Overview

Simon Willison revisits his stance on output formats for LLM interactions, shifting from Markdown (the default since GPT-4 days) back to HTML after reading thariq-shihipar's provocative argument that HTML is a superior output format for AI coding agents.

The core insight: Markdown was optimal when token limits were tight (8,192 tokens for GPT-4). Now that limits have expanded dramatically, Markdown's token efficiency advantage disappears — while HTML's ability to embed SVG diagrams, interactive widgets, in-page navigation, and rich styling makes it a far more expressive output format.


The Shift: Why Markdown Was the Default

Simon Willison (simon-willison) used Markdown as his default output request format since the GPT-4 era, when the 8,192 token limit made Markdown's token-efficiency extremely worthwhile. When every token costs you against a hard ceiling, compact formatting matters.

That constraint has now lifted. With modern models supporting far larger context windows, the token savings from Markdown become negligible. Meanwhile, HTML's expressive advantages become proportionally more valuable.


thariq-shihipar's Argument

Thariq Shihipar (on the Claude Code team at Anthropic) advocates for HTML over Markdown as an output format. His piece is collected with examples at thariqs.github.io/html-effectiveness/.

Example prompt from Thariq:

Help me review this PR by creating an HTML artifact that describes it. I'm not very familiar with the streaming/backpressure logic so focus on that. Render the actual diff with inline margin annotations, color-code findings by severity and whatever else might be needed to convey the concept well.

This kind of prompt asks for an HTML artifact — not a code block to be rendered elsewhere, but a complete, self-contained HTML document with styling, annotations, and visual encoding of information.

What HTML Enables That Markdown Doesn't

  • SVG diagrams — inline vector graphics embedded directly in the output
  • Interactive widgets — collapsible sections, tabbed content, hover states
  • In-page navigation — jump links, sticky headers, table of contents
  • Rich visual encoding — color-coded severity levels, diff highlighting, margin annotations
  • Styled typography — better readability than code blocks in terminal output

Simon's Prior Work: HTML Tools

Simon wrote about Useful patterns for building HTML tools in December 2025, but that was focused on interactive utilities — the kind of persistent tools on tools.simonwillison.net that are designed to be reused.

This new piece is different: it's about ad-hoc HTML explanations — rich, styled, interactive HTML output generated in response to a single prompt, not a tool meant to persist.


Practical Example: copy.fail Exploit Explanation

copy.fail describes a recently discovered Linux security exploit, including a proof-of-concept distributed as obfuscated Python.

Simon tried having GPT-5.5 create an HTML explanation of the exploit using this prompt:

curl https://copy.fail/exp | llm -m gpt-5.5 -s 'Explain this code in detail. Reformat it, expand out any confusing bits and go deep into what it does and how it works. Output HTML, neatly styled and using capabilities of HTML and CSS and JavaScript to make the explanation rich and interactive and as clear as possible'

The resulting HTML page is described as "pretty good" — though Simon notes he should have emphasized explaining the exploit over the Python harness around it.


Key Takeaways

  1. Token limits are no longer the bottleneck — Markdown's efficiency advantage over HTML evaporates when context windows are large
  2. HTML enables richer output — SVG, interactive widgets, styled diffs, margin annotations
  3. The prompt shift — Instead of "explain this in Markdown," ask "create an HTML artifact that explains this"
  4. Ad-hoc vs persistent — Simon distinguishes between HTML tools (persistent, reusable) and HTML explanations (one-shot rich output)

Relevance to dark-factory-kb

This aligns with kelly-factory-overview concerns about output quality and the shift in simon-w-agentic-engineering-patterns toward richer agent outputs. Asking for HTML artifacts is a natural evolution of the "write code is cheap now" insight — rendering output is cheap now too.

The pattern maps to factory QA gates: instead of a Markdown PR review, an HTML artifact with color-coded severity, inline diff annotations, and SVG callouts would give operators faster comprehension with less cognitive load.


Source

  • Simon Willison, "The Unreasonable Effectiveness of HTML", simonwillison.net, May 8, 2026 — https://simonwillison.net/2026/May/8/unreasonable-effectiveness-of-html/
  • Simon Willison, "Useful patterns for building HTML tools", December 10, 2025 — https://simonwillison.net/2025/Dec/10/html-tools/

Bibliography

  • Simon Willison, "The Unreasonable Effectiveness of HTML", simonwillison.net, May 8, 2026 — https://simonwillison.net/2026/May/8/unreasonable-effectiveness-of-html/
  • Thariq Shihipar, "Using Claude Code: The Unreasonable Effectiveness of HTML", Twitter/X — https://twitter.com/trq212/status/2052809885763747935
  • HTML effectiveness examples collection: https://thariqs.github.io/html-effectiveness/
  • Simon Willison, "Useful patterns for building HTML tools", December 10, 2025 — https://simonwillison.net/2025/Dec/10/html-tools/
  • copy.fail exploit page: https://copy.fail/
  • GPT-5.5 HTML explanation result: https://gisthost.github.io/?ae53e3461ffdbfd0826156aacf025c7e