One misplaced noindex can knock your best page out of Google. One broad robots.txt rule can hide a whole section of your site. And now that Google AI Overviews pull from indexed pages, what crawlers can and can’t see matters even more.
At Webplanners, our team of SEO consultants checks robots directives in every technical review. Stray tags are one of the most common things we find.
In this blog, we will understand how the robots meta tag and x-robots-tag work, how they differ from robots.txt, and how to control Google, AI Overviews and AI crawlers.
| robots.txt | Robots meta tag | X-Robots-Tag | |
|---|---|---|---|
| Where it lives | /robots.txt at the site root | In the page’s HTML head | In the HTTP response header |
| Controls | Crawling | Indexing and snippets | Indexing and snippets |
| Works on | Any URL path | HTML pages only | Any file type (PDFs, images, docs) |
| Scope | Site-wide patterns | One page | One URL, or patterns via server rules |
| Best for | Stopping crawl of whole sections | Noindexing individual pages | Noindexing non-HTML files at scale |
The key difference is simple. robots.txt controls crawling, while the meta robots tag and X-Robots-Tag control indexing. Most robots mistakes come from mixing those two jobs up.
Both do the same job in practice, but they’re added in different places, so the syntax looks a little different.
It goes in the head of the page:
<meta name=”robots” content=”noindex, follow”>
To speak to one crawler only, replace “robots” with its name, for example googlebot.
This one is sent as an HTTP header, so it’s usually set on the server:
X-Robots-Tag: noindex
Here’s how you’d cover every PDF on Apache using .htaccess:
<FilesMatch “\.pdf$”>
Header set X-Robots-Tag “noindex”
</FilesMatch>
Launch Without Hidden Indexing Mistakes
| Directive | What it does |
|---|---|
| noindex | Keeps the page out of search results |
| nofollow | Asks search engines not to follow links on the page |
| none | Same as noindex, nofollow |
| nosnippet | No text snippet or video preview in results (also limits use in AI Overviews) |
| max-snippet:[n] | Limits snippet length to n characters |
| max-image-preview:[none/standard/large] | Controls image preview size |
| max-video-preview:[n] | Limits video preview length in seconds |
| noimageindex | Stops images on the page being indexed |
| notranslate | No translation offered in results |
| unavailable_after:[date] | Removes the page from results after a set date |
| indexifembedded | Allows indexing of content embedded via iframe despite noindex |
If you only want to hide part of a page from snippets, use the data-nosnippet HTML attribute.

Getting noindex vs disallow wrong is the most common slip, though it’s not the only one.
Keep Your Best Pages In Google
PDFs, Word docs and images can’t hold a meta tag. So if you’re wondering how to noindex a pdf, the X-Robots-Tag header is the answer.
It’s a common fix for gated whitepapers, price lists and internal documents that shouldn’t turn up in search. One warning, though. Noindex hides a file from search results, but it doesn’t make it private. Anything truly sensitive needs a login, and a web security review can confirm your files are properly protected.

Most AI crawlers are managed in robots.txt by user agent:
User-agent: GPTBot
Disallow: /private/
User-agent: Google-Extended
Disallow: /
So decide section by section. Let public marketing content in and restrict anything premium or private. If you want your pages cited in AI Overviews and other AI answers, our AEO and GEO services build on exactly this kind of access.
Get Found In AI Answers
Use noindex when you want a page kept out of search results, and use disallow when you want to stop Google crawling low-value sections. Don’t combine them on a page you want removed. If robots.txt blocks the URL, Google can’t read the noindex tag, so the page may stay in results through links from other sites.
A robots meta tag sits in the HTML head of a single page. An X-Robots-Tag is sent in the HTTP response header, so it also works on PDFs, images and other files that can’t hold a tag. Both control indexing and snippets, and Google treats them the same way. Pick the one that fits the file type.
Add an X-Robots-Tag: noindex header to the PDF’s server response. On Apache, a FilesMatch rule in .htaccess covers every PDF at once. Don’t block the PDF in robots.txt as well, because Google needs to crawl the file to see the header.
No. Google-Extended controls whether your content is used for Gemini models, and it doesn’t affect Google Search rankings or AI Overviews. AI Overviews draw on pages that Google Search can index and show. To limit how your text appears there, use nosnippet or max-snippet on the page.
Yes. Both follow robots.txt, so you can allow or block each one by user agent. Blocking protects your content from AI use, but it can also keep your brand out of AI answers. Many businesses allow public pages and block only premium or private sections.
Couldn't be happier with how things have gone since working with Webplanners. The team genuinely cares about getting results and has helped us stay ahead of the competition. Thanks for all the hard work, legends!
Webplanners has been a huge part of our digital growth. Managing multiple websites isn't easy, but they've made the whole process feel effortless. The results have exceeded our expectations.
The team has been great to work with and always keeps us in the loop. We've seen steady improvements over time and the whole process has been straightforward. Very happy with how things are going.
Ready to Grow?
Copyright © 2026 www.webplanners.com.au All rights reserved.