Noindex vs Disallow: Which One to Use

Disallow stops crawling. Noindex stops indexing. Mixing them up is one of the most common technical SEO errors. Here is when to use each, with exact code and checks.

You blocked a page in robots.txt. It is still showing up in Google.

Or you added noindex and nothing changed for weeks.

Both problems come from the same confusion: noindex vs disallow. They sound similar, but they control two different things. Get it wrong and you either leak pages you wanted hidden, or hide pages you wanted to rank.

Noindex vs disallow: the short answer

  • Disallow (in robots.txt) tells crawlers: do not fetch this URL. It controls crawling.
  • Noindex (meta tag or HTTP header) tells Google: you can fetch this, but do not keep it in search results. It controls indexing.

If your goal is “this page should not appear in Google”, noindex is usually the right tool. If your goal is “stop bots wasting time on these URLs”, disallow is the right tool.

Different goals. Different tools. That is the whole game.

What disallow actually does

Disallow lives in your robots.txt file at the root of the domain, for example yoursite.com/robots.txt.

Example:

User-agent: *
Disallow: /cart/
Disallow: /search/

Googlebot reads this and does not request those URLs. Simple.

Here’s the thing most beginners miss: blocking a crawl is not the same as removing from the index. If other pages or other websites link to a disallowed URL, Google can still index the bare URL without ever reading the page. You then see a result with no description, or the note that no information is available for the page.

In Search Console this shows up as Indexed, though blocked by robots.txt. You will find it under Indexing > Pages, in the list of reasons below the chart.

What noindex actually does

Noindex is an instruction on the page itself. There are two ways to send it.

Option 1: Meta robots tag in the head

<meta name=”robots” content=”noindex”>

Use this for normal HTML pages.

Option 2: X-Robots-Tag HTTP header

X-Robots-Tag: noindex

Use this for PDFs, images and other files that have no HTML head. It is set at server level (Apache, Nginx, or your CDN).

The key requirement: Google must be able to crawl the page to see the noindex. That one sentence explains almost every noindex failure I have debugged.

The trap: disallow plus noindex on the same URL

This is the classic mistake. Someone wants a page gone from Google, so they do both:

  • Add noindex to the page.
  • Add Disallow for the same URL in robots.txt.

Result: Googlebot is blocked, so it never loads the page, so it never sees the noindex. The URL can stay indexed indefinitely.

Also note: Google stopped supporting a noindex rule inside robots.txt back in 2019. Lines like “Noindex: /page/” in robots.txt do nothing for Google. If you find them in an old file, remove them and use a proper tag.

Which one should you use? A decision table

Situation Use Why
Thank-you pages, internal admin-style pages that should not rank Noindex Google can crawl, sees the tag, drops the page
Thin tag or filter pages you still want users to reach Noindex (often with follow) Keeps them out of search, links stay usable
PDF you do not want in search X-Robots-Tag header No HTML head to put a meta tag in
Endless parameter URLs, internal search results, cart paths Disallow Saves crawl effort on URLs with no value
Staging site Password protection first Neither tag is real security; a login is
Page deleted permanently 404/410 or a 301 redirect No need for either tag, see the redirect note below
Private or sensitive content Authentication Robots rules are requests, not locks

One honest rule of thumb I use: if the URL is already indexed, noindex. If you are worried about crawl waste on a huge site, disallow. Never both on the same URL at the same time.

Exact steps to noindex a page safely

  1. Confirm the page is crawlable. Paste your domain into the Robots.txt Checker and test the exact URL. It must be allowed.
  2. Add the noindex. In WordPress, most SEO plugins have a per-page “Allow search engines to show this page” toggle in the page settings. Otherwise add the meta tag in the head, or set the X-Robots-Tag header for files.
  3. Check the response. The page should return a 200 status. Use the HTTP Status Checker to confirm. A noindexed page that redirects or errors adds confusion.
  4. Inspect it in Search Console. Open URL Inspection, paste the URL, and click “Test live URL”. Under the crawl details you should see “Indexing allowed? No: ‘noindex’ detected in ‘robots’ meta tag” (or in the HTTP header).
  5. Request re-crawl. In the same URL Inspection view, click “Request indexing” so Google revisits sooner.
  6. Wait and monitor. Under Indexing > Pages, look for the reason “Excluded by ‘noindex’ tag”. The page moves there once Google has processed it. This can take days to weeks depending on how often Google crawls that URL.

How to fix a URL that is blocked but still indexed

This is the “I disallowed it and it is still in Google” repair. Follow the order.

  1. Remove the Disallow line for that URL (or its folder) in robots.txt.
  2. Add noindex to the page (meta tag or header).
  3. Test the live URL in URL Inspection to confirm Google can now fetch it and see the tag.
  4. Wait until Search Console shows the URL as excluded by noindex.
  5. Only then, if you really need to, add the Disallow back. Many sites do not need to.

Need it hidden urgently? Use Search Console > Removals > New request > Temporarily remove URL. Be clear on what this does: it hides the URL for roughly six months. It is not permanent. You still need noindex, a 404/410, or a login behind it.

What about deleted pages and redirects?

If a page is gone for good, you do not need noindex or disallow. Return a 404 or 410, or 301-redirect it to the closest relevant page if one exists.

Do not redirect everything to the homepage out of habit. Google can treat that like a soft 404. Check your chains and final destinations with the Redirect Checker.

A mistake I see freshers make

When I review beginner audits, there is one pattern I see again and again. The fresher finds low-value URLs in the index, opens robots.txt, adds Disallow lines, and writes “issue fixed” in the report.

Nothing is fixed. The URLs are still indexed, now with no snippet, and Google can no longer read the page to learn it should drop it.

On a client site last year, I traced a similar case: a set of filter pages that had been blocked months earlier were still sitting in the index. The cause was exactly the trap above. We opened the block, added noindex, confirmed with URL Inspection, and only revisited robots.txt after they dropped out.

The lesson: never report a fix until you have verified it in Search Console. Writing a rule is not the same as seeing the result.

Use server logs to see what Google really does

If you work on a big site, do not guess. Server logs show which URLs Googlebot actually requests. If you disallow a section, logs should show requests there dropping. If you noindex a section, Googlebot should still visit it, at least for a while, to see the tag.

You can upload a log sample into the Log File Analyzer to check this. It is the easiest way to move from “I think” to “I can see”.

Copy-paste checklist before you touch robots.txt or noindex

  • Do I want this URL out of search results, or just not crawled? (Write the goal down.)
  • Is the URL currently indexed? Check with URL Inspection or a site: search.
  • If I want it out of search, is the URL crawlable right now?
  • Am I using noindex on that URL, and not also disallowing it?
  • Is the status code 200 (not a redirect or error)?
  • Did I check that the noindex is not on important pages by accident, such as after a staging-to-live move? This is a real and common launch error.
  • Did I check sitemaps? Noindexed URLs should not sit in your XML sitemap.
  • Did I verify the result in Search Console after a few days, not just on the day I made the change?

What to do next

Pick one site you can legally look at (your own, a friend’s, a practice project). Open its robots.txt, list every Disallow rule, and for each one write down the goal behind it. If you cannot explain the goal, that is your first audit finding.

To place this inside a full workflow, read Your SEO Process. If you are stuck on a real indexing problem, bring it to the free WhatsApp community and ask. Someone has probably hit it before.

This article is based on my own work on client and in-house SEO projects since 2011. If something here doesn't match what you see on your site, write to me. I update posts when things change.