noindex vs robots.txt
robots.txt controls crawling — whether a bot may fetch a URL. A noindex tag controls indexing — whether the page may appear in results. They are not interchangeable, and combining them backfires: a URL blocked in robots.txt is never fetched, so the noindex on it is never read, and the page can remain listed indefinitely.
robots.txt Generator
Build a valid robots.txt, with or without the AI crawlers.
This is the most consequential misunderstanding in technical SEO, because the intuitive fix makes the problem permanent. Someone finds a page they want out of Google, blocks it in robots.txt, and it stays in the index — often for years — as a bare URL with no title or description.
The reason is mechanical rather than mysterious. Google can list a URL it has never fetched, if other pages link to it. Blocking the fetch removes the only channel through which you could have told it not to.
What each one actually does
- robots.txt Disallow: do not fetch this URL. Says nothing about indexing.
- noindex meta tag or X-Robots-Tag header: you may fetch this, but do not list it.
- The crucial asymmetry: a URL can be indexed without ever being crawled, from links alone.
Why combining them fails
To act on a noindex, a crawler has to read it, and to read it, it has to fetch the page. If robots.txt forbids the fetch, the noindex is invisible. The page stays in the index, usually showing just a URL with a note that no description is available — which is worse than either outcome you intended. If a page is already indexed and you want it gone, allow crawling, serve noindex, wait for it to be recrawled and dropped, and only then block it if you still want to.
When to use robots.txt
To save crawl budget on things that are worthless to fetch and that nobody links to.
- Infinite or near-infinite URL spaces — faceted filters, calendars, search results.
- Internal endpoints, health checks and asset paths with no standalone content.
- Reducing load from an aggressive crawler on an expensive path.
When to use noindex
Whenever the goal is that the page does not appear in search results.
- Thin or duplicate pages you still want reachable by visitors.
- Staging or preview URLs that must stay accessible to the team.
- Search result pages, paginated archives and tag pages of little standalone value.
- Anything already indexed that you want removed.
Neither is a security measure
robots.txt is public and lists the paths you care about, so it advertises them. A noindex keeps a page out of results but leaves it fully reachable by anyone with the URL. If a page must not be seen, put it behind authentication — those are the only two tools here, and neither restricts access.
The canonical tag is a third thing
A canonical says "this content also lives at that URL, index that one instead". It is a consolidation hint for duplicates, not an exclusion. Use it for tracking-parameter variants and printer-friendly pages, where you want the ranking signals merged rather than the page suppressed.
Frequently asked questions
I blocked a page in robots.txt and it is still in Google. Why?
Can I use both on the same page?
What is X-Robots-Tag?
Does noindex waste crawl budget?
Where does the canonical tag fit?
Tools used in this guide
All tools →- robots.txt Generator Build a valid robots.txt, with or without the AI crawlers. In your browser
- Meta Tag Generator Generate the meta, Open Graph and Twitter tags for a page. In your browser
- HTTP Header Checker Inspect the response headers and status a URL returns. Server-side
- URL Redirect Checker Follow a redirect chain and see every hop. Server-side
- URL Parser Split a URL into its scheme, host, path, query and fragment. In your browser
Related guides
All guides →- How to Write a robots.txt Control crawling correctly, and understand what the file cannot do.
- How to Write Meta Tags The head tags that actually matter, what to put in them, and the ones to ignore.
- How to Check HTTP Redirects Trace a URL through every hop to its destination, and tell a permanent redirect from a temporary one.
Last reviewed .