Developer Guide

How to Search, View & Resume Claude Code Sessions

Anthropic's Claude Code CLI gives developers superpowers right inside their terminal. But as you navigate complex repositories, finding past prompt rationales, tool executions, and file diffs from previous sessions can be painful. Here is everything you need to inspect, search, and resume your Claude Code history across macOS, Linux, and Windows.

⚡ Instant In-Browser Viewer (Works on Any OS)

Want to inspect a transcript.jsonl session right now with zero uploads?

Open our free, client-side session viewer to filter prompts, view tool call diffs, and inspect token consumption in any browser.

Open Free Session Viewer Tool ↗ Get L2Cache for Mac ↗

Updated October 2026 · By the team behind L2Cache

Where Does Claude Code Store Transcripts?

Whenever you execute claude in a repository, Anthropic records a complete step-by-step transcript of user inputs, assistant thoughts, tool calls (bash, ripgrep, file edits), and token metrics locally on your filesystem:

macOS & Linux:

~/.claude/projects/<sanitized-project-path>/transcript.jsonl

Windows:

%USERPROFILE%\.claude\projects\<sanitized-project-path>\transcript.jsonl

For example, if your repository is at /Users/you/work/api-server, the transcript file is saved under:

~/.claude/projects/Users-you-work-api-server/transcript.jsonl

Built-in Terminal Commands: Resuming Past Work

Claude Code includes native terminal commands to resume recent conversations within your terminal:

💻 Native Claude Code CLI History and Resume Commands

Command Use
claude --resume (or claude -r) Open the interactive session picker for the current workspace.
claude --resume SESSION_ID Resume a specific past session directly by ID.
claude --continue (or claude -c) Continue the most recent session in this directory without prompting.
claude --print Print the last turn response to stdout for piping.

Why Claude Code Conversation History Changes How You Work

Treating your Claude Code transcripts as a searchable repository memory—rather than a pile of ephemeral sessions—fundamentally transforms day-to-day engineering velocity:

🔄 Stop Re-Explaining Complex Modules

If you spent 15 turns giving Claude deep architectural context on your auth layer or SQLite schema, don't start from scratch. Resume that exact session to maintain full context instantly.

🎯 Keep Architectural Decisions Consistent

Technical decisions compound across PRs. Resuming the original session prevents the agent from contradicting patterns, conventions, or design choices established days earlier.

⚡ Slash Token Costs & Prompt Latency

Re-explaining code burns input tokens and model warmup time. Continuing a warm session maximizes prompt cache hit rates (cacheReadTokens), saving up to 90% on API costs and cutting response times.

🧘 Manage Multi-Repo Contexts Calmly

When you can search and resume any Claude conversation across multiple projects in one global hotkey panel, repository hopping stops incurring a massive cognitive context switch.

💡 Never Lose a Late-Night Fix

That brilliant regex or tricky concurrency workaround you found at midnight is indexed in your history. Search the tool output, resume the session, and reuse it effortlessly.

Limitations of the Native CLI Resume:

How to Parse Claude Code History from Terminal

If you want to quickly grep for past user prompts in a project transcript without opening the file, use jq:

# Extract all user prompts in chronological order
jq -r 'select(.type=="USER_INPUT") | .content' ~/.claude/projects/YOUR_PROJECT/transcript.jsonl

# Find all bash commands run by Claude Code
jq -r 'select(.type=="PLANNER_RESPONSE") | .tool_calls[]? | select(.name=="run_command") | .args.CommandLine' ~/.claude/projects/YOUR_PROJECT/transcript.jsonl

Native Claude Code Resume vs. L2Cache History

While the native claude --resume CLI command is great for quick terminal rollbacks, L2Cache for Mac adds visual search, token analytics, and cross-project indexing:

Capability Native Claude Code CLI (claude -r) L2Cache for Mac
Search Scope Initial prompt only in current repo Full SQLite FTS5 search across all turns, tool outputs & code diffs
Session Titles Truncated initial user prompt Auto-surfaces model-generated aiTitle for instant recognition
Prompt Cache Tracking None in CLI picker Real-time cacheReadTokens hit ratios & token savings
Resumption Method Navigate to folder & run shell command 1-Click "Resume in Terminal" from floating panel (⌥Space)
Cross-Project Support Single repository only Unified timeline across all repositories and Claude/Codex agents
Privacy & Telemetry Local disk JSONL 100% On-Device, zero-cloud encrypted storage

Supercharge Your Mac Developer Workflow

L2Cache keeps an unlimited, private, instant-searchable history of your terminal commands, code, and AI prompts on macOS.

Download L2Cache on the Mac App Store

macOS 13 Ventura or later · One-time purchase · Lifetime updates

Frequently Asked Questions

Where is the Claude Code config located on Mac?

Global settings, custom tool permissions, and authentication for Claude Code are stored in ~/.claude/config.json and ~/.claude/settings.json.

Does the In-Browser Session Viewer upload my transcript?

No. The L2Cache Claude Session Viewer runs entirely client-side using JavaScript File API. Your data never touches any server.

Can I search OpenAI Codex transcripts too?

Yes! Read our companion guide on searching OpenAI Codex rollout history on macOS.

🗂️ Search sessions in L2Cache: Visit the Claude Code history viewer for Mac to find earlier debugging conversations and project context.
🛠️ Free Tool: Use our In-Browser Claude & Codex Session Viewer to inspect transcripts.
📖 Production Scenarios: Read How Claude Code Session History Can Save Your Production: 3 Real Scenarios.
📖 Codex Guide: Read How to Find & Resume OpenAI Codex CLI Sessions on Mac.
📖 Terminal Guide: Learn how to search and manage Mac terminal command history.