# What is a user agent?

> A user agent is the name a client sends with each HTTP request to identify itself, such as a browser or a crawler like GPTBot.

Canonical: https://promptlyfound.com/glossary/user-agent
Updated: 2026-12-01

## Short answer

A user agent is **the name that a client sends with each request to identify itself**, such as a browser or a crawler. HTTP carries it in the User-Agent header. AI crawlers put a short token such as GPTBot in that string, and robots.txt rules use the same token to address each bot.

## Key findings

- RFC 9110 says the User-Agent field value consists of one or more product identifiers, each a name with an optional version, and that a user agent should send it in each request unless configured not to. [1]
- RFC 9309 says a crawler's product token should be a substring of the identification string it sends, and that crawlers must match User-agent lines case-insensitively. [2]
- OpenAI says it may add a robots.txt marker to the GPTBot and OAI-SearchBot user agent strings when they fetch robots.txt files. [3]
- Google warns that the user agent string can be spoofed and tells site owners how to verify that a request came from Google. [4]

A user agent is the software that makes a web request, and the term also names the string that identifies it. Browsers and crawlers both send this string with each request. Sites use it to tell AI bots apart in their logs and to address each bot in robots.txt.

## What does a user agent string contain?

A user agent string names the software that sent a request, usually with its version. [RFC 9110](https://www.rfc-editor.org/rfc/rfc9110.html), the IETF standard for HTTP semantics, defines the User-Agent header field. Its value is one or more product identifiers, each a name with an optional version, and optional comments. The standard gives the example `CERN-LineMode/2.15 libwww/2.17b3`. It says a user agent should send the header in each request unless it is configured not to.[1]

AI crawlers add their own token to a browser-style string. [OpenAI's crawler overview](https://developers.openai.com/api/docs/bots) gives this example for GPTBot and says the version number may change:[3]

```
Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko); compatible; GPTBot/1.4; +https://openai.com/gptbot
```

## How does robots.txt use the user agent?

robots.txt addresses each crawler by a short product token taken from its user agent. [RFC 9309](https://www.rfc-editor.org/rfc/rfc9309.html) says a crawler's product token should be a substring of the identification string it sends, such as the User-Agent header. Crawlers must match the token case-insensitively to find the group of rules that applies to them.[2] A `User-agent: GPTBot` line in robots.txt therefore addresses the [GPTBot](https://promptlyfound.com/crawlers/gptbot) string above.

Some tokens have no crawler behind them. [Google's Google-Extended page](https://developers.google.com/crawling/docs/google-extended) says Google does not run a separate Google-Extended crawler. Its other crawlers record each page's Google-Extended status.[5]

## How does the user agent affect AI search?

The user agent tells a site which job a request serves. OpenAI uses GPTBot for training, OAI-SearchBot for ChatGPT search and ChatGPT-User for user requests.[3] A rule written for the wrong token can block a job that the site wanted to allow, such as search.

OpenAI also says it may add a `robots.txt` marker to the GPTBot and OAI-SearchBot strings when they fetch robots.txt files. The marker helps site owners tell those requests apart in logs that do not include paths.[3]

## Can a user agent be trusted?

A user agent alone does not prove who sent a request. [Google's list of user-triggered fetchers](https://developers.google.com/crawling/docs/crawlers-fetchers/google-user-triggered-fetchers) warns that the user agent string can be spoofed.[4] OpenAI publishes the IP addresses that each of its bots uses.[3] [How to verify AI crawlers by IP address and reverse DNS](https://promptlyfound.com/crawlers/verify-ai-crawlers) shows how to check a request against these lists.

## Sources

1. RFC 9110: HTTP Semantics. IETF. https://www.rfc-editor.org/rfc/rfc9110.html
2. RFC 9309: Robots Exclusion Protocol. IETF. https://www.rfc-editor.org/rfc/rfc9309.html
3. Overview of OpenAI Crawlers. OpenAI. https://developers.openai.com/api/docs/bots
4. List of Google user-triggered fetchers. Google for Developers, 2026-11-23. https://developers.google.com/crawling/docs/crawlers-fetchers/google-user-triggered-fetchers
5. Google-Extended. Google for Developers, 2026-11-24. https://developers.google.com/crawling/docs/google-extended

---

This is a plain-text copy of https://promptlyfound.com/glossary/user-agent from Promptly Found. The web page is the canonical version and includes the charts.
