A new way to extract detailed transcripts from Claude Code
25th December 2025
I’ve released claude-code-transcripts, a new Python CLI tool for converting Claude Code transcripts to detailed HTML pages that provide a better interface for understanding what Claude Code has done than even Claude Code itself. The resulting transcripts are also designed to be shared, using any static HTML hosting or even via GitHub Gists.
Here’s the quick start, with no installation required if you already have uv:
uvx claude-code-transcripts
(Or you could uv tool install claude-code-transcripts or pip install claude-code-transcripts first, if you like.)
This will bring up a list of your local Claude Code sessions. Hit up and down to select one, then hit <enter>. The tool will create a new folder with an index.html file showing a summary of the transcript and one or more page_x.html files with the full details of everything that happened.
Visit this example page to see a lengthy (12 page) transcript produced using this tool.

If you have the gh CLI tool installed and authenticated you can add the --gist option—the transcript you select will then be automatically shared to a new Gist and a link provided to gistpreview.github.io to view it.
claude-code-transcripts can also fetch sessions from Claude Code for web. I reverse-engineered the private API for this (so I hope it continues to work), but right now you can run:
uvx claude-code-transcripts web --gist
Then select a Claude Code for web session and have that converted to HTML and published as a Gist as well.
The claude-code-transcripts README has full details of the other options provided by the tool.
Why I built this
These days I’m writing significantly more code via Claude Code than by typing text into a text editor myself. I’m actually getting more coding work done on my phone than on my laptop, thanks to the Claude Code interface in Anthropic’s Claude iPhone app.
Being able to have an idea on a walk and turn that into working, tested and documented code from a couple of prompts on my phone is a truly science fiction way of working. I’m enjoying it a lot.
There’s one problem: the actual work that I do is now increasingly represented by these Claude conversations. Those transcripts capture extremely important context about my projects: what I asked for, what Claude suggested, decisions I made, and Claude’s own justification for the decisions it made while implementing a feature.
I value these transcripts a lot! They help me figure out which prompting strategies work, and they provide an invaluable record of the decisions that went into building features.
In the pre-LLM era I relied on issues and issue comments to record all of this extra project context, but now those conversations are happening in the Claude Code interface instead.
I’ve made several past attempts at solving this problem. The first was pasting Claude Code terminal sessions into a shareable format—I built a custom tool for that (called terminal-to-html and I’ve used it a lot, but it misses a bunch of detail—including the default-invisible thinking traces that Claude Code generates while working on a task.
I’ve also built claude-code-timeline and codex-timeline as HTML tool viewers for JSON transcripts from both Claude Code and Codex. Those work pretty well, but still are not quite as human-friendly as I’d like.
An even bigger problem is Claude Code for web—Anthropic’s asynchronous coding agent, which is the thing I’ve been using from my phone. Getting transcripts out of that is even harder! I’ve been synchronizing them down to my laptop just so I can copy and paste from the terminal but that’s a pretty inelegant solution.
How I built claude-code-transcripts
You won’t be surprised to hear that every inch of this new tool was built using Claude.
You can browse the commit log to find links to the transcripts for each commit, many of them published using the tool itself.
Here are some recent examples:
- c80b1dee Rename tool from claude-code-publish to claude-code-transcripts—transcript
- ad3e9a05 Update README for latest changes—transcript
- e1013c54 Add autouse fixture to mock webbrowser.open in tests—transcript
- 77512e5d Add Jinja2 templates for HTML generation (#2)—transcript
- b3e038ad Add version flag to CLI (#1)—transcript
I had Claude use the following dependencies:
- click and click-default-group for building the CLI
- Jinja2 for HTML templating—a late refactoring, the initial system used Python string concatenation
- httpx for making HTTP requests
- markdown for converting Markdown to HTML
- questionary—new to me, suggested by Claude—to implement the interactive list selection UI
And for development dependencies:
- pytest—always
- pytest-httpx to mock HTTP requests in tests
- syrupy for snapshot testing—with a tool like this that generates complex HTML snapshot testing is a great way to keep the tests robust and simple. Here’s that collection of snapshots.
The one bit that wasn’t done with Claude Code was reverse engineering Claude Code itself to figure out how to retrieve session JSON from Claude Code for web.
I know Claude Code can reverse engineer itself, but it felt a bit more subversive to have OpenAI Codex CLI do it instead. Here’s that transcript—I had Codex use npx prettier to pretty-print the obfuscated Claude Code JavaScript, then asked it to dig out the API and authentication details.
Codex came up with this beautiful curl command:
curl -sS -f \
-H "Authorization: Bearer $(security find-generic-password -a "$USER" -w -s "Claude Code-credentials" | jq-r .claudeAiOauth.accessToken)" \
-H "anthropic-version: 2023-06-01" \
-H "Content-Type: application/json" \
-H "x-organization-uuid: $(jq -r '.oauthAccount.organizationUuid' ~/.claude.json)" \
"https://api.anthropic.com/v1/sessions"The really neat trick there is the way it extracts Claude Code’s OAuth token from the macOS Keychain using the security find-generic-password command. I ended up using that trick in claude-code-transcripts itself!
More recent articles
- Cooking with Claude - 23rd December 2025
- Your job is to deliver code you have proven to work - 18th December 2025