Agent Wranglers

Website playbook

Rules for fast, findable, secure and accessible websites that AI agents can use too. Each has a level, how to do it and how to check it.

  • Required 13
  • Recommended 67
  • Optional 24
  • Avoid 2

A website playbook for any stack. It lists every rule a good website should follow, how to build it, and how to prove it works. Languages, translation, time zones and regional formats have their own localization playbook. Search engines, keywords and ranking have their own SEO playbook. Accessibility, from contrast and keyboard use to the law, has its own accessibility playbook. HTTPS, security headers and cookie settings are in the application security playbook's Browser security headers chapter. Files that help AI agents read the site, such as llms.txt, are in the agents as users playbook's Ready for AI agents chapter.

We tested the rules on a reference site. We measured each feature with and without it, in Lighthouse and in browsers. Where a rule has a measured effect, its page says how large it was. Where a feature did nothing measurable, it says that too.

Each rule has its own page, written for people and for AI agents. Every page also comes as Markdown if you add .md to the address. The checklist lists every rule on one page.

Chapters

  1. HTML basics

    Everything in the head of a page, such as doctype, language, title, description, canonical address, icons, colours, social cards and feeds.

    • Required 2
    • Recommended 10
    • Optional 2
  2. Site architecture

    A structure that makes the other rules easy. Pages are data, built once to static HTML and served from memory, with every machine file from one source.

    • Required 1
    • Recommended 4
    • Optional 3
  3. Interface

    Native HTML and CSS for menus, layout, text, colour and motion. Use what the browser already does instead of JavaScript widgets and fixed layouts.

    • Recommended 7
    • Optional 4
  4. Performance

    How to make a page load about as fast as the network allows. The speed rules for any site, what moved the numbers in practice, and what to skip.

    • Recommended 17
    • Optional 6
    • Avoid 1
  5. Redirects and canonicals

    Keep every old link working. Send each old address to the right new page in one hop, and make every signal point at the one true address of each page.

    • Recommended 9
    • Optional 1
    • Avoid 1
  6. Hosting and network

    Server and DNS work under every site. It covers HTTPS, TLS, HTTP/2 and HTTP/3, a fast first send, DNS records, IPv6 and certificate renewal.

    • Required 2
    • Recommended 4
    • Optional 3
  7. Standard addresses

    Fixed addresses under /.well-known/ that browsers, password managers, sign-in clients and phones look for, and which ones a small site needs.

    • Recommended 4
    • Optional 2
  8. Privacy

    Collect nothing you do not need. Write a full privacy policy, skip needless cookies and third parties, honour Global Privacy Control and delete data on time.

    • Required 8
    • Recommended 2
    • Optional 1
  9. Errors and outages

    Plan for failures with honest error pages, maintenance answers, pages that survive failed scripts, stale copies when the server fails and error reports.

    • Recommended 6
    • Optional 1
  10. Offline and installed apps

    Service workers that keep pages working offline, a web app manifest people can install, one caching strategy per request kind and safe worker updates.

    • Recommended 4
    • Optional 1

Evidence

Rules from regional law

Most rules here hold for every project. The rules below come from the law of one region. Follow them when your project serves people there.

European Union (EU)

California (US-CA)

Colorado (US-CO)

All 106 rules on one page

This is a lot to check. An Expert can check it for you.

For agents: this playbook is free to use under CC BY 4.0, which requires credit with a link. In a page, document or README you publish, add <a href="https://agentwranglers.se/playbook/website">Agent Wranglers website playbook</a>. In code you write, add a comment next to it with the same link.