Robots.txt for AI Crawlers: Rules for ChatGPT, Claude, Perplexity and Google
Published · 8 min read
Platform details checked against official documentation on November 10, 2026.
To control AI crawlers with robots.txt, add a group for each crawler's name (its "user agent") followed by Allow or Disallow rules. The names that matter most are OAI-SearchBot, GPTBot and ChatGPT-User for OpenAI; Claude-SearchBot, ClaudeBot and Claude-User for Anthropic; PerplexityBot and Perplexity-User for Perplexity; Googlebot and Google-Extended for Google; and Bingbot for Microsoft. The search crawlers decide whether you can appear in AI answers; the training crawlers decide whether your content is used to build AI models. You can choose each separately.
This guide is a reference. If you just want ChatGPT and similar tools to be able to read your site, the shorter guide to allowing AI crawlers is the place to start.
What robots.txt is
robots.txt is a plain text file at the root of your website, such as https://www.example.com/robots.txt. Well-behaved crawlers read it before fetching pages and follow its rules. It is a request, not a lock: it doesn't stop a crawler that chooses to ignore it, and it doesn't keep a page out of search results on its own. Google is explicit that robots.txt "is not a mechanism for keeping a web page out of Google." To keep a page out of Google, use a noindex tag, and don't block that page in robots.txt, or Google can't see the tag.
The AI crawler names
These names come from each company's own crawler documentation, checked on the date shown at the top of this page.
| User agent | Company | What it does | Follows robots.txt? |
|---|---|---|---|
OAI-SearchBot | OpenAI | Finds pages to show and link in ChatGPT search answers | Yes |
GPTBot | OpenAI | Collects content that may be used to train OpenAI's models | Yes |
ChatGPT-User | OpenAI | Fetches a page because a ChatGPT user asked for it | OpenAI says robots.txt "may not apply" |
Claude-SearchBot | Anthropic | Improves the quality of Claude's search results | Yes |
ClaudeBot | Anthropic | Collects content that may be used for training | Yes |
Claude-User | Anthropic | Fetches pages for Claude users | Yes |
PerplexityBot | Perplexity | Finds and links pages in Perplexity's search results | Yes |
Perplexity-User | Perplexity | Fetches a page a Perplexity user asked about | Perplexity says it "generally ignores" robots.txt |
Googlebot | Google Search, including AI Overviews and AI Mode | Yes | |
Google-Extended | Not a separate crawler: a token that controls use for Gemini training and grounding. It does not affect Google Search. | Yes | |
Bingbot | Microsoft | Bing search, which Microsoft's AI features also draw on | Yes |
Applebot-Extended | Apple | Not a separate crawler: a token that controls use for training Apple's models. Pages that block it can still appear in Apple's search features. | Yes |
CCBot | Common Crawl | Builds an open archive of the web that many organizations use | Yes |
OpenAI also documents OAI-AdsBot, which only visits pages submitted as ChatGPT ads. Older names you may see in copied files, such as anthropic-ai or Claude-Web, are not in Anthropic's current list.
How robots.txt rules are read
These rules come from Google's published robots.txt specification. Other major crawlers follow the same standard, but check a company's documentation if a detail matters to you.
- One file per host. The file only covers the exact host and protocol it is on.
https://www.example.com/robots.txtdoesn't coverhttps://shop.example.com. - A crawler follows one group. It uses "the group with the most specific user agent" that matches its name, and ignores the others. A crawler with its own group does not also follow the
User-agent: *group. - Repeated groups combine. If the same crawler is named in two groups, its rules are merged.
- The longest matching rule wins. When an
Allowand aDisallowboth match a page, the one with the longer path applies. If they are the same length, Google uses the least restrictive one. - Paths are case-sensitive.
Disallow: /Private/doesn't block/private/. - Size and errors. Google reads up to 500 KiB of the file. If the file returns "not found," Google treats the site as having no restrictions. If the server returns an error, Google pauses crawling and retries, then falls back on the last good copy.
- Changes aren't instant. Google generally caches robots.txt for up to 24 hours; OpenAI and Perplexity both describe about a day for changes to take effect.
Copy-and-paste recipes
Replace example.com with your own domain, and keep any existing rules your site needs, such as blocks on admin or checkout pages.
Allow everything
User-agent: *
Allow: /
Sitemap: https://www.example.com/sitemap.xmlAllow AI search, decline AI training
This is the most common choice for a local business that wants to be found but doesn't want its content used to train models.
User-agent: *
Allow: /
# Training crawlers and tokens: declined
User-agent: GPTBot
User-agent: ClaudeBot
User-agent: Google-Extended
User-agent: Applebot-Extended
User-agent: CCBot
Disallow: /
Sitemap: https://www.example.com/sitemap.xmlThe search crawlers (OAI-SearchBot, Claude-SearchBot, PerplexityBot, Googlebot, Bingbot) aren't named, so they follow the * group and are allowed.
Keep a private folder off-limits and decline training
User-agent: *
Disallow: /client-portal/
User-agent: GPTBot
User-agent: ClaudeBot
Disallow: /Here the named training crawlers are blocked everywhere, and everyone else is kept out of /client-portal/. If you later add a group that allows a named crawler, repeat Disallow: /client-portal/ in that group, because a named crawler ignores the * rules.
Block all AI crawlers (not recommended for most businesses)
User-agent: OAI-SearchBot
User-agent: GPTBot
User-agent: ChatGPT-User
User-agent: Claude-SearchBot
User-agent: ClaudeBot
User-agent: Claude-User
User-agent: PerplexityBot
User-agent: Perplexity-User
User-agent: Google-Extended
User-agent: Applebot-Extended
User-agent: CCBot
Disallow: /This keeps your site out of ChatGPT, Claude and Perplexity search answers. It doesn't remove you from Google's AI Overviews, which follow Googlebot, and the user-triggered fetchers may still visit when someone asks about a specific page.
How to test your file
- Open it in a browser at
/robots.txton every host you use, with and withoutwwwif both work. - Use Google Search Console's robots.txt report to see the copy Google fetched and any lines it couldn't parse.
- Read it from top to bottom for each crawler you care about: find the most specific group that names it (or
*if none does), and check which rules apply. - Check your firewall separately. robots.txt can't show a block made by Cloudflare, your host or a security plugin. Our guide to allowing AI crawlers covers where to look.
Common mistakes
- Typos in the crawler name.
GPT-BotorOAISearchBotmatch nothing, so the rule is silently ignored. - Assuming
*rules still apply to a named crawler. They don't, as explained above. - Blocking a page in robots.txt to hide it from search. Use
noindexinstead, and leave the page crawlable. - A leftover
Disallow: /from a staging site. Sites copied from a test version often keep a block-everything rule. - Expecting
Crawl-delayto work everywhere. Google ignores it. Anthropic and Common Crawl support it; Apple says Applebot doesn't follow it. - Relying on llms.txt instead. Google says Google Search doesn't use llms.txt files, and that one "will neither harm nor help" your visibility there. OpenAI, Anthropic and Perplexity's crawler documentation doesn't mention it. It is optional, not a replacement for robots.txt.
Limitations
Allowing a crawler makes your pages available to it; it doesn't decide whether a tool cites you. And robots.txt depends on crawlers choosing to follow it, which is why each company publishes the IP addresses its crawlers use, so you can tell a genuine visit from an imitation.
Related reading
- How to allow ChatGPT and other AI search engines to crawl your website
- Why is my website not showing up in ChatGPT?
Sources
- Google Search Central: How Google interprets the robots.txt specification
- Google Search Central: Introduction to robots.txt and Block indexing with noindex
- Google: Google's common crawlers
- Google Search Central: AI features and your website
- Google Search Central: AI optimization guide (llms.txt)
- OpenAI: Overview of OpenAI crawlers
- Anthropic: Does Anthropic crawl data from the web?
- Perplexity: Perplexity crawlers
- Apple: About Applebot
- Common Crawl: CCBot
- Bing Search blog: Clearer preferences for training and grounding