Skip to the tool
OnPageKit

Meta Robots Tag Generator

Build robots directives as a meta tag or an X-Robots-Tag header.

comma separated

robots is the catch-all token. A crawler that has a line of its own reads only that line, so naming googlebot means Bing keeps following the generic one.

characters, -1 for no limit
seconds, -1 for no limit
date, or date and offset

Tick it if you already have a Disallow line covering this path. The tool cannot fetch your robots.txt, and the combination is the one mistake that quietly leaves a page in the index.

1 tag(s)
<meta name="robots" content="index, follow">
for PDFs, images and any non-HTML response
<IfModule mod_headers.c>
  Header set X-Robots-Tag "index, follow"
</IfModule>

Directives in play: index, follow

  • index, follow is what a crawler assumes when no tag is present, so this one states the default and changes nothing.

Everything runs in your browser. Nothing you type is sent to a server.

Found a bug in this tool? Report it.

Share this tool

What this meta robots tag generator produces

This meta robots tag generator turns a set of choices about indexing into two things at once: the <meta name="robots"> element for the head of an HTML page, and the equivalent X-Robots-Tag response header written out for Apache and for Nginx. The directives are identical in both. What differs is where they can live, and that difference is the whole reason the header exists.

Tick the boxes, name the crawlers you want to address, and the output updates as you go. Anything contradictory is called out underneath — a snippet limit sitting next to nosnippet, an expiry date on a page already excluded, a token written with a capital letter that no crawler will match.

Crawling and indexing are different switches

The single most expensive misunderstanding in on-page SEO is treating robots.txt and this tag as two ways of saying the same thing. They are not. A Disallow line stops the fetch. This tag is read after the fetch, from inside the response.

Follow that through and the consequence is uncomfortable: a URL blocked in robots.txt can still appear in results, listed by its address alone with no title of yours, because Google learned about it from a link somewhere and was never allowed to read the page that says keep it out. So if the goal is genuine removal, the crawl has to be permitted first. Build the crawl rules with the robots.txt generator, then let the tag decide what happens to the page once it has been read. The tool has a checkbox for the blocked case for exactly this reason.

The default is index, follow — and it is implicit

No tag at all means index and follow. Both are assumed. Writing them out is not wrong, but it is also not doing anything, which is why the tool marks the empty state with a note rather than pretending it produced something useful. The tag earns its place the moment you deviate: a thin tag archive, a search results page, an internal staging copy, a thank-you page that has no business being found by strangers.

The preview directives nobody configures

max-snippet takes a character count, with -1 for no ceiling and 0 for no snippet at all. max-image-preview takes none, standard or large. max-video-preview counts seconds. These arrived together in 2019 as the response to European press publishers' rights, and most sites have never touched them — which is itself a decision, because the default in the EU is that Google shows what it likes within its own limits.

Two of them are worth deliberate thought. max-image-preview:large is what gets a picture shown at full width in Discover, and a publisher who leaves it unset is turning down that surface. A tight max-snippet on a paywalled article is how you stop the free preview from giving away the piece, though set it too tight and the result becomes unclickable.

Bot-specific tags, and one trap in them

Any crawler token can replace robots in the tag name: googlebot, bingbot, googlebot-news. The rule is that a crawler which finds a line addressed to it by name ignores the generic one entirely — it does not merge the two. So a page carrying <meta name="robots" content="noindex"> alongside <meta name="googlebot" content="max-snippet:50"> is telling Google to index it with a short snippet, and everyone else to stay away. That is almost never what the author meant.

When the page is finished, run it through the meta tag analyser to see the head as a crawler would, and make sure the canonical on the page agrees with it: a noindex page that other pages canonicalise to is a contradiction that resolves badly.

Frequently asked questions

Does noindex remove a page from Google straight away?

No, and the delay catches people out. The directive only takes effect the next time that URL is crawled, which for a low-traffic page can be weeks. If the removal is urgent, use the Removals tool in Search Console for the temporary hide and leave the tag in place to make it permanent.

Do I need index, follow on every page?

No. Those two are what a crawler assumes when it finds no tag at all, so writing them out changes nothing about how the page is treated. Plenty of CMS templates emit them anyway, which is harmless but means the tag tells a reviewer nothing. Reserve the tag for pages where you are overriding the default.

What is the difference between nofollow in this tag and rel=nofollow on a link?

Scope. In the meta tag it covers every link the page contains, including your own navigation and footer, so a whole branch of the site loses its internal linking. On an anchor it covers that one destination. If you are discounting a specific paid or user-submitted link, the attribute is the right instrument.

When should I use X-Robots-Tag instead of the meta tag?

Whenever the response is not HTML. A PDF price list, a generated CSV, a raw image file: none of them has a head element to put a tag in, and all of them can be indexed. The header is also easier when the rule is by pattern, such as excluding an entire directory of downloads at the server rather than per file.

Can I put max-snippet on a page I have set to noindex?

The directives are compatible in syntax but pointless together. A snippet is the text under a result, and a page kept out of the index never produces a result. The tool flags the pairing because it usually means someone changed their mind about the page halfway through and left the old settings behind.

Related tools

Updated