Crawling, robots & indexing directives

X-Robots-Tag HTTP Header

An HTTP response header that enforces any robots directive (noindex, nofollow, nosnippet, unavailable_after) on HTML pages as well as non-HTML files like PDFs and images.

Verified

Syntax / Example

HTTP/2 200
X-Robots-Tag: noindex, nofollow

Verify On A Live URL

curl -sIL https://example.com/page/ | grep -i "^x-robots-tag"

Documented Facts For X-Robots-Tag HTTP Header

Metric or RuleDocumented ValueSource
Share of mobile pages sending X-Robots-Tag0.7%HTTP Archive Web Almanac 2025 (SEO Chapter)Checked November 25, 2026
Works on non-HTML files?Yes (PDFs, images, JSON, feeds)Google: Robots Meta Tag & X-Robots-TagChecked November 25, 2026
Visible in View Source?No — HTTP response header onlyGoogle: Robots Meta Tag & X-Robots-TagChecked November 25, 2026

Official Specification & Google Behavior

Google processes X-Robots-Tag identically to <meta name="robots">. It supports bot-specific prefixes (e.g., X-Robots-Tag: googlebot: nofollow) and overrides less restrictive HTML rules.

SEO & Indexing Impact

Can silently noindex or nofollow an entire directory or file type from server, CDN or reverse-proxy configuration without leaving a trace in page HTML.

Backlink Monitoring Verdict
Invisible in View Source and Chrome Elements Inspect. Always run curl -sIL or open Chrome DevTools Network tab to verify no X-Robots-Tag: nofollow or noindex header is sent.

Common Pitfalls

  • Staging environments or Vercel preview domains inject X-Robots-Tag: noindex; accidentally carrying that config to production deindexes the site.
  • Auditing a backlink solely in View Source misses an X-Robots-Tag: nofollow header.

Frequently Asked Questions

Why can't I see X-Robots-Tag in View Source?
Because X-Robots-Tag is sent in the HTTP response headers before the HTML body; use curl -I or the browser Network panel to inspect it.
Which wins if HTML meta robots says index and X-Robots-Tag says noindex?
Google applies the more restrictive directive, so noindex wins.
When is X-Robots-Tag better than a meta robots tag?
Use X-Robots-Tag for PDFs, images and other non-HTML resources, or for applying uniform rules across a directory at the server/CDN layer.

Primary Sources

Verified

Related Research Guides