AI Search

How to Allow AI Crawlers in robots.txt

By BacklinkPrice Team · Dec 1, 2026 · 12 min read
Illustration of a robots.txt file welcoming AI search crawlers

A practical 2026 guide to robots.txt rules for AI crawlers: which bots to allow, which to block, and how to verify the result in your logs.

Quick answer: Allow the search and fetch crawlers from each AI provider in robots.txt, and decide about training crawlers separately. Add explicit Allow rules for OAI-SearchBot, ChatGPT-User, Claude-SearchBot, Claude-User, PerplexityBot and Perplexity-User, then add Disallow rules only for the training bots you want out, such as GPTBot and ClaudeBot. Never rely on a single wildcard rule.

TL;DR: Search bots decide whether AI answers can cite you. Training bots decide whether your text feeds model training. They are separate robots.txt decisions, and mixing them up is the most common mistake.

Key takeaways

  • OpenAI, Anthropic and Perplexity each run separate bots for training, search and user fetches.
  • Blocking OAI-SearchBot removes your pages from ChatGPT search answers.
  • A wildcard Disallow under User-agent: * blocks AI bots you never meant to block.
  • Robots.txt changes take about 24 hours to reach search, according to OpenAI's crawler documentation.
  • Cloudflare's managed robots.txt can add training blocks you did not write yourself.
  • Check server logs after every change, because a robots.txt rule is a request, not a wall.

The three jobs AI crawlers do

Every AI provider splits its crawlers by job, and the split is what makes robots.txt decisions confusing. A training crawler collects pages that may be used to train a model. A search crawler builds the index behind AI search answers and citations.

A user-fetch bot opens a single page because a person asked a question in a chat. The same company runs all three, and each one reads robots.txt on its own terms.

OpenAI documents three user agents. GPTBot crawls content that may be used to train its models. OAI-SearchBot powers ChatGPT search, which launched on October 31, 2024, and surfaces websites in search results.

ChatGPT-User fetches a page on demand when a user inside ChatGPT asks for it. According to OpenAI's crawler documentation, each robots.txt setting is independent, so a site can allow OAI-SearchBot while disallowing GPTBot.

Anthropic follows the same pattern. ClaudeBot collects web content that could contribute to training. Claude-SearchBot navigates the web to improve search result quality for Claude users.

Claude-User fetches a page when a user asks a question. Perplexity runs two: PerplexityBot, which surfaces and links websites in Perplexity search results, and Perplexity-User, which visits a page to help answer a question. According to Perplexity's own bot documentation, PerplexityBot is not used to crawl content for AI foundation models.

Google works differently. Google-Extended is a robots.txt control token, not a separate crawler, and it governs whether Google may use your content for Gemini model training and grounding. Googlebot itself remains the crawler that feeds Google search and AI Overviews. Microsoft's Bingbot discovers and indexes pages for Bing search, and Bing's index grounds Microsoft Copilot answers.

According to Cloudflare's May 2026 measurement, AI crawlers made up 20.3 percent of verified bot traffic, with AI-search bots adding another 6.5 percent, so roughly a quarter of verified bot activity was AI related.

The crawler list: who is who in 2026

BotVendorJobIf you block it
OAI-SearchBotOpenAISearch index for ChatGPTPages leave ChatGPT search answers
ChatGPT-UserOpenAIFetches a page for one userChatGPT cannot open the page on request
GPTBotOpenAITraining data collectionContent stays out of model training
Claude-SearchBotAnthropicSearch index for ClaudePages are not indexed for Claude search
Claude-UserAnthropicFetches a page for one userClaude cannot open the page on request
ClaudeBotAnthropicTraining data collectionFuture pages stay out of training data
PerplexityBotPerplexitySearch index for PerplexitySite leaves Perplexity search results
Perplexity-UserPerplexityFetches a page for one userPerplexity cannot open the page on request
Google-ExtendedGoogleTraining control tokenContent stays out of Gemini training
BingbotMicrosoftBing search indexPages leave Bing and Copilot results

Keep this table next to your robots.txt file. When a vendor adds a bot or renames one, the table is the first thing to update. User-agent names change over time, so confirm each token against the official documentation from OpenAI, Anthropic and Perplexity before you deploy any rules, as the guides from DEV Community recommend.

The two robots.txt setups that cover most sites

Your robots.txt file lives at the root of each hostname, and it applies per hostname, so a subdomain such as docs.example.com needs its own file. Two setups cover most sites. The first welcomes everything. The second welcomes search and opts out of training.

The maximum visibility setup allows the search and retrieval bots and leaves training crawlers open as well. Use it when you want the widest possible presence in AI answers and you are comfortable with training use. The file below is the shape of that setup. Put your own sitemap address in the last line.

User-agent: OAI-SearchBot
Allow: /
User-agent: ChatGPT-User
Allow: /
User-agent: Claude-SearchBot
Allow: /
User-agent: Claude-User
Allow: /
User-agent: PerplexityBot
Allow: /
User-agent: Perplexity-User
Allow: /
User-agent: *
Allow: /
Sitemap: https://example.com/sitemap.xml

The second setup is the one most small sites should start with. It allows AI search and opts out of model training. The training bots get a Disallow, the search and fetch bots get an Allow, and the wildcard group stays open so ordinary search engines keep working.

User-agent: GPTBot
Disallow: /
User-agent: ClaudeBot
Disallow: /
User-agent: Google-Extended
Disallow: /
User-agent: CCBot
Disallow: /
User-agent: OAI-SearchBot
Allow: /
User-agent: ChatGPT-User
Allow: /
User-agent: Claude-SearchBot
Allow: /
User-agent: Claude-User
Allow: /
User-agent: PerplexityBot
Allow: /
User-agent: Perplexity-User
Allow: /
User-agent: *
Allow: /
Sitemap: https://example.com/sitemap.xml

A new shared opt-out is on its way. One robots.txt group, whose token starts with two underscores and ends in ai-training, says no AI training to every operator that reads it.

According to a DEV Community guide checked in November 2026, Anthropic began recognising it on October 30, 2026, Google plans to read it in 2027, Microsoft starts on February 1, 2027, and OpenAI says it will follow in the coming months. It is an individual Internet-Draft, not a standard, so do not rely on it alone yet.

The first mistake is a wildcard Disallow. A rule that reads User-agent: * with Disallow: / covers every crawler with no group of its own, including AI bots you have never heard of.

Under RFC 9309, a crawler obeys the group matching its own token and falls back to the wildcard group only when none matches. A named group with Allow: / protects that bot from the wildcard, so always give the search bots their own groups before you touch the wildcard.

The second mistake is copying a GPTBot block from an old post. OpenAI documents GPTBot as the training crawler and OAI-SearchBot as the search crawler, with each setting independent. Blocking GPTBot leaves ChatGPT search alone, while blocking OAI-SearchBot keeps your pages out of its answers, though they can still appear as plain links. According to a DEV Community guide from November 2026, a change can take about 24 hours to reach search, so recheck after a day.

The third mistake is letting a platform write the file for you without reading it. Cloudflare has blocked AI crawlers by default for new domains since July 2025. On September 15, 2026, Cloudflare set new defaults across three AI traffic categories, with Training and Agent blocked by default for new domains on ad-displaying pages, while Search stays allowed.

According to a Vibrant Media census of 945 small-business sites in November 2026, 42 sites blocked GPTBot and 2 blocked OAI-SearchBot, and Cloudflare wrote the rule on 32 of the 42. Read your own file before you trust it.

The fourth mistake is a firewall that blocks the bots at the server. When Cloudflare, Sucuri or other bot-protection layers are configured aggressively, OAI-SearchBot, PerplexityBot and ClaudeBot get the same treatment as malicious scrapers. According to FuelOnline's 2026 guide, they get blocked, and that means your content never enters the AI knowledge pool. Check your firewall and CDN rules for the same tokens you allowed in robots.txt.

If your site already earns citations, how to get cited in AI overviews explains the on-page work that turns access into actual mentions. Access alone does not earn a citation, but without access nothing else matters.

How to verify the change worked

Start with a direct fetch of the file. Run a curl command against your own robots.txt and search the output for each token you care about. The check takes seconds and catches the most common error, which is a rule in the wrong group. A robots.txt file is plain text, so read it like one.

Next, check your server logs for the bots themselves. Search access logs for OAI-SearchBot, Claude-SearchBot and PerplexityBot requests and confirm the IP addresses against the ranges each vendor publishes, because a user agent string is easy to fake. A real visit from a search bot after your change is the first sign the rule took effect.

Then check indexing. Submit your sitemap to Google and Bing, and confirm in each console that your key pages are indexed. AI products rely on search indexes, so a page that no search engine has indexed cannot be cited. According to FuelOnline's 2026 guide, more than 5 billion URLs are submitted daily via IndexNow across Bing, Yandex, Naver and Seznam, and that protocol is the fastest way to get a changed page noticed.

Finally, wait a day and recheck. OpenAI documents a delay of about 24 hours for robots.txt changes to reach search. Perplexity and Meta document a similar delay of up to 24 hours. If a bot still has not visited after two days, look for a firewall rule or a CDN setting that blocks it, because robots.txt was probably not the problem.

To see which of your pages the AI engines are already citing, how to track AI citations shows the monitoring setup that catches new mentions as they appear.

What about llms.txt

An llms.txt file sits at yoursite.com/llms.txt and lists your key pages in a short, machine-readable form. It is optional. Current data suggests most AI crawlers do not request it, and the DEV Community guides checked in November 2026 found little evidence that it changes citation behavior. It costs almost nothing to add, and it gives a model a clean map of your site, but it is not a substitute for robots.txt access, a sitemap, or content in the initial HTML.

Server-rendered content matters more. AI crawlers read the HTML your server sends first, and a 2024 Vercel test found OpenAI crawlers do not read JavaScript. If your key answers only appear after JavaScript runs, the crawlers may never see them. Put the answer in the raw HTML, keep headings in the question's own words, and keep paragraphs short enough for a model to quote cleanly.

Frequently Asked Questions

No. GPTBot is OpenAI's training crawler and OAI-SearchBot is its search crawler, and each robots.txt setting is independent. Blocking GPTBot keeps your content out of training data.

Blocking OAI-SearchBot keeps your pages out of ChatGPT search answers. Check both tokens separately.

Will allowing AI crawlers hurt my Google rankings?

No evidence in the sources reviewed here shows a ranking penalty for allowing AI crawlers. The search bots are separate from Googlebot, and Google's own AI features read your pages through Googlebot. Allowing AI crawlers changes who can read your pages, not how Google ranks them.

How long does a robots.txt change take to work?

About 24 hours for OpenAI, and up to 24 hours for Perplexity and Meta, according to their own documentation. Crawlers cache robots.txt, so a change is not instant. Recheck your logs the day after you edit the file.

Do I need to allow every AI bot I have heard of?

No. Allow the search and fetch bots from the providers whose answers you want to appear in. Most sites need OAI-SearchBot, Claude-SearchBot and PerplexityBot, plus the user-fetch bots. Decide about training bots on their own merits.

What if my host or CDN blocks the bots anyway?

Then robots.txt cannot help, because the bots never reach the file. Check your firewall, CDN and security plugin settings for the same tokens, and add the bots to your allowlist there. A robots.txt rule is a request that a well-behaved crawler follows, not a wall that forces anything.

Should I use Cloudflare's managed robots.txt?

Only if you read what it adds. The managed file blocks eight training crawlers, and that is a reasonable default for many sites. It does not block AI search crawlers. Check your file after enabling it, because the change applies to your whole site at once.

Expert verdict

Pros: The setup takes about 30 minutes, costs nothing, and gives you a clear record of which AI systems may use your content. The search and training decisions are separate, so you can appear in AI answers without feeding model training.

Cons: Robots.txt is a request, not enforcement, and some bots ignore parts of it. User-fetch bots may skip robots.txt rules entirely, so rate limits and IP rules are the controls that bind for that group. Vendor tokens also change, so the file needs a check every few months.

Best for: Any site that wants citations in ChatGPT, Claude or Perplexity answers, and any site that wants to opt out of training without losing search visibility.

Not for: Sites that want to block all AI access, which need firewall rules and IP controls on top of robots.txt, and sites whose content is already behind a login, where robots.txt changes nothing.

If you want the full picture of how citations are earned once access is open, how ChatGPT chooses which sources to cite explains the selection step that follows the crawl.

For the numbers behind AI citation behavior, AI search citation statistics for 2026 collects the studies that show which pages get cited and why.

And if you are weighing whether AI visibility matters for your link strategy at all, are backlinks still important with AI search puts the two channels side by side.

For the measurement side, how to measure AI referral traffic in GA4 shows how to see the traffic AI search sends you once the crawlers can reach your pages.

Bottom line

Allow the search bots, decide about the training bots, and check your work in the logs. A file with six Allow groups and four Disallow groups covers almost every small site. The whole job takes half an hour, and the cost of getting it wrong is invisibility in the answers your customers now read first.

Sources

BacklinkPrice Team
Written by
BacklinkPrice Team
Link building and backlink pricing research

The BacklinkPrice Team researches backlink prices, publisher sites and link building tools. We check prices and plans against each provider's own pages and date them, so you know how current the numbers are.

More from BacklinkPrice Team

Related guides