Claude Code storage
What’s taking up space in ~/.claude, and what you can delete
Claude Code saves every session as a .jsonl file under ~/.claude/projects, keeps debug logs and file snapshots beside them, and never trims any of it. On one developer Mac, 610 sessions took 1.75 GB, about 30% of it embedded screenshots, while public bug reports describe hundreds of gigabytes in ~/.claude/debug and ~/.claude/file-history. Old sessions, debug logs and the CLI cache are safe to remove as long as no claude process is running.
What’s in ~/.claude
Sessions live in ~/.claude/projects, with one folder per project path. Each session is a <uuid>.jsonl file, often with a folder of the same name beside it that holds tool results and subagent transcripts. That folder belongs to the session, so remove both or neither.
~/.claude/debug holds a debug log for each session and ~/.claude/file-history holds snapshots of the files Claude Code edited. When ~/.claude reaches hundreds of gigabytes, these two are usually the reason, because nothing rotates them. The CLI cache and MCP logs sit outside the folder, in ~/Library/Caches/claude-cli-nodejs.
settings.json, your CLAUDE.md memory files and .credentials.json are your configuration and your login. Claude Code can’t rebuild them, so leave them where they are.
Cleaning it up by hand
Measure first, because the large folders grow for different reasons and you clear them in different ways.
- Quit every claude process, including sessions left open in other terminal windows.
- Run du -sh ~/.claude/* | sort -rh to see which folder is large.
- Empty ~/.claude/debug and ~/Library/Caches/claude-cli-nodejs, which Claude Code fills again on its next run.
- Delete old session files in ~/.claude/projects together with their same-named folders.
What Mint adds
In Mint’s Disk tab, Claude Code shows up under Claude with its folders measured. Mint counts your sessions as conversation history and leaves them in place, so removing old sessions is still something you do by hand.
In the Direct and Setapp editions, the Claude Code caches are offered, but only while neither Claude Code nor the Claude app is running. Mint leaves ~/.claude/debug and file-history alone, and it doesn’t shrink the screenshots inside Claude Code sessions, since Optimize works on Codex conversations only.
Things to check before you delete
Don’t run rm -rf ~/.claude. It removes your settings, memory files and login along with every session, and Claude Code won’t start cleanly afterwards.
Keep an eye on free space as well. People have reported Claude Code failing to save its own settings and login once the disk reached zero bytes free, so clear space before your next session.
Frequently asked questions
Is it safe to delete ~/.claude/projects?
Claude Code keeps working, but claude --resume will have nothing left to resume. Removing the individual sessions you haven’t opened in months is the gentler choice.
Does removing a session break anything?
No. In our test with a separate config folder, a removed session simply stopped appearing in claude --resume, and resuming its id failed with a clear message. Nothing else points at the file.
Why is ~/.claude hundreds of gigabytes?
Sessions are rarely the cause at that size. Debug logs and file-history snapshots are, so measure those two folders first.
Can Mint shrink Claude Code sessions the way it does Codex conversations?
No. Optimize works on Codex conversations only, and Mint leaves Claude Code sessions as they are. To free that space, remove old sessions by hand as described above.
See how much space Claude Code is using
Run a scan and find Claude in the Disk tab. Sessions, caches and the other folders in ~/.claude are measured there.