AI Bot Content Negotiation: Serving the Right Format to Every Crawler
HTTP content negotiation allows servers to serve different representations of the same resource based on client preferences. Browsers use content...
- HTTP content negotiation allows servers to serve different representations of the same resource based on client preferences.
- Every HTTP request includes Accept headers that indicate the client's preferred content types.
- Content negotiation is implemented at the server level using the Vary header and server-side format selection: Vary: Accept, User-Agent The Vary...
- One emerging pattern in 2025 is serving JSON-LD as direct responses to AI crawlers that express strong preferences for structured data.
- For AI crawlers that prefer plain text, consider offering a clean text endpoint.
- Proper Vary header configuration is essential for content negotiation to work with CDNs and caching layers.
- Track content negotiation performance through server logs.
- Content negotiation provides a mechanism to serve AI-optimized content without degrading the human experience.
HTTP content negotiation allows servers to serve different representations of the same resource based on client preferences. Browsers use content negotiation to request HTML, JSON, or XML. AI crawlers can use content negotiation to request machine-optimized content formats. Properly implemented...
What Content Negotiation Means for AI Crawlers

HTTP content negotiation allows servers to serve different representations of the same resource based on client preferences. Browsers use content negotiation to request HTML, JSON, or XML. AI crawlers can use content negotiation to request machine-optimized content formats. Properly implemented content negotiation ensures AI crawlers receive content in the most consumable format without sacrificing the human experience.
The Accept Header Opportunity

Every HTTP request includes Accept headers that indicate the client's preferred content types. AI crawlers send Accept headers that reveal their parsing preferences:
A standard browser sends Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8. AI crawlers send similar headers but may include additional preferences for machine-readable formats.
Google-Extended sends standard Accept headers that prioritize HTML but accept JSON and XML at lower quality values. OpenAI's crawlers send Accept headers that explicitly include application/json at a higher quality weight than typical browsers. Claude-Web sends Accept headers with strong preference for text/html but includes application/ld+json for structured data extraction.
By analyzing the Accept headers from AI crawlers, you can serve content variants optimized for each crawler's consumption patterns.
Server-Side Content Negotiation Implementation

Content negotiation is implemented at the server level using the Vary header and server-side format selection:
Vary: Accept, User-Agent
The Vary header tells caches that the response varies based on Accept and User-Agent headers. This ensures AI crawlers receive their optimized version while human visitors receive the standard HTML.
Server-side logic inspects the Accept header and selects the appropriate representation:
If the request is from an AI crawler and Accept includes application/ld+json with high priority, serve structured data as the primary representation. If the request is from an AI crawler and Accept includes text/plain, serve a clean text extraction optimized for LLM consumption. For standard browser requests, serve the full HTML with interactive features.
JSON-LD as a Content Negotiation Response
One emerging pattern in 2025 is serving JSON-LD as direct responses to AI crawlers that express strong preferences for structured data. When ChatGPT-User requests a page with Accept: application/ld+json, the server responds with a JSON-LD document containing all schema.org structured data for that page, including full entity graphs and relationship data.
This approach has several benefits:
AI models receive perfectly structured data with no HTML parsing required. The entity relationships are explicit and unambiguous. Page size is significantly reduced because HTML markup, CSS, and scripts are excluded. Content extraction is deterministic and repeatable.
The tradeoff is that the JSON-LD response must contain all content that the AI model needs. If your schema only includes metadata (title, date, author) but not the full article text, the AI model will miss the content.
Clean Text Extraction Endpoints
For AI crawlers that prefer plain text, consider offering a clean text endpoint. A URL like /page?format=text or a separate /page/plain endpoint returns only the extracted main content as plain text.
This endpoint should strip all HTML, CSS, scripts, navigation, sidebars, and ads. Return only the main content text with basic paragraph separation. Include metadata at the top (title, publication date, author) in a consistent format.
AI crawlers can be directed to these endpoints through content negotiation or through explicit links in the HTML <head>:
<link rel="alternate" type="text/plain" href="/page/plain" />
<link rel="alternate" type="application/ld+json" href="/page.json" />
Vary Header Best Practices
Proper Vary header configuration is essential for content negotiation to work with CDNs and caching layers. Without the Vary header, caches may serve the HTML version to AI crawlers or the text version to browsers.
The Vary header should include:
Acceptbecause the response format depends on the client's accepted content typesAccept-Encodingif you serve different compression formatsUser-Agentif you customize responses based on crawler identity
Be aware that broad Vary headers reduce cache efficiency. Each unique combination of Vary header values creates a separate cache entry. For high-traffic sites, consider using a separate subdomain or path for AI-optimized content to minimize cache fragmentation.
Monitoring Content Negotiation
Track content negotiation performance through server logs. Monitor which representations AI crawlers request and receive. Compare response sizes across representations. Ensure that AI-optimized representations contain at least as much content as the HTML version.
Set up alerts for negotiation failures. If a crawler requests a representation that cannot be served, log the failure and fall back to standard HTML.
Audit Closing
Content negotiation provides a mechanism to serve AI-optimized content without degrading the human experience. Audit your Accept header handling for AI crawler requests. Implement server-side content negotiation that serves JSON-LD or clean text to crawlers that express preferences for those formats. Configure Vary headers correctly for CDN compatibility. Test all representations for content completeness. Create explicit alternate links in page headers. Include content negotiation in your quarterly technical SEO audits.
References:
- MDN Web Docs. "HTTP Content Negotiation." 2025. https://developer.mozilla.org/en-US/docs/Web/HTTP/Content_negotiation
- OpenAI. "GPTBot Content Negotiation and Preferred Formats." 2025. https://platform.openai.com/docs/gptbot/content-negotiation
- Google Search Central. "Vary Header Configuration for Crawler Optimization." 2025. https://developers.google.com/search/docs/crawling-indexing/vary-header
- Anthropic. "Claude-Web Accepted Content Types and Format Preferences." 2025. https://docs.anthropic.com/en/docs/claude-web/content-formats