Does Content Security Policy block AI live search crawlers?
Your brand is missing from a ChatGPT or Perplexity answer. You open your server configuration, check your robots.txt file, and confirm that no AI bots are explicitly banned. The site loads cleanly in your desktop browser. Yet when an AI answer engine performs a real-time web search for your category, it fails to cite your page or summarizes outdated third-party mentions instead.
The problem is often not access permission, but execution failure. Content Security Policy (CSP) headers designed to protect your visitors can silently prevent AI live search crawlers from rendering the text on your pages.
How Content Security Policy stops headless answer crawlers
A Content Security Policy is an HTTP response header that tells a web browser which dynamic resources are allowed to load and execute. It controls script execution sources, inline script permissions, stylesheet origins, and backend API fetch destinations. Security teams configure CSP headers to prevent cross-site scripting attacks, data injection, and unauthorized data exfiltration.
Traditional search engine crawlers downloaded raw HTML files and parsed static text. Modern AI answer crawlers act differently. When a user asks a query, search-enabled AI tools dispatch answer crawlers to fetch live web pages. Engines such as ChatGPT, Perplexity, Claude, and Google AI Overviews routinely spin up headless browser instances running Chromium to execute JavaScript and evaluate modern web applications.
If your site relies on client-side rendering frameworks like React, Vue, or Angular, your web server initially returns an almost empty HTML shell containing container elements and script tags. The browser must download the JavaScript bundles, execute them, and fetch data from your API endpoints before the page text becomes visible.
Strict CSP directives interfere with this process in several ways:
- Restricting inline script execution. If your application uses inline scripts to bootstrap state without valid nonce or hash attributes, a strict
script-srcdirective causes the headless browser to halt script execution immediately. - Restricting API fetch domains. If your dynamic content relies on fetching data from a microservice hosted on a separate subdomain not explicitly listed in your
connect-srcdirective, the request fails. - Restricting frame or web worker execution. Directives like
child-srcorworker-srccan block client-side data processing workers required to build the Document Object Model (DOM).
When a headless answer crawler encounters these script execution blocks, it does not retry with relaxed security settings. It captures whatever text exists in the rendered DOM at that moment. If your client-side JavaScript failed to execute due to a CSP violation, the crawler records a blank page, a loading screen, or an error boundary. The model then generates its response without your content.
Separating network blocks from rendering failures
It is critical to distinguish between crawling permissions configured in robots.txt and rendering failures caused by security headers. It is equally critical to distinguish between training crawlers and answer crawlers.
Training crawlers fetch web pages to build offline datasets for future model generations. Blocking a training crawler prevents an AI vendor from training future models on your content, but it has zero effect on whether your brand appears in a real-time search query today.
Answer crawlers fetch web pages on demand while generating a response for an active user prompt. Blocking or breaking an answer crawler directly prevents your site from being cited in real-time answers.
In a panel of 54,082 domains measured on 2026-08-08, 33,670 returned a readable robots.txt file. Of those 33,670 readable domains, 5,497 block at least one AI agent in robots.txt, and 2,576 block at least one answer crawler.
The block rates across our panel break down as follows:
Training crawlers:
- GPTBot: 5,080 of 33,670 readable domains
- ClaudeBot: 4,603 of 33,670 readable domains
- Google-Extended: 4,275 of 33,670 readable domains
Answer crawlers:
- PerplexityBot: 2,147 of 33,670 readable domains
- ChatGPT-User: 2,074 of 33,670 readable domains
- OAI-SearchBot: 1,579 of 33,670 readable domains
- Perplexity-User: 1,402 of 33,670 readable domains
- Claude-SearchBot: 1,400 of 33,670 readable domains
- Claude-User: 1,384 of 33,670 readable domains
For comparison, Googlebot is blocked by 610 of 33,670 readable domains.
In a separate census of active Y Combinator companies conducted on 2026-08-07, 3,755 of 4,226 domains returned a readable robots.txt file, and 253 blocked at least one AI crawler.
These figures measure explicit exclusion in robots.txt. They do not capture rendering failures. A domain might permit ChatGPT-User or Perplexity-User in its robots.txt file, but if its CSP headers block script execution in headless Chromium, the result is identical: zero content extracted, zero citations returned.
Auditing browser console errors and response headers
To diagnose whether CSP headers are blocking live search crawlers, you must inspect both your HTTP response headers and your client-side rendering pipeline under headless conditions.
First, inspect your HTTP response headers using command-line tools:
curl -I -
See where you actually stand
Run a free check on your domain. Five AI surfaces, the real buying questions, about a minute. No signup.
Run a free check