Technical SEO

Robots.txt in Google Search Console

Your robots.txt file tells search engine crawlers which pages they are allowed (or not allowed) to crawl. Here is how it relates to Google Search Console:

The robots.txt report in Google Search Console settings listing the robots.txt file of each host with the date it was checked, its fetch status and its size
robots.txt stops crawling, not indexing. To keep a page out of the index you need noindex, and Google has to be able to crawl it.

Checking Your Robots.txt

Visit https://yourdomain.com/robots.txt directly in your browser. You should see a plain text file.

Checking If a Specific Page Is Blocked

Use the URL Inspection tool in Search Console - it will specifically tell you if a page is "Blocked by robots.txt" under the crawl details section.

Best Practices for Robots.txt

  • Do NOT block pages you want indexed (including CSS and JS files)
  • Block admin panels, login pages, thank-you pages, duplicate parameter URLs
  • List your sitemap URL in robots.txt: Sitemap: https://yourdomain.com/sitemap.xml
  • Never use robots.txt to hide a page from search - use noindex instead (blocked pages can still appear in search if they have links pointing to them)

Robots.txt Tester

Google retired the old Robots.txt Tester and replaced it with the robots.txt report under Settings. That report shows the robots.txt files Google found for your site, when it last crawled them and any warnings or errors, and it lets you request a recrawl after an urgent fix. It cannot test whether a particular URL is allowed, though. For that, check your rules against the URL with my free robots.txt tester, or inspect the URL in Search Console to see whether Googlebot was blocked.

Get more from your Search Console data

Start turning your Search Console data into growth today. No credit card needed.

Start 7-day free trial

Search Console tips in your inbox

Practical GSC and GA4 workflows, product updates and SEO experiments. No spam, unsubscribe anytime.