by ZeroSumQuant
Extract clean conversation logs from Claude Code's internal storage
# Add to your Claude Code skills
git clone https://github.com/ZeroSumQuant/claude-conversation-extractor🚀 The ONLY tool to export Claude Code conversations. Extract Claude chat history from ~/.claude/projects, search through logs, and backup your AI programming sessions.
claude-start - Interactive UI with ASCII art logo, real-time search, and menu-driven interface (recommended)claude-extract - Plain CLI for command-line operations and scriptingExport Claude Code conversations with the #1 extraction tool. Claude Code stores chats in ~/.claude/projects as JSONL files with no export button - this tool solves that.
No comments yet. Be the first to share your thoughts!
🔥 What users search for: Export Claude conversations | Claude Code logs location | Backup Claude sessions | Claude JSONL to Markdown

Claude Code has no export button. Your conversations are trapped in ~/.claude/projects/ as undocumented JSONL files. You need:
This is the ONLY tool that exports Claude Code conversations:
claude-extract - we find everything automatically# Using pipx (solves Python environment issues)
pipx install claude-conversation-extractor
# OR using pip
pip install claude-conversation-extractor
# Install pipx first
brew install pipx
pipx ensurepath
# Then install the extractor
pipx install claude-conversation-extractor
# Install pipx
py -m pip install --user pipx
py -m pipx ensurepath
# Restart terminal, then:
# Install the extractor
pipx install claude-conversation-extractor
# Ubuntu/Debian
sudo apt install pipx
pipx ensurepath
# Install the extractor
pipx install claude-conversation-extractor
# Run the interactive UI with ASCII art logo and real-time search
claude-start
# Run the standard CLI interface
claude-extract
# Search for specific content directly
claude-search "API integration"
# Note: claude-logs also works for backward compatibility
That's it! The tool will:
# Interactive mode with UI - easiest way to export Claude conversations
claude-start
# CLI mode - command-line interface
claude-extract
# List all Claude Code conversations
claude-extract --list
# Export specific Claude chats by number
claude-extract --extract 1,3,5
# Export recent Claude Code sessions
claude-extract --recent 5
# Backup all Claude conversations at once
claude-extract --all
# Save Claude logs to custom location
claude-extract --output ~/my-claude-backups
Export conversations in multiple formats:
# Export as JSON for programmatic processing
claude-extract --format json --extract 1
# Export as HTML with beautiful formatting
claude-extract --format html --all
# Include tool use, MCP responses, and system messages
claude-extract --detailed --extract 1
# Combine options for complete exports
claude-extract --format html --detailed --recent 5
Supported Formats:
Detailed Mode (--detailed):
Includes complete conversation transcript with:
Search across all your Claude conversations:
# Method 1: Direct search command
claude-search # Prompts for search term
claude-search "zig build" # Search for specific term
claude-search "error handling" # Multi-word search
# Method 2: From interactive menu
claude-extract
# Select "Search conversations" for real-time search
Search features:
~/.claude/projects/*/chat_*.jsonl%USERPROFILE%\.claude\projects\*\chat_*.jsonl~/Desktop/Claude logs/claude-conversation-2025-06-09-abc123.md
├── Metadata (session ID, timestamp)
├── User messages with 👤 prefix
├── Claude responses with 🤖 prefix
└── Clean Markdown formatting
Install with pipx install claude-conversation-extractor then run claude-extract. The tool automatically finds all conversations in ~/.claude/projects.
Use the --detailed flag to include tool invocations, MCP responses, terminal outputs, and system messages:
claude-extract --detailed --format html --extract 1
This gives you the complete conversation as seen in Claude's Ctrl+R view.
Claude Code saves all chats in ~/.claude/projects/ as JSONL files. There's no built-in export feature - that's why this tool exists.
Yes! Run claude-search or select "Search conversations" from the menu. Type anything and see results instantly.
Run claude-extract --all to export every conversation at once, or use the interactive menu option "Export all conversations".
No, this tool specifically exports Claude Code (desktop app) conversations. Claude.ai has its own export feature in settings.
Yes! Version 1.1.1 supports multiple export formats:
--format json or --format html when extracting.No, this is an independent open-source tool. It reads the local Claude Code files on your computer - no API or internet required.
| Feature | Claude Conversation Extractor | Manual Copy | Claude.ai Export | |---------|------------------------------|-------------|------------------| | Works with Claude Code | ✅ Full support | ✅ Tedious | ❌ Different product | | Bulk export | ✅ All conversations | ❌ One at a time | ❌ N/A | | Search capability | ✅ Real-time search | ❌ None | ❌ N/A | | Clean formatting | ✅ Perfect Markdown | ❌ Terminal artifacts | ❌ N/A | | Zero configuration | ✅ Auto-detects | ❌ Manual process | ❌ N/A | | Cross-platform | ✅ Win/Mac/Linux |