Block GPTBot in robots.txt: Minimal Template

Use this template when your specific goal is to disallow GPTBot sitewide. It targets OpenAI’s training crawler only; it does not automatically block OAI-SearchBot, which controls ChatGPT Search crawling.

Independent technical reference Updated Editorial approach Report a correction
Training crawler route blocked at a website while a separate AI search discovery route remains open

Copy-paste robots.txt example

User-agent: GPTBot
Disallow: /

This is the smallest sitewide rule for the specific intent “block GPTBot”:

User-agent: GPTBot
Disallow: /

What this template blocks

The rule targets GPTBot, OpenAI’s crawler for content that may be used in generative AI foundation-model training. It does not create a provider-wide OpenAI block.

In particular, it does not automatically block OAI-SearchBot. That lets a publisher make a separate decision about appearing in ChatGPT Search.

Keep ChatGPT Search open if you want discovery

If your policy is “no GPTBot training crawl, but keep ChatGPT Search eligibility,” make the distinction explicit:

User-agent: GPTBot
Disallow: /

User-agent: OAI-SearchBot
Allow: /

OpenAI documents these controls independently. Do not add extra OpenAI user agents unless you have a separate reason for each one.

Test a real site policy rather than just the homepage

A site that blocks GPTBot from / can still have unrelated rules for other agents. Build the merged draft first, then test it with draft Checker using GPTBot and OAI-SearchBot for /, plus a private path such as /account/profile.

CrawlerPathIntended result with the example above
GPTBot/Blocked
OAI-SearchBot/Allowed by the example
OAI-SearchBot/account/profileAllowed unless you add a specific restriction

The final row is why copy-pasting only an Allow: / group can be unsafe for an existing configuration: specifically matched groups do not inherit a wildcard group’s path restrictions. Review the live rules, carry forward site-specific protections and re-test before deployment. Robots.txt never replaces authentication.

Before you paste it

  1. Merge the group into your existing /robots.txt; do not overwrite unrelated search-engine rules.
  2. Keep any existing Sitemap: directives and platform-specific rules.
  3. Publish the file on the exact hostname you want to control.
  4. Open the live file in a browser and test a public URL with the robots.txt Checker.

Need a broader OpenAI policy?

If your real requirement is to make different decisions for training and ChatGPT Search, use the OpenAI robots.txt controls template. If you want the factual reference behind this snippet, see GPTBot.

Block only part of the site

You do not have to disallow GPTBot everywhere. If only a specific public section should be excluded from GPTBot crawling, use a path rule instead:

User-agent: GPTBot
Disallow: /research-archive/

Test both a URL inside the blocked path and a normal public URL outside it. This catches prefix and path-matching mistakes before they affect more of the site than intended.

FAQ

Does blocking GPTBot block ChatGPT search?

No. OpenAI documents OAI-SearchBot as an independent search crawler. Keep OAI-SearchBot allowed if you want your pages eligible for ChatGPT search discovery.

Does blocking GPTBot remove previously collected content?

The robots.txt rule controls future compliant crawling. It does not by itself remove content collected before the rule was published.

How long does a GPTBot robots.txt change take to apply?

Provider systems need time to refresh robots.txt. OpenAI notes an adjustment period for crawler settings, so verify the public file and allow time for the change to propagate.

Can I block GPTBot only from selected directories?

Yes. Use path-specific Disallow rules for stable content areas, but protect genuinely private material with authentication rather than relying on a public path list.

Does GPTBot obey a wildcard group?

A wildcard group can apply when there is no more specific matching GPTBot group, but a dedicated GPTBot group is clearer and prevents accidental policy changes when other rules are edited.

Continue with the tools

Build a policy from the guidance above, then test the complete file that is actually published.

Related pages

Website blocking an AI training crawler while keeping a separate search discovery route open GPTBot: robots.txt Rules for OpenAI Training Crawling

GPTBot is OpenAI’s crawler for content that may be used to improve and train generative AI foundation models. Its robots.txt control is independent from OAI-SearchBot, which is used for ChatGPT Search visibility, and from user-triggered ChatGPT-User requests.

Separate GPTBot training and OAI-SearchBot search routes with independent website access controls GPTBot vs OAI-SearchBot: Training vs Search

GPTBot and OAI-SearchBot are separate OpenAI crawler controls. GPTBot crawls content that may be used to improve and train OpenAI’s generative AI foundation models; OAI-SearchBot discovers pages for ChatGPT search results. You can block one and allow the other.

Website selectively blocking AI training crawler routes while keeping search discovery routes open How to Block AI Crawlers with robots.txt

Block only the exact crawler names that match your policy, keep ordinary search and user-requested access separate when you still want them, publish the merged file at the correct host root, and verify each important crawler and path on the live site.

Website allowing an AI search discovery route while blocking a separate model-training route How to Allow AI Search but Block AI Training

Block only the documented training or product-use controls, such as GPTBot, ClaudeBot, Google-Extended, and Applebot-Extended. Leave AI search crawlers unblocked unless an existing rule blocks them; add explicit search groups only when necessary, and repeat any private-path restrictions inside those groups. Then test the live file by crawler and path.

Robots.txt checker inspecting a website and reporting allowed and blocked crawler access robots.txt Checker

Test the live robots.txt served by a website or paste unpublished rules to simulate a crawler across up to eight URL paths. Review the winning Allow or Disallow rule before deploying changes.