Skip to content
Search

How to block AI crawlers

Block AI bots with robots.txt: choose which jobs to block, name each bot's token, add CDN or server rules for bots that ignore it, then test.

for OpenAI's search systems to adjust after a robots.txt change. Perplexity and Meta also give up to 24 hours.Source: OpenAI

In short. To block AI bots with robots.txt, decide which jobs to block, then name each bot's token in a User-agent line. A GPTBot or ClaudeBot rule keeps content out of training, and an OAI-SearchBot rule removes the site from ChatGPT search answers. For fetchers that ignore robots.txt, add a CDN or server rule. Keep /robots.txt reachable, because a bot that cannot read the file cannot see your opt-out.

On this page 9 sections

The evidence

Confirmed

OpenAI says disallowing GPTBot indicates that a site's content should not be used to train its generative AI foundation models. Its GPTBot and OAI-SearchBot settings are independent.1

1OpenAIOpenAI, Overview of OpenAI Crawlers, checked Nov 20, 2026.
Confirmed

Anthropic says blocking its IP addresses may not give a reliable opt-out, because the block stops its bots from reading robots.txt.2

2Anthropic Help CenterAnthropic Help Center, checked Nov 20, 2026.
Confirmed

Google-Extended has no user agent of its own. Google says it does not affect a site's inclusion in Google Search and is not a ranking signal.3

3Google for DevelopersGoogle for Developers, List of Google's common crawlers, checked Nov 20, 2026.
Confirmed

Perplexity says Perplexity-User generally ignores robots.txt rules, because a user requested the fetch.4

4PerplexityPerplexity, Perplexity Crawlers, checked Nov 20, 2026.
Confirmed

Meta says it supports robots.txt rather than non-standard formats such as NoAI tags.8

8Meta for DevelopersMeta for Developers, Meta Web Crawlers, updated May 21, 2026, checked Nov 20, 2026.

When you block AI bots with robots.txt, you decide whether your content trains AI models and whether your site can appear in AI search answers, and different bots control the two. In our crawl of websites cited by AI answers, 8.52% of domains with a valid robots.txt fully blocked at least one AI crawler. You block an AI crawler in up to three places: robots.txt for bots that follow it, a CDN or firewall for bots that do not, and the web server. A rule for one bot never covers another bot, even one from the same company. Each operator documents what a block on its own bots changes.

#Decide what to block

The choice comes down to how much AI search visibility you are willing to give up for control. Choose one of three levels. Each level adds bots to the one before it.

Table 1.Each choice adds bots to the one above it. Googlebot, Bingbot and Applebot stay allowed in all three.
ChoiceBots to nameMain effect
Block training, allow AI searchGPTBot, ClaudeBot, Google-Extended, meta-externalagent, Applebot-Extended, CCBotOperators that document a training opt-out stop using the site for future training
Block AI search tooAdd OAI-SearchBot, Claude-SearchBot, PerplexityBot, meta-webindexerThe site leaves ChatGPT search answers and can lose visibility in Claude, Perplexity and Meta AI
Block everythingAdd ChatGPT-User, Claude-User, Perplexity-User, meta-externalfetcher, BytespiderSome of these fetchers ignore robots.txt, so this choice needs a CDN or server rule

What is the difference between training bots and search bots? describes the job of each bot. The sections below give what each operator says a block changes.

This split opts a site out of training and keeps it eligible for AI search. OpenAI's crawler overview says that disallowing GPTBot "indicates a site's content should not be used in training generative AI foundation models." Each OpenAI setting is independent, so OAI-SearchBot can stay allowed for ChatGPT search.1

The Anthropic Help Center says a ClaudeBot restriction signals that the site's future materials should be excluded from its training datasets.2 Google's list of common crawlers says Google-Extended controls training of future Gemini models and grounding in Gemini Apps and Grounding with Google Search on Vertex AI. Google says the token does not affect inclusion in Google Search and is not a ranking signal.3 A Google-Extended block therefore also covers grounding, which is a use at answer time.

Apple's About Applebot page says disallowing Applebot-Extended opts content out of training Apple's foundation models. Pages that disallow it can still appear in search results in Spotlight, Siri and Safari.5

Two more bots need a decision:

How to allow or block AI bots in robots.txt gives the complete rule set for this split. In our crawl of the websites that AI answers cited in October and November 2026, 8.52% of domains with a valid robots.txt fully blocked at least one AI crawler. A smaller share, 4.15%, blocked GPTBot and let OAI-SearchBot fetch the site. Do websites cited by AI answers block AI crawlers? has the figures for each crawler.

#Block AI search too

A search block removes the site from some AI answers. OpenAI says sites opted out of OAI-SearchBot "will not be shown in ChatGPT search answers," though they can still appear as navigational links.1 Anthropic says disabling Claude-SearchBot prevents indexing for search, which may reduce the site's visibility and accuracy in search results.2

Perplexity says PerplexityBot is not used to crawl content for AI foundation models. It recommends allowing the bot to ensure a site appears in its search results.4 A PerplexityBot block is therefore a search decision only. Meta says allowing meta-webindexer helps it cite and link to content in Meta AI's responses.8

#Block everything

Blocking everything takes a CDN or server rule, because three of the four operators say their user-request fetchers may not follow robots.txt. These fetchers act when a person asks an assistant about a page. Anthropic says disabling Claude-User prevents its system from retrieving content in response to a user query.2 The other three operators say their fetchers may not follow robots.txt. OpenAI says the rules may not apply to ChatGPT-User, because a user starts these actions.1 Perplexity says Perplexity-User generally ignores them,4 and Meta says meta-externalfetcher may bypass them.8

ByteDance's page about Bytespider names it as the crawler of Toutiao Search. The page does not say whether Bytespider follows robots.txt or whether its data trains models.9

Leave Googlebot, Bingbot and Applebot out of all three choices unless you also want to leave their search results. Google says rules for Googlebot affect Google Search.3 Apple says allowing Applebot lets content appear in search results in its products.5 Cloudflare says a block of all three stops them from reaching a site for search as well.10

#Write the robots.txt groups

  1. Open the robots.txt generator and start from the preset that matches your choice of what to block, so each bot token is spelled the way its operator writes it.
  2. Change single bots where your choice differs from the preset.
  3. Copy the paths that your User-agent: * group already blocks into each new group. A bot that finds a group with its own name ignores the * group, so without the copy it could fetch those paths.
  4. Keep every existing group for other crawlers, and remove older groups that name the same AI tokens, so each AI token has one group to follow.
  5. Publish the file at /robots.txt on each host. Anthropic says to repeat the rules for every subdomain you want to opt out.2

Google-Extended and Applebot-Extended send no requests. Google crawls with its existing user agents and reads Google-Extended as a control.3 Apple says Applebot-Extended does not crawl webpages.5 robots.txt is the only place where these two tokens work, so a CDN or server rule cannot replace them.

Plan for about a day before a robots.txt change takes effect. OpenAI says its search systems need about 24 hours after a robots.txt update.1 Perplexity and Meta say up to 24 hours.4 8 Common Crawl's FAQ says CCBot stops crawling after a Disallow rule and checks the file again from time to time.6

#Block at the CDN or firewall

Add an edge rule in two cases: for bots that do not follow robots.txt, and when you want requests refused instead of asked to stay away. ChatGPT-User, Perplexity-User and meta-externalfetcher are the first case. Bytespider may also be, because ByteDance does not document its robots.txt support.

#Cloudflare

On Cloudflare, check the Training setting first. Cloudflare sets a separate policy for Search, Agent and Training bots, and since September 15, 2026, the Block setting for Training also applies to Googlebot, Bingbot and Applebot. Cloudflare's announcement says this "impacts search as well as training," and that Disallow AI Training stops training and keeps search.10 With Disallow AI Training, Cloudflare blocks the training-only crawlers of OpenAI, Anthropic, Meta and Amazon. How Cloudflare's AI bot settings work explains each setting and the defaults for new domains.

#Other CDNs and firewalls

Match the user agent and the operator's IP list together. OpenAI publishes an IP list for each of its bots, including ChatGPT-User.1 Perplexity publishes separate lists for PerplexityBot and Perplexity-User. Its firewall examples combine a user agent match with an IP match.4 Perplexity wrote them as allow rules, and the same two conditions work in a block rule. How to verify AI crawlers lists the IP files and the operators that publish none.

Caution.A firewall block can stop a bot from reading robots.txt. Anthropic says an IP block "may not work correctly or persistently guarantee an opt-out," because the block stops its bots from reading robots.txt.2 OpenAI says that if a site allows both GPTBot and OAI-SearchBot, it may use one crawl for both uses.1 Keep the Disallow rule for each training bot in robots.txt, and exclude the path /robots.txt from every edge and server block.

A blocked robots.txt request can cancel your opt-out or close the whole site, depending on its status code. RFC 9309 says a 4xx answer lets the crawler access any resource on the server. A 5xx answer means the crawler must assume the whole site is disallowed.11

#Add server rules by user agent

Without a CDN, refuse the requests in the web server. These rules return 403 to the listed user agents and let every client fetch /robots.txt. Replace the names with the tokens you chose to block.

For nginx:

# In the http block
map $http_user_agent $block_ai {
    default 0;
    ~*(GPTBot|ClaudeBot|CCBot|meta-externalagent|Bytespider) 1;
}

# In the server block
set $deny_ai $block_ai;
if ($uri = /robots.txt) { set $deny_ai 0; }
if ($deny_ai) { return 403; }

For Apache, in the site configuration or .htaccess:

RewriteEngine On
RewriteCond %{REQUEST_URI} !^/robots\.txt$
RewriteCond %{HTTP_USER_AGENT} (GPTBot|ClaudeBot|CCBot|meta-externalagent|Bytespider) [NC]
RewriteRule ^ - [F]

A user agent rule trusts what the client says about itself. Any client can send a bot's name, and a bot can send a browser's user agent. Common Crawl says it is aware of crawlers that falsely identify themselves as CCBot.7 ByteDance says a Bytespider request whose hostname is outside bytedance.com is an impostor.9 A user agent rule blocks the fakes along with the genuine bot, and it misses any bot that hides its name. To act only on verified requests, check the IP address as described in How to verify AI crawlers. Agents that run in a person's own browser carry no bot token, as How AI browser agents access websites explains.

#Rule out methods that do not block

These methods stop no crawling, so a policy that relies on them leaves content open to the bots you meant to block.

  • A noai or noimageai meta tag has no standard behind it. Meta says it supports robots.txt "rather than non-standard formats like NoAI tags."8 Google's robots meta tag specification lists its valid rules, and noai is not among them.12 The crawler pages of OpenAI, Anthropic, Perplexity, Common Crawl and ByteDance do not mention it.
  • Some operators document their own page-level tags, which limit use and do not stop crawling. Google says nosnippet prevents content from being used as a direct input for AI Overviews and AI Mode.12 Apple says it does not use nosnippet content as context for AI-generated output, and that Applebot can still crawl the page.5
  • Microsoft says it honors <meta name="Bingbot" content="ai-training:disallow"> and an ai-grounding tag from February 1, 2027. It says these settings govern use of content and do not control crawl access.13
  • A tag on a page that robots.txt disallows is never read. Google says indexing and serving rules on a URL that is disallowed from crawling will not be found.12
  • Google-Extended and Applebot-Extended rules stop no requests. To stop the crawling, a site has to block Googlebot or Applebot, which also removes it from their search results.3 5
  • robots.txt does not keep content private. RFC 9309 says the protocol "is not a substitute for valid content security measures" and recommends HTTP authentication.11

#Test the result

  1. Run the robots.txt checker for AI crawlers on each host. It shows which bots each rule allows or blocks, and the rule that decides each result.
  2. Fetch the file as a bot: curl -sI -A "GPTBot" https://example.com/robots.txt. The answer should be 200 even when GPTBot is blocked elsewhere, which confirms the bot can still read your opt-out.
  3. Test an edge or server rule with curl -sI -A "GPTBot" https://example.com/. A rule that matches the user agent alone returns 403. A rule that also checks the IP address lets your own request through.
  4. Wait at least 24 hours before you judge the result, because cached copies of robots.txt can take that long to expire. That way you are not judging a change that has only half applied.
  5. Load the access logs into the AI crawler log analyzer. Check that verified requests from blocked bots stop or receive 403, and that robots.txt requests still get 200. Log file analysis for AI crawlers explains the fields to read.

Questions

Which robots.txt rules block AI bots?

A group that names the bot's token, followed by Disallow: /. For example, User-agent: GPTBot on one line and Disallow: / on the next asks OpenAI's training crawler to stay away from the whole site. Each bot follows only the group that names it, so list every token you mean to block.

Can a noai meta tag block AI crawlers?

No operator in this guide documents support for it. Meta says it uses robots.txt rather than NoAI tags, and noai is not among the rules Google lists. Google, Microsoft and Apple document their own tags, such as nosnippet and Bingbot ai-training, which limit how content is used and do not stop crawling.

Should I block AI crawlers in robots.txt or in a firewall?

Use robots.txt for bots that follow it, and add a firewall rule for fetchers that ignore it or when you want requests refused. Let every bot fetch /robots.txt. Anthropic warns that an IP block can stop its bots from reading the file, so the opt-out may not work.

Does a block remove content an AI company already collected?

Anthropic says a ClaudeBot restriction covers the site's future materials. OpenAI's and Common Crawl's crawler pages do not say whether a block affects content collected before the rule was added.

Notes

  1. 1
    Overview of OpenAI CrawlersOpenAI · Checked Nov 23, 2026 · Primary source
  2. 2
    Does Anthropic crawl data from the web, and how can site owners block the crawler?Anthropic Help Center · Checked Nov 23, 2026 · Primary source
  3. 3
    List of Google's common crawlersGoogle for Developers · Oct 30, 2026 · Checked Nov 20, 2026 · Primary source
  4. 4
    Perplexity CrawlersPerplexity · Checked Nov 20, 2026 · Primary source
  5. 5
    About ApplebotApple Support · Sep 4, 2026 · Checked Nov 20, 2026 · Primary source
  6. 6
    Frequently Asked QuestionsCommon Crawl · Checked Nov 20, 2026 · Primary source
  7. 7
    CCBotCommon Crawl · Checked Nov 20, 2026 · Primary source
  8. 8
    Meta Web CrawlersMeta for Developers · May 21, 2026 · Checked Nov 20, 2026 · Primary source
  9. 9
    关于Bytespider (About Bytespider)Toutiao Search Webmaster Platform (ByteDance) · Checked Nov 20, 2026 · Primary source
  10. 10
    Have it both ways: stay discoverable in search while disallowing AI trainingCloudflare · Sep 15, 2026 · Checked Nov 23, 2026 · Primary source
  11. 11
    RFC 9309: Robots Exclusion ProtocolIETF · Sep 1, 2022 · Checked Nov 23, 2026 · Primary source
  12. 12
    Robots meta tag, data-nosnippet, and X-Robots-Tag specificationsGoogle Search Central · Mar 24, 2026 · Checked Nov 20, 2026 · Primary source
  13. 13
    Your content, your choice: clearer preferences for training and groundingMicrosoft Bing Blogs · Oct 30, 2026 · Checked Nov 20, 2026 · Primary source

About this page

Researched and reviewed by Promptly Found. Reviewed Nov 23, 2026. Next review due Feb 2027.

Cite this page
Citation style

Promptly Found. (2026, November 23). How to block AI crawlers https://promptlyfound.com/crawlers/block-ai-crawlers

Revisions 2
Rewrote the description, short answer and opening sentence around blocking AI bots with robots.txt, and added an FAQ item on the rules that block them.
First published.