Using Claude Code: The unreasonable effectiveness of HTML
TL;DR Highlight
Having Claude Code output HTML instead of markdown made specs easier to read, share and interact with.
Who Should Read
Developers whose long Claude Code specs and plans in markdown go unread by teammates
Core Mechanics
- Nobody reads markdown past 100 lines
- The author says he doesn't actually read markdown files over 100 lines.
- Getting others in his organization to read them is even harder.
- HTML carries far richer information
- Tables, CSS, SVG and JavaScript cover data, design, illustrations and interactions.
- Without it, the model falls back to ASCII diagrams or unicode characters to fake colors.
- Sharing is just upload and send a link
- Markdown isn't rendered well by browsers, so it ends up as an attachment.
- HTML uploaded to S3 becomes a link, and the author says it's much more likely to be read.
- Sliders and copy buttons give two-way interaction
- You can add sliders or knobs to tune a design or algorithm.
- A button copies your tweaks as a prompt to paste back into Claude Code.
- Claude Code pulls in lots of context
- It reads the file system, MCPs (Slack, Linear), the browser and git history.
- The author had it collect his own HTML files and categorize them to make this article's diagrams.
- Tradeoffs are time, tokens and version control
- HTML can take 2-4x longer to generate than markdown.
- HTML diffs are noisy and hard to review, which the author calls a major downside.
- With Opus 4.7's 1MM context, the extra tokens are not noticeable, he says.
Community Reactions
- Markdown is easier for humans to co-author, one commenter argued
- Editing HTML by hand is harder, so you must re-prompt the LLM, which may reduce human co-creation.
- Others noted HTML is less token-efficient and harder to give precise feedback on.
- Markdown with inline HTML or better renderers may suffice, commenters said
- The markdown spec allows inline HTML, so you can embed SVG directly.
- Others suggested GitHub markdown with mermaid, MDX, or Typst.
- One team said switching their report agent to HTML made customers happier
- Their YAML-spec renderer drowned them in feature requests.
- Letting the agent write HTML was slower but gave unlimited customization, and customers liked it more.
- One dev said an interactive HTML spec cut a refactor from days to hours
- JS let them use ts-morph to map call sites for state management refactoring.
How to Apply
- Turn your next PR writeup into an HTML review page
- When opening a PR, ask Claude Code for an HTML explainer with the diff, severity colors and annotations.
- Name the unfamiliar logic so it focuses there.
- Compare design options in one HTML grid
- When unsure of direction, ask for 6 distinct approaches in a single file side by side.
- Have each labeled with its tradeoff.
- Build a throwaway editor with an export button
- For ticket triage or config editing, ask for a single-file HTML editor.
- End it with a 'copy as JSON/prompt' button and paste the result back into Claude Code.
- Keep markdown for docs that need diffs
- Keep long-lived, diff-reviewed docs in markdown.
- Use HTML only for read-and-discard explainers, reports and explorations.
Try It
# Paste directly into Claude Code (based on the article's example prompt)
Help me review this PR by creating an HTML artifact that describes it. I'm not very familiar with {{unfamiliar logic name}}, 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.Terminology
Related Papers
Why Do LLMs Help with Scientific Misconduct Requests and What to Do About It?: Increasing the Trustworthiness of AI for Science
Adding an intention-analysis system prompt raised refusal of misconduct requests from 58% to 87%.
How Specification Explicitness Shapes Failure in LLM-Generated Code
Spelling out invariants, edge cases and constraints cut hidden-test failures in LLM code by 47.2%.
Same Task, Different Statement: When and How Reformulation Helps LLM Problem Solving
Rewriting problem statements to fit their type raises LLM accuracy, but blind rewriting hurts.
Show HN: STE80 Humanizer – de-AI text by writing 80% of the way to ASD-STE100
A skill strips 26 AI tells and rewrites text in short ASD-STE100-style sentences
Character-Name Concentration in LLM Fiction: Measuring Displacement and Mitigating Repetition
Drafting name candidates and filtering by frequency cut LLM character-name repetition by 95%
LLM Voice
Martin Fowler: LLM-drafted prose keeps an uncanny tone even after human editing.
The Instruction Tax on Factual Recall: Base Models Can Beat Their Instruction-Tuned Counterparts
Few-shot completion with repeated sampling on a base model beat chat: F1 0.684 vs 0.568
AI is a tool and using it well takes skill
A rebuttal to Hickey: LLMs are tools, and skill in directing and checking them decides the outcome