Export an LLM chat to Markdown, HTML, or PDF
Chat UIs make it hard to get a clean, portable copy of a conversation. This tool takes a pasted transcript — or a raw message JSON array — parses it into turns, and exports it as Markdown, standalone HTML, or a print-ready page you can save to PDF. Everything happens in your browser.
When to use each export format
| Format | Best for |
|---|---|
| Markdown | Pasting into a doc, GitHub issue, Notion, or Obsidian |
| Standalone HTML | Sharing with someone who doesn’t use Markdown; email attachment |
| Print / PDF | Archiving, client deliverables, including in a report |
How it works
The parser supports two inputs:
- Role-labeled text — it scans for lines beginning with a known role label
(
User:,Assistant:,Human:,System:,AI:) and groups the lines that follow into that turn. This matches how most people copy a chat from the UI. - Message JSON — an array of
{ "role": "...", "content": "..." }objects in the OpenAI or Anthropic message shape. Each object becomes one turn.
Once parsed, the conversation is re-rendered into the chosen format:
- Markdown uses
**Role:**headers and preserves the body text verbatim, including any code blocks. - HTML wraps each turn in a styled block with role-based color coding for easy reading.
- Print view opens a clean, paginated page in a new tab where you trigger Save as PDF from the browser print dialog.
Tips and notes
- If turns merge into one block instead of splitting, your paste is missing role labels — add
User:andAssistant:prefixes or switch to the JSON message format. - The HTML export is self-contained with inline styles, so you can save the file and open it anywhere without a linked stylesheet.
- For PDF, the browser print engine is used rather than a bundled library — it is lighter, renders code fonts correctly, handles pagination, and keeps your conversation fully local.
- To export from ChatGPT: select all text in the conversation, copy, and paste here. To export from Claude.ai: use the same approach or copy the JSON from the developer tools network tab if you need the message JSON format.
Why a portable export matters
Chat UIs change over time and are not designed for long-term archival. Conversations you want to reference later — research sessions, technical problem-solving threads, client interaction records — are safer in a format you control. Markdown and HTML exports are plain text files that will remain readable indefinitely, unlike platform-specific export formats that can break when the service updates. PDF exports are suitable for records that need to be shared with people who do not use the same AI tools.