# Hello, agentic web

_2026-06-11 · agents, markdown_

More and more of the traffic on the web is not people. AI agents read pages,
follow links, and answer questions on behalf of the people who used to click
through themselves. Most sites still serve those agents the same heavy HTML
they serve a browser, and the agents spend their effort parsing layout instead
of reading content.

This site takes a different approach. Every public page has a markdown twin.
Append `.md` to a path, send an `Accept: text/markdown` header, or simply fetch
a page with an agent user agent, and you get clean markdown instead of HTML.

## This blog works the same way

Each post here is a single MDX file. The same file produces the page you are
reading now and the markdown twin an agent reads. There is no second copy to
keep in sync.

The build step scans every post, derives the markdown version, and registers it
in one manifest. The middleware then serves the right format per request:

```ts
// Simplified: the decision the middleware makes on every request.
function clientWantsMarkdown(req: Request): boolean {
  if (accepts(req, "text/markdown")) return true;
  const ua = classify(req.headers.get("user-agent"));
  return ua === "crawler" || ua === "fetcher";
}
```

Agents also get an index. `/llms.txt` lists every page on the site with a one
line summary, and `/llms-full.txt` includes the full markdown bodies.

## Try it

Fetch this post as markdown:

```sh
curl -H "Accept: text/markdown" https://caprail.dev/blog/hello-agentic-web
```

If you are reading this through an agent, you already did.
