Robots.txt Generator

Build a robots.txt file for your website in seconds. Pick a preset, tweak the fields, copy the result.
Allow all: every crawler is welcome. Good for public websites that want maximum visibility.

How robots.txt works

A robots.txt file is a plain-text file that lives at the root of your domain. When a crawler visits your site, it checks this file first to see which paths it's allowed to access. Googlebot, Bingbot, and most other search engine crawlers respect it.

The syntax

The file uses a simple line-based format. Each block starts with a User-agent: line to identify the crawler, followed by Allow: or Disallow: rules for that agent:

User-agent: * Allow: / User-agent: GPTBot Disallow: / User-agent: CCBot Disallow: /

The * is a wildcard that matches all crawlers. A more specific user-agent (like GPTBot or Googlebot) applies its own rules, and takes precedence over the wildcard block for that specific crawler.

Allow vs disallow

Allow: grants access to a path or set of paths. Disallow: blocks access. When both apply to the same path, the more specific rule wins โ€” so a Disallow: / followed by Allow: /public means everything is blocked except /public.

Paths can include wildcards: * matches any sequence of characters, and $ anchors to the end of the URL. Disallow: /*.pdf$ blocks every URL ending in .pdf.

Blocking AI crawlers

Since around 2023, many site owners have used robots.txt to block AI training crawlers. The most common bots and the companies that run them:

The Block AI bots preset blocks all of these while leaving regular search engines unaffected. Google will still index your site for search โ€” it just won't use the content for AI training.

What robots.txt can't do

A few important limitations:

Common questions

โ† Back to Your Online Helper