Robots.txt Tester
Robots.txt Tester
Check if any URL is allowed or blocked by your robots.txt rules — instantly
| Directive | Syntax Example | What It Does |
|---|---|---|
| User-agent | User-agent: Googlebot | Specifies which bot the rules below apply to |
| Disallow | Disallow: /admin/ | Blocks the bot from crawling matching paths |
| Allow | Allow: /public/ | Explicitly allows a path, overrides Disallow |
| Sitemap | Sitemap: https://site.com/sitemap.xml | Points bots to your XML sitemap location |
| Crawl-delay | Crawl-delay: 10 | Requests a delay (seconds) between bot requests |
| Wildcards (*) | Disallow: /*.pdf$ | Matches any characters in a path pattern |
How to Test Your robots.txt File and Fix Crawling Issues
🔑 Key Takeaways
- A single wrong line in robots.txt can accidentally block Googlebot from your entire site
- Allow rules always win over Disallow when both match the same URL
- Longer, more specific rules take priority over shorter, general rules
- Use this tester to verify every important URL before publishing your robots.txt
The robots.txt file sits at the root of every website and quietly controls which pages search engine bots are allowed to crawl. Get it right and Googlebot focuses on your most important content. Get it wrong and entire sections of your site can silently disappear from Google's index — sometimes for weeks before you notice. A robots.txt tester lets you verify your rules before they go live, so you can catch mistakes before they cause real SEO damage.
What Is robots.txt and Why Does It Matter for SEO?
The robots.txt file is a plain-text file that you place at https://yoursite.com/robots.txt. It uses a simple set of directives to tell crawlers which parts of your site they should and shouldn't visit. When Googlebot arrives at your domain, it reads this file first, before crawling anything else.
The most commonly used directives are User-agent (which bot the rule applies to), Disallow (paths to block), and Allow (paths to explicitly permit). A correctly configured robots.txt helps Google concentrate its crawl budget on your valuable pages, keeps private or duplicate content out of the index, and can speed up how quickly new pages get discovered.
How This Robots.txt Tester Works
Paste your robots.txt content into the text area, enter the URL you want to check, and choose which user-agent to simulate — Googlebot, Bingbot, GPTBot, or any other bot. Click Test URL and the tool parses your robots.txt, identifies every rule that applies to the chosen agent, checks each one against the URL, and tells you whether the URL is allowed or blocked — along with a step-by-step rule match log showing exactly which rule made the final decision.
How robots.txt Matching Rules Actually Work
Understanding the matching priority is the most important part of writing robots.txt correctly:
- Specificity wins: The longer rule (more specific) always takes priority over a shorter one. So
Allow: /admin/public/beatsDisallow: /admin/for the path/admin/public/. - Allow beats Disallow on equal length: If two rules of the same length match, Allow always wins.
- User-agent specificity: Rules under a named user-agent like
Googlebottake priority over rules under*(all agents) for that specific bot. - Wildcards: The
*character matches any sequence of characters in a path. The$character anchors the rule to the end of the URL.
User-agent: * Disallow: /private/ Allow: /private/press/ # Result: /private/page.html → BLOCKED # Result: /private/press/release.html → ALLOWED
Common robots.txt Mistakes That Hurt SEO
After working on dozens of websites, these are the most frequent robots.txt errors that cause real ranking problems:
- Blocking the whole site:
Disallow: /underUser-agent: *blocks every bot from everything. This is sometimes accidentally left from staging environments. - Blocking CSS and JS files: If search engines can't load your stylesheets and scripts, they can't render your pages properly, which can hurt how they understand and rank your content.
- Missing trailing slashes:
Disallow: /adminwill also block/administratorbecause it matches as a prefix. UseDisallow: /admin/with a trailing slash to target only the admin folder. - Case sensitivity: Paths in robots.txt are case-sensitive.
Disallow: /Blog/does not block/blog/.
Who Should Use a Robots.txt Tester
Any website owner, SEO specialist, or web developer who manages a robots.txt file should test it before deploying changes. It's especially important when launching a new site, migrating from staging to production, reorganizing site structure, or noticing unexpected drops in crawl coverage in Google Search Console. A quick test takes under a minute and can save weeks of indexing headaches.
Frequently Asked Questions
Does Googlebot always follow robots.txt rules?
Googlebot respects robots.txt for crawling, but it's not a security mechanism. Blocked URLs can still appear in search results if other pages link to them — Google just won't crawl their content. To prevent indexing entirely, you also need a noindex meta tag or HTTP header on the page itself.
What's the difference between robots.txt and meta robots?
robots.txt controls whether a bot can visit a URL at all (crawling). The <meta name="robots" content="noindex"> tag controls whether content from a visited URL gets added to the search index (indexing). You need both working correctly for full control over what Google sees.
Can I block AI bots like GPTBot with robots.txt?
Yes. OpenAI's GPTBot and other AI training crawlers respect robots.txt. Add User-agent: GPTBot followed by Disallow: / to block them from your entire site, or specify individual paths you want to protect.
Found this robots.txt tester useful? Bookmark it and test your rules every time you update your robots.txt — it only takes a minute and can save your rankings.
Comments (0)
Leave a Comment