Crawling, robots & indexing directives

HTTP Link rel="canonical" Header

An HTTP response header that declares a canonical URL without editing HTML—essential for consolidating PDFs, whitepapers and non-HTML downloads to their canonical HTML landing page.

Verified

Syntax / Example

HTTP/2 200 OK
content-type: application/pdf
Link: <https://www.example.com/reports/2026-study>; rel="canonical"

Verify On A Live URL

curl -sIL https://example.com/report.pdf | grep -i "^link:"
Metric or RuleDocumented ValueSource
Primary use caseCanonicalizing PDFs & non-HTML resourcesGoogle: Consolidate Duplicate URLs (Canonical)Checked November 25, 2026
Syntax requirementAbsolute URL inside angle brackets (<...>)Google: Consolidate Duplicate URLs (Canonical)Checked November 25, 2026
Google handling weightStrong hint (same as HTML rel=canonical)Google: Consolidate Duplicate URLs (Canonical)Checked November 25, 2026

Official Specification & Google Behavior

Documented by Google Search Central alongside RFC 6596 / RFC 8288. Google processes HTTP Link rel="canonical" headers with the same strong-hint weight as HTML <link rel="canonical"> tags.

SEO & Indexing Impact

Stops downloadable PDFs from cannibalizing your main HTML guide in Google Search and consolidates backlinks pointing at PDF files onto your canonical web page.

Backlink Monitoring Verdict
Invisible in View Source—run curl -sIL and inspect the Link response header whenever a linking PDF or document appears not to index cleanly.

Common Pitfalls

  • Sending conflicting canonicals—one in the HTTP Link header and a different URL inside the HTML <link rel="canonical"> tag.
  • Omitting angle brackets around the URL or using a relative path instead of an absolute https:// URL.

Frequently Asked Questions

How do you add a canonical tag to a PDF file?
Because PDF files have no HTML <head>, configure your web server or CDN to send the HTTP response header Link: <https://example.com/page>; rel="canonical".
Can I use both an HTML canonical tag and an HTTP Link canonical header?
Google recommends using one method consistently—or ensuring both emit the exact same absolute URL so Google does not ignore conflicting signals.
How do I verify an HTTP Link canonical header?
Run curl -sIL on the URL and inspect the returned HTTP headers for Link: <...>; rel="canonical".

Primary Sources

Verified

Related Research Guides