Robots Meta Tag Generator

Create a robots meta tag for index, follow, snippet and image-preview directives.

Short answer: A robots meta tag is one line in a page's HTML, for example <meta name="robots" content="noindex, follow">, that tells search engines whether to index the page, follow its links and how much of it to show as a snippet or image preview. This meta robots generator combines four choices into one comma-separated tag you can paste into the <head>. For PDFs, images and other non-HTML files, send the same rules in an X-Robots-Tag HTTP header instead.

How to use the robots meta tag generator

  1. Indexing: keep index for pages you want in search, or choose noindex to keep the page out of results.
  2. Links: keep follow so crawlers can discover pages linked from this one, or choose nofollow.
  3. Snippet: "No limit" outputs max-snippet:-1 (Google chooses the length); "No snippet" outputs nosnippet.
  4. Image preview: max-image-preview:large, standard or none.
  5. Click Copy tag and paste it inside the page's <head>, or into the "advanced robots" field of your SEO plugin.
  6. After publishing, open the URL in Google Search Console's URL Inspection tool and check the crawled HTML shows the tag. If the URL is blocked in robots.txt, Google never sees it (more on that below).

The syntax, explained with a real example

With the default settings the tool produces:

<meta name="robots" content="index, follow, max-snippet:-1, max-image-preview:large">
  • name="robots" addresses every crawler. Use name="googlebot" to address only Google; Google also honours googlebot-news and ignores other user-agent names in this tag.
  • index, follow are Google's defaults, so writing them changes nothing. They are still useful as documentation that the page is meant to be indexed.
  • max-snippet:-1 lets Google pick the snippet length; max-image-preview:large allows a large image preview, which matters for visual results and Discover.
  • Rules are comma-separated and case-insensitive. Where two rules conflict, Google applies the more restrictive one.

Worked example — a Noida real-estate developer. The site has a lead form that redirects to /thank-you.html. If that page is indexed, people land on it from search and every visit fires the "lead" conversion. At a ₹1,200 cost per lead, just 30 such false conversions a month make the campaign look ₹36,000 cheaper per month than it is (30 × ₹1,200). The fix is:

<meta name="robots" content="noindex, follow">

The page stays out of results, while links on it (back to projects) can still be followed. The same developer runs a festive "₹5 lakh off on booking" page that ends on 31 December 2026. The generator's four dropdowns don't include an expiry rule, so add it by hand:

<meta name="robots" content="max-image-preview:large, unavailable_after: 2026-12-31">

After that date Google stops showing the page, and it crawls it far less often.

Complete robots directive reference

Every rule below is documented in Google Search Central's robots meta tag specification. Other search engines may interpret some of them differently.

DirectiveWhat it doesNotes
allNo restrictions. The default; listing it has no effect.
noindexDo not show this page, media or resource in search results.Most-used rule; the page must stay crawlable for it to be seen.
nofollowDo not follow the links on this page.Page-level. Use rel="nofollow" on individual links instead.
noneSame as noindex, nofollow.
nosnippetNo text snippet or video preview. A static thumbnail may still show.Also stops the content being used as direct input for AI Overviews and AI Mode.
max-snippet:[number]Maximum snippet length in characters.0 = nosnippet; -1 = no limit.
max-image-preview:[setting]Maximum image preview size: none, standard or large.large can be up to the viewport width.
max-video-preview:[number]Maximum video preview in seconds.0 = static image only; -1 = no limit.
notranslateDo not offer a translation of the title link and snippet.
noimageindexDo not index images on this page.Images linked from elsewhere can still be indexed via those pages.
unavailable_after:[date]Stop showing the page after a date/time.RFC 822, RFC 850 or ISO 8601 format; invalid dates are ignored.
indexifembeddedAllow content embedded in another page (iframe) to be indexed despite noindex.Only works together with noindex.
noarchive, nocache, nositelinkssearchboxIgnored by Google Search today.The cached-link and sitelinks search box features no longer exist.

data-nosnippet: hide part of a page from snippets

To keep one block out of snippets (a price disclaimer, say) without affecting the whole page, add the boolean data-nosnippet attribute. Google accepts it only on span, div and section elements, and the HTML must be properly closed or the exclusion runs on into the rest of the page:

<div data-nosnippet>Prices exclude GST and registration charges.</div>

X-Robots-Tag header examples for Apache and Nginx

A PDF brochure or price list has no <head>, so the rule goes in the HTTP response header. Any rule valid in the meta tag is valid here. Apache (.htaccess or server config):

<Files ~ "\.pdf$">
  Header set X-Robots-Tag "noindex, nofollow"
</Files>

Nginx (inside the relevant server block):

location ~* \.pdf$ {
  add_header X-Robots-Tag "noindex, nofollow";
}

To target Google only, prefix the user agent: X-Robots-Tag: googlebot: noindex. Check the live header with curl -I https://example.com/brochure.pdf.

robots.txt vs meta robots: which one to use

robots.txtMeta robots / X-Robots-Tag
ControlsCrawling (whether a URL is fetched)Indexing and how the result is shown
Keeps a page out of results?No. A blocked URL can still be indexed, without a description, if other pages link to itYes, with noindex
ScopeWhole folders or URL patternsOne page or file type
Best forStopping crawl waste on filters, internal search, cartsThank-you pages, thin tag pages, staging, PDFs

Google's robots.txt introduction states plainly that robots.txt "is not a mechanism for keeping a web page out of Google". Never combine the two on one URL: if robots.txt blocks a page, Google cannot read its noindex.

Common mistakes and how to fix them

  • Staging noindex goes live. WordPress's "Discourage search engines" setting outputs a noindex tag; a redesign launched with it on can drop a site from Google within weeks. Check the live source after every launch.
  • Disallow plus noindex. Remove the robots.txt block until Google has recrawled and dropped the page, then re-block if you need to.
  • Two conflicting tags. A theme outputs index and a plugin outputs noindex: the restrictive one wins. Keep a single source of robots tags.
  • Using nosnippet to "protect" content. It removes your description from results and from AI Overviews input, which usually cuts clicks. Use data-nosnippet on the specific block instead.
  • Expecting instant removal. noindex takes effect only when the page is recrawled. For urgent cases use Search Console's Removals tool as a temporary measure.
  • Relying on noarchive. Google no longer uses it; it does nothing.

Practical use cases

  • D2C store: noindex, follow on internal search results and thin filter combinations, so product pages keep getting discovered.
  • Clinic or hospital: noindex on appointment-confirmation and patient-portal login pages.
  • B2B SaaS: X-Robots-Tag noindex on gated whitepaper PDFs so the landing page, not the file, ranks.
  • Publisher or blog: max-image-preview:large on articles to be eligible for large image previews.
  • Education institute: unavailable_after on last year's admission-date pages.

For a full crawl and indexing check, see our technical SEO audit checklist; if thank-you pages are inflating your numbers, read how to fix duplicate conversions in GA4 and Google Ads. Writing titles too? Use the meta tag preview generator, or talk to our SEO team.

The generator runs entirely in your browser — nothing you select is sent to our servers.

Frequently asked questions

What is the difference between noindex and nofollow?

noindex tells search engines not to show the page in results. nofollow tells them not to follow the links on that page. They are independent: "noindex, follow" hides a thank-you page but still lets crawlers reach the pages it links to, while "index, nofollow" keeps the page in search but stops link discovery from it. Most pages need neither.

Can I put noindex in robots.txt?

No. Google stopped supporting a noindex rule inside robots.txt in 2019. robots.txt only controls crawling. To keep a page out of results, use a robots meta tag or an X-Robots-Tag header, and make sure the URL is not disallowed in robots.txt, otherwise Google cannot fetch the page to see your noindex rule.

How long does noindex take to remove a page from Google?

It applies the next time Googlebot recrawls the page, which can be days for active pages and weeks for rarely crawled ones. Requesting indexing in Search Console's URL Inspection tool can speed up the recrawl. For urgent removals, use the Removals tool, which hides a URL temporarily while the noindex takes permanent effect.

What does max-image-preview:large do?

It allows Google to show a large image preview for the page, up to the width of the viewport, instead of a small thumbnail. It does not guarantee a large image will appear. Publishers and blogs usually set it so articles are eligible for prominent images in Discover and other visual results. Use "none" to block image previews entirely.

Where should I place the robots meta tag?

Place it inside the head section of the page's HTML, ideally once. Google says it also reads robots meta tags in the body, but head placement is the standard and is what other crawlers expect. In WordPress, set it through your SEO plugin's advanced settings for the page rather than editing theme files, so plugin and theme tags do not conflict.

Is the robots meta tag case-sensitive?

No. Google treats the name and content attributes, and the rule values, as case-insensitive, so "NOINDEX" and "noindex" behave the same. The same applies to the X-Robots-Tag header name and values. Lowercase is still the convention because it is easier to audit and matches the examples in Google's documentation and most SEO plugins.