ai newsMi., 25. Nov.
EilmeldungYale’s Sonnenfeld: Nvidia is a ‘detriment’ to U.S. industrial might — not a champion

robots.txt for AI Crawlers: Keep the Search Bots, Decide on Training, and Verify Who Is Really Crawling

Most robots.txt advice for AI crawlers says "block GPTBot" and stops there. That blocks one of three different jobs, and the job decides what blocking costs you. This post lays out the trade-off, gives you a robots.txt that keeps AI search open, a way to test it, a one-liner that shows which AI bot

dev.toMontag 14:18 · 23.11.6 Min. Lesezeit

Most robots.txt advice for AI crawlers says "block GPTBot" and stops there. That blocks one of three different jobs, and the job decides what blocking costs you. This post lays out the trade-off, gives you a robots.txt that keeps AI search open, a way to test it, a one-liner that shows which AI bots hit your server and what they got back, and a 10-line check that tells a real crawler from something wearing its name.

The bot list itself, checked against every company's own docs on 23 November 2026, is in our AI crawler list. We built it, so treat this as our view, with the sources linked from every row.

Google is the odd one out: AI Overviews and AI Mode use the normal Search index, so Googlebot controls them. Google-Extended is a robots.txt token with no crawler behind it.

Here is what the first rows of the list look like, with the share of sites each bot reached in our logs (WordPress sites running the LovedByAI plugin, 23 October to 21 November 2026):

Most of the advice out there says "block GPTBot". We don't think that's the right default for most sites, so here are both sides.

If you block training bots (GPTBot, ClaudeBot, Google-Extended, CCBot and the rest):

For most small businesses we'd allow them, because being known to the model is the point. Publishers and sites whose content is the product often decide the other way. It's a real choice; the search bots are not.

The default we recommend keeps every crawler in:

# Everyone allowed: search bots, user-triggered fetchers, training bots and search engines. User-agent: * Allow: / Enter fullscreen mode Exit fullscreen mode If you decide to keep your content out of training, this optional variant blocks only the documented training tokens and leaves every AI search bot and fetcher allowed:

# OPTIONAL. Only if you decide to keep your content out of AI model training. # Trade-off: future models learn less about your business. User-agent: GPTBot User-agent: ClaudeBot User-agent: Google-Extended User-agent: Applebot-Extended User-agent: meta-externalagent User-agent: Amazonbot User-agent: CCBot User-agent: MistralAI-Training Disallow: / # Everyone else, including every AI search bot and fetcher, stays allowed. User-agent: * Allow: / Enter fullscreen mode Exit fullscreen mode Whatever you choose, never block the search bots (OAI-SearchBot, Claude-SearchBot, PerplexityBot) or the fetchers (ChatGPT-User, Claude-User, Perplexity-User). OpenAI says sites that opt out of OAI-SearchBot "will not be shown in ChatGPT search answers."

Python's standard library has a robots.txt parser, which is enough to catch a group that doesn't do what you meant:

# check_robots.py: which AI bots may fetch "/" under a robots.txt? import sys, urllib. robotparser BOTS = [ "OAI-SearchBot", "ChatGPT-User", "Claude-SearchBot", "Claude-User", "PerplexityBot", "Perplexity-User", "GPTBot", "ClaudeBot", "Google-Extended", "CCBot", "Googlebot", "Bingbot" ] rp = urllib. robotparser. RobotFileParser ( ) rp. parse ( open ( sys. argv [ 1 ] ). read ( ). splitlines ( ) ) for bot in BOTS: print ( f "{bot:<17} {'allowed' if rp.can_fetch(bot, '/') else 'BLOCKED'}" ) Enter fullscreen mode Exit fullscreen mode Run against the optional variant, it shows exactly what you'd be giving up and what stays open:

$ python3 check_robots.py robots-no-training.txt OAI-SearchBot allowed ChatGPT-User allowed Claude-SearchBot allowed Claude-User allowed PerplexityBot allowed Perplexity-User allowed GPTBot BLOCKED ClaudeBot BLOCKED Google-Extended BLOCKED CCBot BLOCKED Googlebot allowed Bingbot allowed Enter fullscreen mode Exit fullscreen mode On the default file every line says allowed. If a search bot or fetcher ever shows BLOCKED, fix that first.

Python's parser is a sanity check, not the spec. It does not implement every RFC 9309 rule (longest-match precedence, for one), so keep each bot in a single group as above and you avoid the cases where parsers disagree.

Probably not in robots.txt. In our checks of sites running the LovedByAI plugin (23 September to 22 November 2026), GPTBot was blocked in robots.txt on 4.8% of sites and ClaudeBot on 4.4%, against 0.5% for OAI-SearchBot and 0.4% for Claude-SearchBot. People aim robots.txt at training.

Firewalls don't make that distinction. Claude-SearchBot was refused at the server on 3.0% of sites, almost as often as ClaudeBot at 3.4%.

Our check sends each crawler's name from our own servers, so a firewall that verifies crawlers by IP can refuse us and still let the real one in. Read those firewall numbers as an upper bound.

This counts requests per AI crawler and HTTP status in a combined-format access log (nginx or Apache defaults):

#!/bin/sh # ai-bots.sh: requests and status per AI crawler in a combined-format access log. # Usage:./ai-bots.sh /var/log/nginx/access.log BOTS = 'OAI-SearchBot|ChatGPT-User|GPTBot|Claude-SearchBot|Claude-User|ClaudeBot|PerplexityBot|Perplexity-User|meta-webindexer|meta-externalfetcher|meta-externalagent|Amzn-SearchBot|Amazonbot|DuckAssistBot|MistralAI-User|CCBot|Bytespider' grep -oE "\" [0-9]{3}.*($BOTS)" "$1" \ | sed -E "s/^\" ([0-9]{3}).*($BOTS).*/\2 \1/" \ | sort | uniq -c | sort -rn Enter fullscreen mode Exit fullscreen mode On a small illustrative log (not real traffic):

$./ai-bots.sh access.log 2 OAI-SearchBot 200 1 PerplexityBot 200 1 GPTBot 403 1 Claude-SearchBot 200 1 ChatGPT-User 200 Enter fullscreen mode Exit fullscreen mode A 403 or 503 next to a search bot or fetcher is the thing to look for: that's a firewall rule costing you citations. The match is case-sensitive on purpose, so ClaudeBot's contact address ( claudebot@anthropic.com ) inside other user agents doesn't get counted as ClaudeBot.

A user agent is a claim. OpenAI, Anthropic, Perplexity, Google and others publish their crawler IP ranges as JSON, so checking a request takes ten lines:

# verify_ip.py: is this IP in a crawler's published ranges? # Usage: python3 verify_ip.py <ip> [list_url] import ipaddress, json, sys, urllib. request ip = ipaddress. ip_address ( sys. argv [ 1 ] ) url = sys. argv [ 2 ] if len ( sys. argv ) > 2 else "https://openai.com/searchbot.json" req = urllib. request. Request ( url, headers = { "User-Agent": "ip-check/1.0" } ) data = json. load ( urllib. request. urlopen ( req, timeout = 10 ) ) nets = [ ipaddress. ip_network ( p. get ( "ipv4Prefix" ) or p. get ( "ipv6Prefix" ) ) for p in data [ "prefixes" ] ] match = next ( ( n for n in nets if ip in n ), None ) print ( f "{ip}: {'verified, in ' + str(match) if match else 'NOT in the published list'} ({len(nets)} ranges checked)" ) Enter fullscreen mode Exit fullscreen mode Pipe in every IP that claimed to be OAI-SearchBot:

$ grep 'OAI-SearchBot' access.log | awk '{print $1}' | sort -u | xargs -n1 python3 verify_ip.py 104.210.140.129: verified, in 104.210.140.128/28 (39 ranges checked) 20.171.207.1: NOT in the published list (39 ranges checked) Enter fullscreen mode Exit fullscreen mode The same script works with https://claude.com/crawling/bots.json (Anthropic), https://www.perplexity.ai/perplexitybot.json and Google's googlebot.json, which share the prefixes format. Every list we found is linked from its row in the AI crawler list, and the whole table is a CSV if you want to generate your rules from it.

If you run a firewall, this is also the fix for the blocks above: allow the search bots and fetchers by their published ranges, not by name.

Full list, reach and block data, and the method: AI crawler list 2026 on lovedby.ai.

Quelle: dev.to (dev.to). Original öffnen