Block Search inde xing withnoindex
noindex
is a rule set with either a<meta>
tag or HTTP response header and is used to prevent inde xing content by search engines that
support thenoindex
rule, such as Google. When Googlebot crawls that page and
extracts the tag or header, Google will drop that page entirely from Google Search results,
regardless of whether other sites link to it.
Usingnoindex
is useful if you don't have root access to your server, as it
allows you to control access to your site on a page-by-page basis.
Implementingnoindex
There are two ways to implementnoindex
:as a<meta>
tag and
as an HTTP response header. They have the same effect; choose the method that is more
convenient for your site and appropriate for the content type. Specifying the
noindex
rule in the robots.txt file is not supported by Google.
You can also combine thenoindex
rule with other rules that control inde xing. For
example, you can join anofollow
hint with anoindex
rule:
<meta name= "robots" content= "noindex, nofollow"/>
.
<meta>
tag
To preventall search enginesthat support thenoindex
rule from inde xing
a page on your site, place the following<meta>
tag into the
<head>
section of your page:
<meta name= "robots"content=" noindex ">
To preventonly Google web crawlersfrom inde xing a page:
<meta name= "googlebot"content=" noindex ">
Be aware that some search engines might interpret the
noindex
rule differently. As a result, it is possible that your page might
still appear in results from other search engines.
Read more about thenoindex
<meta>
tag.
HTTP response header
Instead of a<meta>
tag, you can return anX-Robots-Tag
HTTP header with a value of eithernoindex
ornone
in your response.
A response header can be used for non-HTML resources, such as PDFs, video files, and image
files. Here's an example of an HTTP response with anX-Robots-Tag
header
instructing search engines not to index a page:
HTTP/1.1 200 OK (...) X-Robots-Tag: noindex (...)
Read more about thenoindex
response header.
Debuggingnoindex
issues
We have to crawl your page in order to see<meta>
tags and HTTP headers. If
a page is still appearing in results, it's probably because we haven't crawled the page since
you added thenoindex
rule. Depending on the importance of the page on the
internet, it may take months for Googlebot to revisit a page. You can request that Google
recrawl a page using the
URL Inspection tool.
If you need to remove a page of your site quickly from Google's search results, see our documentation about removals.
Another reason could also be that the robots.txt file is blocking the URL from Google web crawlers, so they can't see the tag. To unblock your page from Google, you must edit your robots.txt file.
Finally, make sure that thenoindex
rule is visible to Googlebot. To test if your
noindex
implementation is correct, use the
URL Inspection tool
to see the HTML that Googlebot received while crawling the page.
You can also use the
Page Inde xing report
in Search Console to monitor the pages on your site from which Googlebot extracted a
noindex
rule.