Agent Experiences

Developer Guide to AXO

The developer's part

Developers build the groundwork that lets AI tools find a site and make sense of it: clear markup, labels that AI tools can read, and a site structure that's easy to follow.

AXO (agent experience optimization) means making your website easy for AI tools to find, understand, quote, and use, including AI agents (AI assistants that carry out tasks for someone, such as booking or buying). Much of that work is writing and policy, but the parts an AI tool reads first are yours: the HTML, the labels in the code, the speed, and the ways a program can fetch your content. This guide covers that technical work, from labeling content through to testing it.

Structured data

JSON-LD

Structured data (labels in a page's code that state facts such as the author, the date, or a price) states outright what the prose only implies: who wrote the page, when it last changed, what it's about, and how it relates to the rest of the site. The usual way to add it is JSON-LD (a small block of code in the page, written in a format software reads easily). Whether AI answer engines use it is disputed, but it earns rich results (the star ratings, prices, and other extras shown under a link) in ordinary search either way. Add it to your main content types:

{
  "@context": "https://schema.org",
  "@type": "Article",
  "headline": "Your Article Title",
  "author": {
    "@type": "Person",
    "name": "Author Name"
  },
  "datePublished": "2026-01-15",
  "dateModified": "2026-01-20",
  "description": "Clear, factual description",
  "mainEntityOfPage": {
    "@type": "WebPage",
    "@id": "https://yoursite.com/article"
  }
}

Schema types to start with

  • Article for blog posts, guides, and other informational pages
  • Organization for company and contact details
  • Product for product pages and specifications

Older guides also recommend FAQPage and HowTo. In an August 2023 Search Central post, Google said FAQ rich results would only show regularly for well-known government and health sites, and it has since stopped showing HowTo rich results altogether. So for most sites, neither earns the extras in Google's results any more.

Semantic HTML

Headings in order

Semantic HTML means using tags that say what each part of a page is, such as a heading, an article, or a footer, instead of generic boxes. AI tools read the headings to work out how a page is organized, so use them in order:

<h1>Main Topic</h1>
  <h2>Subtopic A</h2>
    <h3>Detail A1</h3>
    <h3>Detail A2</h3>
  <h2>Subtopic B</h2>
    <h3>Detail B1</h3>

Elements that describe the page

HTML5 has elements for the main parts of a page. Using them tells an AI tool which part is the article, which is the side note, and which is the footer:

<article>
  <header>
    <h1>Article Title</h1>
    <time datetime="2026-01-15">January 15, 2026</time>
  </header>
  
  <section>
    <h2>Key Information</h2>
    <p>Factual content that agents can reference...</p>
  </section>
  
  <aside>
    <h3>Related Information</h3>
    <p>Supporting details...</p>
  </aside>
  
  <footer>
    <p>Source: <cite>Authoritative Reference</cite></p>
  </footer>
</article>

Content APIs for AI agents

A content endpoint

An API (a way for one program to ask another for data or actions) lets a program fetch your content as clean data instead of picking it out of your HTML. This is optional, and only useful if something will call it, such as your own apps, a partner's tools, or an agent set up to work with your site. Each endpoint (a URL that returns data rather than a web page) can serve one article with its title, summary, key facts, and sections already separated:

// /api/content/[slug]/route.ts
// Next.js 15+: route params arrive as a Promise
export async function GET(request: Request, { params }: { params: Promise<{ slug: string }> }) {
  const { slug } = await params
  const content = await getContent(slug)
  
  return Response.json({
    title: content.title,
    summary: content.summary,
    facts: content.keyFacts,
    lastModified: content.updatedAt,
    sections: content.sections.map(section => ({
      heading: section.heading,
      content: section.content,
      facts: section.extractedFacts
    }))
  })
}

A manifest

You can also publish a manifest, a single file that describes what your site offers and where each kind of content lives. This is a pattern rather than a published standard, and no AI tool is known to read a manifest like this yet, so treat it as optional:

// /api/axo-manifest/route.ts
export async function GET() {
  return Response.json({
    site: "https://yoursite.com",
    axoVersion: "1.0",
    contentTypes: ["articles", "guides", "faqs"],
    lastUpdated: new Date().toISOString(),
    endpoints: {
      content: "/api/content/{slug}",
      search: "/api/search",
      sitemap: "/sitemap.xml"
    },
    policies: {
      crawlable: true,
      citable: true,
      updateFrequency: "daily"
    }
  })
}

llms.txt

llms.txt (a plain-text file at the root of your site that lists your most useful pages for AI tools) gets a lot of attention, so set your expectations before you build one. Ahrefs studied 137,000 sites and found that 97% of valid llms.txt files received zero requests in May 2026, and Google has documented that it does not use llms.txt for Search or AI Overviews. It does help with tools. Lighthouse (Google's free site-testing tool) now checks for it when testing how AI agents browse a site, and coding agents pointed at your docs can follow it. Build one if your users point coding agents at your docs, not in the hope of more citations.

The spec is stricter than most examples on the web suggest. A valid file has an H1 title, a > blockquote summary, optional prose with no headings, and then ## sections containing markdown link lists in the form - [name](url): description. A section named ## Optional marks links an agent may skip when it's short on space. Key/value lines like Name: or Contact: are not part of the format.

Save the following as /public/llms.txt so it is served from /llms.txt:

# Agent Experiences

> Resources for agent experience optimization (AXO): making websites
> easy for AI tools to find, understand, quote, and use.

Guides are grouped by role. Every page linked below is available as
markdown by appending `.md` to its URL.

## Guides

- [Developer Guide](https://yoursite.com/guides/developers.md): JSON-LD, semantic HTML, server rendering, content APIs
- [Writer Guide](https://yoursite.com/guides/writers.md): Fact-first structure and citation-ready prose
- [Admin Guide](https://yoursite.com/guides/admins.md): Crawler controls, log monitoring, site management
- [SEO Guide](https://yoursite.com/guides/seo.md): Where search practice carries over to answer engines

## Reference

- [AXO Playbook](https://yoursite.com/axo-playbook.md): End-to-end implementation guide
- [Glossary](https://yoursite.com/glossary.md): AXO terminology and definitions

## Optional

- [Blog](https://yoursite.com/blog.md): Ongoing analysis and case studies

Speed

Fast pages

AI crawlers (the bots AI companies send to fetch pages) may visit often, so speed matters for them as much as for people:

  • Build content pages ahead of time with Next.js static generation, rather than on every request
  • Send proper HTTP caching headers
  • Turn on gzip or Brotli compression
  • Serve pages through a CDN (a network of servers that keeps copies of your pages close to each visitor)

A complete sitemap

A sitemap (a file listing every page you want found, with the date each one last changed) helps bots find all of your content. Keep the dates honest:

// Generate complete sitemaps
export default function sitemap(): MetadataRoute.Sitemap {
  return [
    {
      url: 'https://yoursite.com',
      lastModified: new Date('2026-11-01'), // the date the home page last really changed
      changeFrequency: 'daily',
      priority: 1,
    },
    // Include all content pages with accurate lastModified dates
    ...contentPages.map(page => ({
      url: `https://yoursite.com/${page.slug}`,
      lastModified: page.updatedAt,
      changeFrequency: 'weekly',
      priority: 0.8,
    }))
  ]
}

Metadata

Page by page

Give every page its own title, description, author, and dates:

export const metadata: Metadata = {
  title: 'Specific, descriptive title',
  description: 'Clear, factual description under 160 characters',
  keywords: ['relevant', 'keywords', 'for', 'content'],
  authors: [{ name: 'Author Name', url: 'https://author-profile.com' }],
  openGraph: {
    title: 'Specific Title',
    description: 'Clear description',
    type: 'article',
    publishedTime: '2026-01-15T00:00:00.000Z',
    modifiedTime: '2026-01-20T00:00:00.000Z',
    authors: ['Author Name'],
  },
  robots: {
    index: true,
    follow: true,
    googleBot: {
      index: true,
      follow: true,
    },
  },
}

Consistent URLs

Use URLs that are predictable and say what the page is:

✅ Good: /guides/developers/schema-implementation
✅ Good: /blog/2026/axo-best-practices
❌ Bad: /p/123456/dev-guide
❌ Bad: /content?id=abc&type=guide

Technical checklist

Developer checklist

  • JSON-LD structured data on every content page
  • Semantic HTML, with headings in order
  • Page metadata: title, description, authors, and dates
  • Content API endpoints for programs that want your pages as data
  • llms.txt in the llmstxt.org format, if you want the tooling benefit (low priority, since it does not affect citations)
  • sitemap.xml with accurate last-modified dates
  • Pages that load in under 3 seconds
  • A layout that works on phones
  • Consistent URLs
  • robots.txt (the file that tells bots which parts of the site they may visit) set up the way you intend

Testing your work

Validation tools

  • Schema Markup Validator (Schema.org's own checker; schema markup is another name for structured data) to test your JSON-LD
  • An HTML validator to confirm the markup is correct
  • Lighthouse to check speed and accessibility
  • A sitemap validator to confirm the sitemap is formatted properly

Checking it the way an AI would

Then read a page the way an AI tool might:

  1. Can the key facts be picked out easily?
  2. Does the structure make sense from the headings alone?
  3. Are the modification dates accurate and current?
  4. Does the page load quickly for an automated visitor?

Common mistakes

  • Missing or wrong JSON-LD, which costs you rich results in ordinary search and leaves AI tools guessing what the page is about
  • Headings out of order, which leaves the structure unclear
  • Modification dates that don't match real changes
  • Slow pages, which bots may time out on or skip
  • Broken internal links, which hide pages from anything that finds content by following links

Where to start

Start with structured data and semantic HTML, which help in ordinary search as well. Add the content API and the speed work after that.

References

  1. Schema.org Documentation - Schema.org Community
  2. HTML5 Semantic Elements - MDN Web Docs
  3. Next.js Metadata API - Vercel

Further reading from Field Notes

Posts with more on this topic, each with its date.

All Field Notes