What is a Link header?
Expresses a typed relationship with another resource, e.g. rel="preload" or pagination links.
Link is a flexible way for a website to point to related resources directly in the HTTP response - preloading a critical font or stylesheet, pointing to the next and previous pages of a paginated API, or linking to a canonical URL, all without needing to parse the HTML body first. It's a small header with outsized performance impact when used for preloading, since the browser can start fetching a critical asset before it's even reached that point in the page.
Common use case
A paginated API includes Link headers with rel="next" and rel="prev" URLs, letting a client library page through results without needing to construct the next URL itself.
Example
Link: </style.css>; rel=preload; as=styleHistory
Part of the original HTTP/1.1 specification, RFC 2068 (1997), and significantly expanded by RFC 8288 (2017).
Did you know?
It's also what powers HTTP/2 Server Push in some setups, and later Early Hints (103) - both preload a critical asset before the browser would otherwise have discovered it by parsing the HTML.