AI Crawler robots.txt Guide: Allowing OAI-SearchBot, GPTBot, PerplexityBot & ClaudeBot Safely

Published by FoundInAnswers • Reviewed by Rob Pfleghardt • 4 Verified References

Direct Answer: To appear in ChatGPT Search, Perplexity, Claude, and Google AI Overviews without exposing private app routes, configure /robots.txt to explicitly Allow: / for Googlebot, Bingbot, OAI-SearchBot, PerplexityBot, ClaudeBot, Applebot, and Google-Extended while Disallowing /portal/, /api/, and admin paths, and verify your Cloudflare or CDN WAF does not block datacenter crawler IPs with HTTP 403 CAPTCHA challenges.

User-Agent TokenOperatorPrimary Purpose (Search vs. Training)Recommended Setting for SaaS & BrandsImpact If Blocked
OAI-SearchBotOpenAILive ChatGPT Search citations & clickable source linksAllow: / (Mandatory for ChatGPT Search traffic)Removes your domain from live ChatGPT Search citations
GPTBotOpenAIFoundation model training crawlsAllow: / for brand awareness (or Disallow if publisher-restricted)Future base models lack baseline knowledge of your product
PerplexityBotPerplexity AILive Perplexity answer retrieval & numbered [1] citationsAllow: /Perplexity cites third-party directories instead of your site
ClaudeBotAnthropicClaude web retrieval & ecosystem indexingAllow: /Claude cannot fetch or verify your product documentation
Google-ExtendedGoogleGemini & Vertex AI grounding/training control (separate from Googlebot)Allow: /Limits Gemini model grounding without affecting classic Googlebot

1. The 2023 Reflex That Is Quietly Costing Startups 2026 Buyer Traffic

Back in 2023, thousands of developers copied blanket robots.txt snippets from social media that blocked GPTBot, CCBot, ClaudeBot, and Google-Extended, assuming those bots only scraped news publishers without sending referral clicks. Meanwhile, security plugins and CDN presets added "Block AI Scrapers" toggles turned on by default.

For an ad-supported news newspaper selling subscriptions behind a paywall, blocking training crawlers can make commercial sense. For a B2B SaaS startup, mobile app, CPA firm, or e-commerce brand trying to get recommended when buyers ask AI assistants what to buy, blocking AI retrieval bots is the equivalent of putting Disallow: / on Googlebot in 2008.

Even worse, when we audited 30 prominent SaaS and app domains live today, 10% either blocked AI user-agents or served an HTTP 403 WAF bot challenge to cloud crawler IPs without the founder realizing it.

2. Understanding the Six Crawler User-Agents: Live Search Retrieval vs. Model Training

Major AI labs now separate live search citation bots from background model-training bots so site owners have granular control. Knowing which user-agent controls which surface lets you welcome buyer referral traffic cleanly.

Use the reference table below to verify what each User-agent token actually controls.

3. Copy-Paste Production /robots.txt for SaaS, Mobile App & E-Commerce Sites

A clean /robots.txt does two jobs simultaneously: it rolls out the red carpet for search and AI citation bots on your public marketing pages, /compare, /tools, and /guides/*, and it keeps crawlers out of authenticated dashboards, internal APIs, checkout sessions, and staging preview routes so crawl budget is never wasted.

Note an important syntax detail in the RFC 9309 robots.txt standard: once you declare a specific User-agent block (such as User-agent: OAI-SearchBot), that bot follows ONLY its specific block and ignores rules placed under User-agent: *. Therefore, always repeat your private Disallow lines inside each explicit bot section!

public/robots.txt (Hardened Search + AI Citation Configuration)
# Search & AI Answer Engine Crawl Directives
User-agent: *
Allow: /
Disallow: /portal/
Disallow: /admin/
Disallow: /api/

User-agent: OAI-SearchBot
Allow: /
Disallow: /portal/
Disallow: /admin/
Disallow: /api/

User-agent: GPTBot
Allow: /
Disallow: /portal/
Disallow: /admin/
Disallow: /api/

User-agent: PerplexityBot
Allow: /
Disallow: /portal/
Disallow: /admin/
Disallow: /api/

User-agent: ClaudeBot
Allow: /
Disallow: /portal/
Disallow: /admin/
Disallow: /api/

User-agent: Google-Extended
Allow: /
Disallow: /portal/
Disallow: /admin/
Disallow: /api/

Sitemap: https://yourdomain.com/sitemap.xml

4. Why Your /robots.txt Can Say "Allow" While Your Cloudflare WAF Secretly Says "403 Forbidden"

This is the #1 hidden bug we catch with /tools/ai-crawler-checker: a founder checks their /robots.txt in Chrome, sees User-agent: * Allow: /, and assumes AI bots can read their site. Yet when OAI-SearchBot, PerplexityBot, or our Cloudflare Edge crawler fetches their homepage from a cloud datacenter IP, their firewall returns HTTP 403 "Just a moment..." with a JavaScript Turnstile challenge.

In Cloudflare Dashboard, inspect Security -> Bots: if "Block AI Bots" or "Super Bot Fight Mode -> Definitely Automated -> Managed Challenge" is enabled indiscriminately on public marketing paths, non-browser retrievers get blocked before they ever read a single word of HTML. Keep bot challenges scoped to /login, /api/auth, and POST form endpoints while allowing verified crawlers and GET requests to /, /guides/*, /compare, /sitemap.xml, and /llms.txt.

5. Protecting Private Routes Properly: Why robots.txt Disallow Is Not Authentication

Remember that /robots.txt is a public file anyone can read, so listing Disallow: /secret-admin-panel tells curiosity seekers that route exists without locking it. Never rely on Disallow alone to protect private data.

Pair robots.txt Disallow on /portal/* and /admin/* with two additional layers: (1) real session/passcode authentication on API endpoints, and (2) an X-Robots-Tag: noindex, nofollow HTTP header (or <meta name="robots" content="noindex, nofollow">) so even if an external link points to a private URL, search engines never index it in public results.

Verified Primary Sources & Reference Citations

Frequently Asked Questions

Why do I need to repeat Disallow lines inside every User-agent block in robots.txt?

Under RFC 9309, crawlers match the single most specific User-agent group that applies to them and ignore the wildcard User-agent: * group. If you write User-agent: OAI-SearchBot followed only by Allow: /, OAI-SearchBot will not inherit Disallow: /admin/ from your wildcard block unless you include it in both.

How do I check if Cloudflare Bot Fight Mode is blocking AI search crawlers?

Run your URL through foundinanswers.com/tools/ai-crawler-checker (which fetches from Cloudflare edge IPs using a non-browser crawler User-Agent) or inspect Security -> Events in your Cloudflare dashboard filtered by HTTP 403 / Managed Challenge.

Does blocking Google-Extended hurt my normal Google Search rankings?

Google states that Google-Extended does not affect classic Googlebot web search indexing. However, for SaaS and product brands seeking visibility inside Gemini experiences and AI ecosystems, keeping Google-Extended allowed is recommended.

Should /api/ routes always be disallowed in /robots.txt?

Disallow internal application and mutation endpoints (/api/*), while serving public machine-readable SEO deliverables at clean root or content paths (/sitemap.xml, /llms.txt, /guides/*) that are explicitly allowed.

Where should the Sitemap: line go inside /robots.txt?

Place Sitemap: https://yourdomain.com/sitemap.xml at the very bottom of /robots.txt using an absolute HTTPS URL (never a relative /sitemap.xml path) so every search and AI crawler discovers your canonical sitemap immediately.

Hub 1: AI Answer Engine Optimization (AEO) & /llms.txt Architecture

How FoundInAnswers structures plain-text /llms.txt catalogs, 75-word direct answer boxes, and AI crawler permissions for ChatGPT, Perplexity, Gemini, and Claude.