RFC 8288 Link headers
Send Link headers on HTML responses to point agents at related resources (sitemap, llms.txt, MCP card, OpenAPI) without requiring them to parse HTML first.
On this page
- What are RFC 8288 Link headers?
- Why do RFC 8288 Link headers matter for AI agent discovery?
- Are RFC 8288 Link headers required for AI agents?
- What RFC 8288 says about Link headers
- What good RFC 8288 Link header implementation looks like
- How do I add RFC 8288 Link headers to my site?
- How can I test my RFC 8288 Link headers?
- Frequently asked questions
- Do RFC 8288 Link headers replace HTML <link> tags for agent discovery?
- Can e-commerce sites use RFC 8288 Link headers to improve product discovery by AI agents?
- How do RFC 8288 Link headers compare to meta tags for agent metadata?
- Do SaaS documentation sites benefit more from RFC 8288 Link headers than marketing sites?
- Can I use RFC 8288 Link headers with Vercel's edge config?
- Is rel="sitemap" officially registered for RFC 8288 Link headers?
- Do news publishers need RFC 8288 Link headers if they already have XML sitemaps?
- Can WordPress sites add RFC 8288 Link headers without plugins?
What are RFC 8288 Link headers?
RFC 8288 Link headers let you attach metadata about related resources directly in HTTP response headers, without requiring clients to parse the body of your HTML. Instead of an agent downloading your entire homepage, tokenizing it, and hunting for <link> tags or navigation elements, it can read a Link: header and immediately discover your sitemap, API spec, MCP card, or llms.txt file. It's a clean separation: headers for discovery, body for content.
The RFC 8288 format looks like Link: <https://example.com/sitemap.xml>; rel="sitemap". You can send multiple headers or comma-separate multiple links in one header. The rel attribute describes the relationship (sitemap, alternate, service-desc), and an optional type attribute declares the MIME type. For AI agents, this is a low-latency, parse-free way to answer "where's your API?" or "where's your agent-readable summary?"
Why do RFC 8288 Link headers matter for AI agent discovery?
Most agents today start by fetching your homepage HTML, then run heuristics or DOM parsing to find sitemaps, API docs, or markdown alternatives. That's slow, token-expensive, and fragile—your redesign might move a footer link and break discovery. Link headers short-circuit this: an agent's HTTP client reads the headers before even buffering the body. ChatGPT's web browsing, Perplexity's crawlers, and Claude's citation indexers can all recognize rel="sitemap" or rel="alternate" without loading a single kilobyte of HTML. That means faster indexing, lower costs for the agent operator, and fewer false positives from WAFs that flag aggressive DOM scraping.
For agentic commerce or B2B integrations, Link headers are a forcing function for good architecture. If your checkout flow or product catalog is agent-accessible, advertising rel="service-desc" with a pointer to your OpenAPI spec tells agents exactly where to look—no guessing, no scraping your JavaScript bundles for API endpoints. This directly improves agent installability (how easily an LLM can wire up your service as a tool) and citation rate (agents prefer sites they can parse reliably). It's a small investment with outsized leverage.
Are RFC 8288 Link headers required for AI agents?
This check is optional for most sites. RFC 8288 is a general-purpose standard; nothing in it mandates Link headers for agent discovery specifically. If your HTML is well-structured and your sitemap is linked in a <link rel="sitemap"> tag, most agents will find it eventually. But "eventually" is the problem: agents pay in tokens and latency for every byte of HTML they parse.
Link headers become recommended if you run a high-traffic API, a marketplace, or any site that wants to be cited or integrated by agents. They're also valuable if you serve multiple representations of the same resource (HTML, Markdown, JSON-LD) and want agents to discover the machine-readable version without heuristics. If you've already invested in llms.txt, MCP cards, or OpenAPI specs, Link headers are the last-mile polish that makes those artifacts trivially discoverable.
What RFC 8288 says about Link headers
RFC 8288 defines the Link: header as a way to convey typed relationships between resources. The core syntax:
Link: <URI-Reference>; rel="relation-type"; type="media-type"
- URI-Reference (required): Absolute or relative URL to the related resource.
- rel (required): The relationship type. IANA maintains a registry of link relations. Common values for agents:
sitemap,alternate,service-desc,describedby. - type (optional): MIME type of the target resource, e.g.,
application/json,text/markdown. - Multiple links: Separate with commas or send multiple
Link:headers.
Minimum valid example for agent discovery:
Link: </sitemap.xml>; rel="sitemap"
Link: </llms.txt>; rel="describedby"; type="text/plain"
Link: </api/openapi.json>; rel="service-desc"; type="application/json"
No agent-specific extensions exist yet, but conventions are emerging: rel="service-meta" for agent skill indexes, rel="alternate" with type="text/markdown" for markdown versions of pages.
What good RFC 8288 Link header implementation looks like
Anthropic's documentation and Stripe's API reference both use Link headers effectively, though exact headers vary. A realistic production example would look like:
HTTP/2 200
Content-Type: text/html; charset=utf-8
Link: </sitemap.xml>; rel="sitemap"
Link: </docs.md>; rel="alternate"; type="text/markdown"
Link: </openapi.yaml>; rel="service-desc"; type="application/vnd.oai.openapi"
Link: </mcp.json>; rel="service-meta"; type="application/json"
Companies like Cloudflare and Vercel increasingly add Link: headers for preload and prefetch use cases; the same infrastructure can advertise agent-readable resources. If your CDN already injects headers for performance, agent discovery is a one-line addition.
How do I add RFC 8288 Link headers to my site?
- Identify your agent-readable resources: sitemap.xml, llms.txt, OpenAPI spec, MCP card, markdown alternates.
- Add headers at the edge or origin:
- Cloudflare Workers: Use
response.headers.append('Link', '</sitemap.xml>; rel="sitemap"')in your edge function. - Next.js: Add custom headers in
next.config.js:module.exports = { async headers() { return [{ source: '/', headers: [ { key: 'Link', value: '</sitemap.xml>; rel="sitemap"' }, { key: 'Link', value: '</llms.txt>; rel="describedby"' }, ], }]; }, }; - Nginx: Use
add_header Link '</sitemap.xml>; rel="sitemap"';in your server block.
- Cloudflare Workers: Use
- Test with multiple links: Ensure your HTTP stack supports multiple
Link:headers or comma-separated values. - Document your conventions: If you invent a new
reltype for agent use (e.g.,rel="agent-skills"), document it in your llms.txt or developer docs.
How can I test my RFC 8288 Link headers?
curl -I https://yoursite.com/ | grep -i '^link:'
You should see one or more Link: headers with rel="sitemap", rel="alternate", or rel="service-desc". Or just run a free scan and we'll check this for you alongside 30+ other agent-readiness signals.
Frequently asked questions
Do RFC 8288 Link headers replace HTML <link> tags for agent discovery?
No, RFC 8288 Link headers complement rather than replace HTML <link> tags. Agents can parse both, but Link headers offer faster discovery since they're available before the HTML body is downloaded. For maximum compatibility, serve both: headers for speed-conscious agents and HTML tags as a fallback for traditional crawlers.
Can e-commerce sites use RFC 8288 Link headers to improve product discovery by AI agents?
Yes. E-commerce sites can use Link: headers with rel="service-desc" pointing to product API specs or rel="alternate" for JSON-LD product feeds. This lets agents like shopping assistants discover your catalog structure instantly without parsing HTML, improving citation rates and enabling faster product comparisons across competing retailers.
How do RFC 8288 Link headers compare to meta tags for agent metadata?
RFC 8288 Link headers are protocol-level while meta tags live in HTML. Link headers work before any HTML parsing, making them faster for agents to consume. Meta tags require downloading and tokenizing the page. For resource discovery (sitemap, service-desc), headers win. For page-specific metadata (descriptions, keywords), meta tags remain appropriate.
Do SaaS documentation sites benefit more from RFC 8288 Link headers than marketing sites?
Significantly more. SaaS docs typically serve multiple formats (HTML, Markdown, OpenAPI specs) and need agent integration. Using rel="service-desc" for API specs and rel="alternate" for markdown versions gives agents instant access to machine-readable documentation. Marketing sites gain less unless they're optimizing for agent-based product research or comparison engines.
Can I use RFC 8288 Link headers with Vercel's edge config?
Yes. Vercel supports custom headers in vercel.json or Edge Middleware. Add them in your config under the headers array with source matching your routes and key: 'Link' entries. For dynamic header injection based on routing logic, use Edge Middleware to append headers before the response reaches the client.
Is rel="sitemap" officially registered for RFC 8288 Link headers?
Yes, sitemap is in IANA's official link relations registry. Other agent-relevant relations include alternate, describedby, and service-desc. Emerging conventions like service-meta for MCP cards aren't yet registered, so document any custom rel values clearly in your documentation and consider proposing them to IANA.
Do news publishers need RFC 8288 Link headers if they already have XML sitemaps?
It's valuable but not critical. Publishers with real-time content benefit from Link: headers advertising news sitemaps (rel="sitemap") or AMP alternates (rel="amphtml"), letting agents discover fresh articles faster. For citation-focused agents indexing breaking news, headers reduce discovery latency from seconds to milliseconds, improving timeliness of agent-generated summaries.
Can WordPress sites add RFC 8288 Link headers without plugins?
Yes, via .htaccess (Apache) or functions.php. In .htaccess, use Header add Link "</sitemap.xml>; rel=sitemap". In functions.php, hook send_headers and call header('Link: </llms.txt>; rel="describedby"', false). The second parameter (false) prevents replacing existing Link headers. For multiple links, call header() multiple times or use comma-separated values.