A good crawler user agent has three parts: a unique bot name, a version number, and a link to a page about your bot. For example: ExampleBot/1.0 (+https://example.com/bot). Verification services reject generic user agents, because they can't be matched to one operator (Cloudflare).
What gets rejected
Cloudflare's verification rejects generic user-agent patterns and may stop you submitting until you fix yours. Its examples of generic patterns include (Cloudflare):
- library names:
python-requests,node-fetch,node,got,okhttp,GuzzleHttp,Go-http-client,Dart,fasthttp,cloudflare-go - browser names:
Google Chrome,Mozilla Firefox,Safari - tool names:
Nessus,uTorrent
These name the software, not the operator. Thousands of different bots send python-requests.
The three parts
| Part | Example | Why |
|---|---|---|
| Bot name | ExampleBot | Unique to you, so a site can match one rule to one operator |
| Version | /1.0 | Lets you and sites tell releases apart |
| Info link | (+https://example.com/bot) | Where a site owner learns what the bot does and how to block it |
Put the link in parentheses with a +, the convention major crawlers use.
Good examples
ExampleBot/1.0 (+https://example.com/bot)
ExampleMonitor/2.3 (+https://example.com/monitor; uptime checks)
ExampleSEOBot/1.4 (+https://example.com/seobot)Rules of thumb
- One purpose, one name. If you run a search crawler and a training crawler, give them different names. Sites block by purpose, and Cloudflare gives mixed-use crawlers the strictest treatment (TechCrunch).
- Keep the name stable. Site owners write rules against it. Change the version number, not the name.
- Don't pretend to be a browser. Vercel flags requests that claim to be a browser but don't behave like one (Vercel).
- Make the link work. The page should say what the bot does, which addresses or key directory it uses, how often it visits, and how to block it.
- Match it to your identity. Your user-agent pattern goes into your Cloudflare and Vercel submissions, alongside your IP list, reverse DNS domain or Web Bot Auth key directory.
A user agent isn't proof
Anyone can copy your user agent. That's why verification pairs it with something that can't be faked: a Web Bot Auth signature, or addresses that are provably yours through a published IP list or reverse DNS. The user agent says who you claim to be; the signature or addresses prove it.
Code: setting it in Python
import requests
session = requests.Session()
session.headers["User-Agent"] = "ExampleBot/1.0 (+https://example.com/bot)"
r = session.get("https://example.com/", timeout=10)PacketPaper's planned Bot ID plan includes a hosted public bot page for your user agent to link to, along with your key directory and applications. It's planned, not live yet. Join the waitlist.