The Robots Exclusion Protocol dates from 1994 and became an IETF standard, RFC 9309, in 2022. The file must live at /robots.txt on each host and protocol: https://example.com/robots.txt does not cover https://shop.example.com/.
Syntax
Groups start with one or more User-agent lines followed by Allow and Disallow rules. A crawler follows the most specific group that matches its name. Within a group, the longest matching path wins.
User-agent: *
Disallow: /cart/
Disallow: /search
Allow: /search/help
User-agent: GPTBot
Disallow: /
Sitemap: https://example.com/sitemap.xml
Crawling is not indexing
A URL blocked in robots.txt can still appear in Google results if other pages link to it. Google just shows it without a description. To keep a page out of the index, allow crawling and use a noindex meta tag or header. If you block the URL, Google never sees the noindex.
Why it matters for AI
robots.txt is the main switch for AI crawlers. Each vendor publishes its user agents, and most separate training from search, so you can make choices bot by bot.
Common mistakes
Disallow: /left over from a staging site after launch.- Blocking CSS or JavaScript files that Googlebot needs to render the page.
- Using robots.txt to hide private content. The file is public and the rules are advisory.
- Forgetting that CDN bot rules can override what robots.txt allows.
How Renderly handles it
We review robots.txt, CDN rules and server logs together. See AI crawlers and our technical SEO service.