Skip to content
Search
Search
Learn
Glossary
Research
Platforms
News
Tools
About

CloudflareFeature

Cloudflare converts pages to markdown at the edge for AI agents

On Pro plans and up, Cloudflare can answer an AI agent's request for text/markdown with a converted copy of your HTML page, with no change at your origin.

Published

#What is new

On February 12, 2026, Cloudflare launched Markdown for Agents. The announcement and changelog entry explain that on zones with the feature on, Cloudflare's network converts a page's HTML to markdown whenever a client asks for markdown. The documentation has since added custom content signals, path rules and analytics.

#How a request gets markdown

A client asks for markdown by including text/markdown in its Accept header. Cloudflare fetches the normal HTML from your origin, converts it and returns markdown. Every other visitor still gets HTML, and your origin never has to produce a second format.

Cloudflare says popular coding agents such as Claude Code and OpenCode already send this header. Its own announcement post took 16,180 tokens as HTML and 3,150 as markdown, an 80% cut.

The markdown follows a fixed layout:

  • YAML front matter built from your title, description and og:image meta tags. The standard <meta name> tags win over Open Graph ones.
  • The body, with headers, footers, navigation, scripts and styles stripped.
  • Every JSON-LD block on the page, joined in one fenced code block at the end.

Conversion works on HTML only, up to 6 MiB of decompressed HTML. Past a content limit, the output can be cut short or lose its front matter or JSON-LD.

#What the response headers say

HeaderOn the markdown response
Content-Typetext/markdown; charset=utf-8
VaryIncludes Accept, so caches keep markdown and HTML apart
Content-SignalYour origin's value if it sends one, otherwise ai-train=yes, search=yes, ai-input=yes
ETag, Last-ModifiedRemoved, so conditional requests can't be honored
Cache-Control, CSP, HSTS, Set-Cookie, CORSKept from your origin

The Content-Signal row is the one to watch. At launch every converted page carried the all-yes signal, and custom policies were promised for later. The current docs make your origin's header authoritative, so you can now send ai-train=no and the markdown copy keeps it.

Our read: a site that blocks training crawlers in robots.txt but leaves the default in place sends mixed signals. The markdown copy says yes to training while robots.txt says no.

#Who can turn it on

The feature is free on Pro, Business and Enterprise plans, and for SSL for SaaS customers. Free plans are not listed. At launch the switch sat under Quick Actions. The docs now put it under Agent Readiness, then Markdown for Agents, as "Serve Markdown to AI agents". A configuration rule can limit it to one subdomain or path, such as /blog/, and the API setting is content_converter. SaaS platforms can enable it for all custom hostnames or, on an advanced plan, for chosen ones.

The same dashboard page shows conversions over time, top user agents, failure reasons and the top pages that failed to convert. Those user agents are whatever the client sends, and Cloudflare does not verify them. A Playground tab compares the markdown and HTML for any path.

#What to check

  • Before you turn it on, decide your training policy and set a Content-Signal header at your origin. Our Cloudflare AI bot settings guide covers the other controls it should match.
  • Start with a configuration rule on one section, such as documentation, instead of the whole zone.
  • Test a page with curl -i -H "Accept: text/markdown" https://example.com/your-page and read the content-signal and vary lines.
  • Look at the markdown for pages that rely on JavaScript to render text. The converter works from the HTML your origin sends, and Cloudflare points to a separate browser-rendering API for dynamic pages. We think a client-rendered page can come out nearly empty.
  • After launch, open Top pages not converted and Content limits in the analytics tab to find pages that lost their JSON-LD or were truncated.

#What Cloudflare doesn't say

  • Whether any AI search engine treats the markdown copy differently when it chooses sources. The announcement adds a content type view to Cloudflare Radar and shows markdown being served to OAI-SearchBot, but not what OpenAI does with it.
  • Whether the x-markdown-tokens header from the launch post is still sent. The current docs leave it out of the example response.