Documentation
How to use claude-devtools to inspect Claude Code sessions, track token usage, debug tool calls, and monitor what your AI agent actually did.
What is claude-devtools?
claude-devtools is a free, open-source desktop app that reads the session logs Claude Code already saves to ~/.claude/ on your machine. It reconstructs exactly what happened during each session — every file read, every tool call, every edit, every token consumed — and presents it in a structured, searchable interface.
It does not wrap or modify Claude Code in any way. It works with every session you've ever run — from the terminal, from an IDE, or from any other tool that uses Claude Code.
Where are Claude Code session logs stored?
Claude Code saves all session data to ~/.claude/ on your machine. This directory contains raw JSONL log files for every session — including tool calls, AI responses, user prompts, token counts, and system messages.
These logs exist whether or not you use claude-devtools. The app simply reads them and turns them into something you can actually navigate.
Default locations by platform:
macOS: /Users/
Linux: /home/
Windows: C:\Users\
How to view Claude Code token usage
The Claude Code terminal shows a three-segment progress bar for context usage — but no actual numbers. claude-devtools provides per-turn token attribution across 7 categories:
CLAUDE.md files — global, project, and directory-level Skill activations — slash commands and custom skills @-mentioned files — files referenced in your prompt Tool call I/O — input and output tokens from Read, Edit, Bash, etc. Extended thinking — chain-of-thought tokens Team overhead — coordination tokens from subagents and teammates User text — your actual prompts
This breakdown appears as a Context Badge on each assistant response, a Token Usage popover with percentage breakdowns, and a dedicated Session Context Panel.
Understanding context window compaction
When Claude Code hits its context limit, it silently compresses your conversation and continues. Most tools don't even show that this happened.
claude-devtools detects compaction boundaries, measures the token delta before and after, and visualizes how your context fills, compresses, and refills over the course of a session. You can see exactly what was in the window at any point, and how the composition shifted after each compaction event.
This is critical for debugging sessions where Claude "forgot" something — you can see precisely when and what was compressed away.
How to debug Claude Code tool calls
In the terminal, Claude Code collapses tool calls into one-line summaries: Read 3 files, Edited 2 files, Ran bash command. You don't see which files, what changed, or what the output was.
claude-devtools expands every tool call with specialized viewers: Read calls show syntax-highlighted code with line numbers and the exact file path Edit calls show inline diffs with added/removed highlighting Bash calls show the full command and output Search calls show the regex pattern, matching files, and matched lines Subagent calls show the full execution tree, expandable in-place
The --verbose flag in Claude Code dumps raw JSON that includes internal system prompts and thousands of lines of noise. claude-devtools gives you the same information, structured and filterable.
Debugging subagents and teams
Claude Code now spawns subagents via the Task tool and coordinates teams with TeamCreate, SendMessage, and TaskUpdate. In the terminal, all of this collapses into an unreadable stream.
claude-devtools renders each subagent as an isolated execution tree with its own tool traces, token metrics, duration, and cost. Nested agents (agents spawning agents) render as recursive trees. Teammate messages are color-coded by sender.
You can see the full team lifecycle: initialization, task coordination, direct messages and broadcasts, shutdown requests, and teardown.
Setting up notification triggers
claude-devtools supports system notifications triggered by patterns in your session. Built-in triggers include:
.env File Access — alerts when Claude reads any .env file
Tool Result Error — alerts on is_error: true responses
High Token Usage — alerts when a single turn exceeds a token threshold (default: 8,000)
You can create custom triggers with regex patterns that match against specific fields (file paths, commands, prompt content, thinking). Assign colors, set ignore patterns, and scope triggers to specific repositories.
This replaces the need to wire up Claude Code hooks manually for every project.
Inspecting remote sessions over SSH
claude-devtools can inspect Claude Code sessions on any remote machine. It reads your ~/.ssh/config for host aliases, supports agent forwarding and key auth, and opens an SFTP channel to stream session logs from the remote ~/.claude/ directory.
Each SSH host gets its own isolated context. Switching between local and remote is instant — the app snapshots your state before the switch and restores it when you return.
This is useful for inspecting sessions that ran on CI machines, cloud instances, or team servers.
Installation
Homebrew (macOS):
brew install --cask claude-devtoolsDirect download: Available for macOS (Apple Silicon + Intel), Windows, and Linux from the GitHub releases page.
Docker:
docker compose up
# Open http://localhost:3456No API keys, no login, no configuration. The app reads ~/.claude/ — the data is already on your machine.
Frequently Asked Questions
What is claude-devtools?
claude-devtools is a free, open-source desktop app that reads Claude Code session logs from ~/.claude/ and reconstructs exactly what happened — every file path, tool call, edit, and token — in a structured, searchable interface. It does not wrap or modify Claude Code.
Where are Claude Code session logs stored?
Claude Code saves all session data to ~/.claude/ on your machine. On macOS: /Users/<you>/.claude/, on Linux: /home/<you>/.claude/, on Windows: C:\Users\<you>\.claude\. These logs exist whether or not you use claude-devtools.
How do I see Claude Code token usage?
claude-devtools provides per-turn token attribution across 7 categories: CLAUDE.md files, skill activations, @-mentioned files, tool call I/O, extended thinking, team overhead, and user text. This replaces the terminal's three-segment progress bar with actual numbers.
Does claude-devtools modify Claude Code?
No. claude-devtools is read-only. It reads the session logs that already exist on your machine and has zero interaction with Claude Code itself. It works with every session you've ever run.
What platforms does claude-devtools support?
macOS (Apple Silicon and Intel), Windows, Linux, and Docker. Install via Homebrew (brew install --cask claude-devtools) or download directly from GitHub releases.
Ready to see what Claude Code actually did?
Free, open source, no setup required.