# How do I stop pop-ups and cookie banners from blocking AI agents?

> Gemini and Claude hand cookie consent back to the person, so a banner that covers the page can end a shopping task. Keep content readable and dialogs closable.

- Canonical URL: https://aiscovery.io/resources/stop-popups-blocking-ai-agents
- Markdown version: https://aiscovery.io/resources/stop-popups-blocking-ai-agents.md
- Last updated: 2026-10-21

Keep the product page readable behind your cookie banner instead of covering it, make every pop-up a real dialog that closes with a labeled button or the Escape key, and don't open marketing pop-ups on a shopper's first page. Agents such as Google's Gemini and Anthropic's Claude are built to hand cookie consent back to the person, so a banner that hides the whole page can stop the task right there.

- Topic: Page basics
- Author: Aiscovery team
- Published: 2026-10-21
- Updated: 2026-10-21
- Reading time: 7 min read

## Key facts

- Google's Gemini computer use docs say the model requires user takeover for cookie consent banners and privacy prompts.
- Gemini in Chrome's auto browse pauses for manual steps such as accepting cookies, signing in or entering a CAPTCHA.
- Anthropic's computer use docs list accepting cookies among the actions that need a person's confirmation.
- Google's sample instructions for its computer use model forbid solving or bypassing CAPTCHAs of any kind.
- Google Search guidance: don't obscure the entire page with interstitials; use banners that take a small part of the screen.

## Why overlays stop AI agents

Agents that browse for a shopper are built to leave consent to the shopper. Google's Gemini computer use model hands control back for cookie banners and privacy prompts. Gemini in Chrome pauses for cookies, sign-in and CAPTCHAs until the person clicks Take over task. Anthropic tells developers to ask a person before accepting cookies. If the banner covers the product, the agent can't read the price until someone answers it, and often nobody is watching.

OpenAI's help page for ChatGPT's cloud browser says each website ultimately decides whether to allow its traffic. To the shopper, a store that blocks the agent and a store that hides behind an overlay look the same: the assistant couldn't get the answer.

Common overlays on a store and how they affect agents:

| Overlay | What happens to an agent | Fix |
| --- | --- | --- |
| Cookie wall that hides the page until you choose | Hands consent back to the person and waits | A banner that leaves the page readable behind it |
| Newsletter or discount pop-up on the first page | Has to find and close it before reading anything | Show it later, never before the price is visible |
| Country or currency selector as a full-screen modal | May not know which country to pick | Default to a country, offer the switch inline |
| Age gate | May need the person to confirm | Keep it only where the law requires it, as an overlay |
| Chat widget that covers Add to cart or the price | Reads or clicks the wrong element | Keep it collapsed and clear of the buy box |
| CAPTCHA or bot challenge on product pages | Stops: agents are told not to solve CAPTCHAs | Keep challenges for login, checkout and forms |

## Fix the overlays

### 1. Let the page stay readable behind the cookie banner

Keep whatever consent choices your legal team requires. The change is the layout: a banner at the bottom or side, with Accept and Reject as equal buttons, and the product, price and stock still in the page and not hidden behind a full-screen layer. Google's Search guidance asks for the same: banners that take up a small part of the screen.

### 2. Make every pop-up a real dialog

W3C's modal dialog pattern: the dialog has `role="dialog"` and a name, focus moves into it, Tab stays inside, Escape closes it, and focus returns to where it was. A labeled close button gives an agent something it can find by name.

**HTML: a dialog an agent can close**

```html
<div role="dialog" aria-modal="true" aria-labelledby="signup-title">
  <h2 id="signup-title">Join our newsletter</h2>
  <!-- form -->
  <button type="button" aria-label="Close">×</button>
</div>

<script>
  document.addEventListener("keydown", (event) => {
    if (event.key === "Escape") closeSignupDialog();
  });
</script>
```

### 3. Delay marketing pop-ups

Don't open a newsletter or discount pop-up on the first page a visitor lands on. Show it after a second page view, on exit, or after a scroll, and never on top of a product's price.

**JavaScript: open the pop-up from the second page view**

```js
const views = Number(sessionStorage.getItem("pageViews") ?? 0) + 1;
sessionStorage.setItem("pageViews", String(views));
if (views >= 2) openSignupDialog();
```

### 4. Don't block prices behind a country picker

Pick a default country and currency from the domain or the visitor's location, show prices straight away, and offer the switch as a menu, not a modal that must be answered first.

### 5. Keep bot challenges off browsing pages

A CAPTCHA on a product or collection page stops agents completely. Google's sample instructions forbid its model from solving them, and Anthropic says its crawlers won't try to bypass them. Use challenges where they protect something: login, checkout and forms. See [does Cloudflare block AI agents](https://aiscovery.io/resources/does-cloudflare-block-ai-agents).

> **Where agents get stuck.** The agent lands on a product page from a search result, meets a full-screen offer and a cookie wall stacked on top of each other, and hands the task back. The shopper asked for a price and got a question about cookies.

## Test it like an agent

### 1. Open a product page in a private window

No cookies, no history: the way an agent's fresh browser arrives. Use a phone-sized window too, where overlays cover the most.

### 2. Answer three questions without clicking

Can you read the product name, the price and the stock state? If an overlay hides any of them, an agent has to deal with it first.

### 3. Close everything with the keyboard

Press Tab to reach each close button and Escape to close each dialog. If you can't, neither can an agent that works through the accessibility tree.

In Aiscovery's AI agent test runs, named AI agents try key shopping tasks on your store in a read-only browser, and the masked step screenshots show the overlay an agent met and what it did next. See [how a test run works](https://aiscovery.io/product/agent-readiness-audit).

## Keep going

- [Variants and stock](https://aiscovery.io/resources/product-variants-stock-ai-agents): Once the overlay is gone: can the agent read the size and stock?
- [Accessibility for AI agents](https://aiscovery.io/resources/accessibility-for-ai-agents): Accessibility-tree signals, keyboard behavior and dynamic states.
- [Product tour](https://aiscovery.io/product): The site check, AI agent test runs and the ranked fix list.
- [Request a demo](https://aiscovery.io/demo): See where named AI agents stop on your own product pages.

## Questions store owners ask

**Q: Will AI agents accept my cookie banner?**

A: Many are built not to. Google's Gemini computer use model requires user takeover for cookie consent banners, and Anthropic tells developers to get a person's confirmation before accepting cookies.

**Q: Can I hide the cookie banner from bots?**

A: We don't recommend it. Serving bots a different page is hard to keep in step with the real one and easy to get wrong. Make the banner non-blocking for everyone instead.

**Q: Do pop-ups hurt Google rankings too?**

A: Google says intrusive dialogs that obscure the page can lead to poor search performance, and recommends banners that take up a small part of the screen. Legally required interstitials, such as age gates, are an exception.

**Q: Is a chat widget a problem?**

A: Only when it covers the price, the options or Add to cart, or opens on its own. Keep it collapsed until someone opens it.

## Sources

Every technical claim on this page comes from the vendor's own documentation, checked on the date shown as Updated. Crawler names and settings change, so check the source before you edit a live store.

1. [Computer use](https://ai.google.dev/gemini-api/docs/computer-use) (Google AI for Developers (Gemini API))
2. [Use Gemini in Chrome](https://support.google.com/chrome/a/answer/17030585?hl=en) (Google Chrome Enterprise and Education Help)
3. [Computer use tool](https://platform.claude.com/docs/en/agents-and-tools/tool-use/computer-use-tool) (Claude Developer Platform)
4. [Does Anthropic crawl data from the web, and how can site owners block the crawler?](https://support.claude.com/en/articles/8896518-does-anthropic-crawl-data-from-the-web-and-how-can-site-owners-block-the-crawler) (Anthropic)
5. [Using cloud browser in ChatGPT](https://help.openai.com/en/articles/20001280-using-cloud-browser-in-chatgpt) (OpenAI Help Center)
6. [Avoid intrusive interstitials and dialogs](https://developers.google.com/search/docs/appearance/avoid-intrusive-interstitials) (Google Search Central)
7. [Dialog (Modal) Pattern](https://www.w3.org/WAI/ARIA/apg/patterns/dialog-modal/) (W3C WAI-ARIA Authoring Practices Guide)

## More guides

- [How do I allow ChatGPT and other AI agents on my Shopify store?](https://aiscovery.io/resources/allow-ai-agents-shopify-robots-txt) (Shopify)
- [How do I check which AI crawlers my store blocks?](https://aiscovery.io/resources/check-which-ai-crawlers-your-store-blocks) (AI crawlers)
- [Does blocking GPTBot hurt my store?](https://aiscovery.io/resources/does-blocking-gptbot-hurt-your-store) (AI crawlers)

## See what AI agents do in your store.

A short call: we run the site check on your store, show what robots.txt tells each AI crawler, and walk through a test run where named AI agents try key shopping tasks.

[Request a demo](https://aiscovery.io/demo)

Have a real workflow to test now? [Apply as a launch partner](https://aiscovery.io/partners)

---

This is the Markdown version of the page for AI agents. The HTML page at the canonical URL is authoritative. Site index: https://aiscovery.io/llms.txt
