Repository navigation
Closed as not planned
Closed as not planned
Copy link
Labels
area:corearea:securitybugSomething isn't workingSomething isn't workingduplicateThis issue or pull request already existsThis issue or pull request already existsmemoryperf:memory
Description
Summary
This issue consolidates widespread user frustration about .claude.json file bloat from storing unbounded conversation history in what should be a configuration file.
Impact Scale
- Multiple reports of files growing to 65MB+
- Affecting numerous users across issues History accumulation in .claude.json causes performance issues and storage bloat #5024, Bug: .claude.json automatically stores conversation history when it shouldn't #1449, Unify MCP configuration and separate from conversation history #2539, ~/.claude.json file JSON Configuration File Corruption with Chat Sessions #6181, [BUG]
.claude.jsonis trucated directly, and so occasionally gets corrupted #2593, claude code corrupts ~/.claude.json on mac while running 5 concurrent sessions #3117 - Causing real operational failures, not just inconvenience
Critical Problems Reported by Users
1. Performance Degradation
- Slow Claude Code startup times
- MCP server initialization failures
- System resource exhaustion
- 72+ duplicate MCP processes spawning (reported by @vincentortegajr)
2. Data Loss & Corruption
- File corruption during concurrent sessions (claude code corrupts ~/.claude.json on mac while running 5 concurrent sessions #3117)
- Configuration loss when manually cleaning history
- Truncation issues leading to invalid JSON ([BUG]
.claude.jsonis trucated directly, and so occasionally gets corrupted #2593)
3. Developer Workflow Disruption
- Version control pollution - constant dirty state
- Cannot safely version control configurations
- Privacy concerns with sensitive conversations in config files
- Manual cleanup required repeatedly
Community Sentiment (Direct Quotes)
- "This is nuts to do this in this manner" - @nonrev76
- "IT MAKES THE ENTIRE claude.json COMPLETELY UNUSABLE" - @cosier
- "Totally unacceptable to be storing mutable data in a config file" - @rebuyengine
- "Storing unbounded conversation history in a config file doesn't make sense" - @dimension-zero
Proposed Solutions from Community
- Short-term: Automatic rotation after size/age limits
- Long-term: Separate history from configuration entirely
- for settings
- for per-project history
- Use proper cache directories for ephemeral data
Current Workarounds Are Insufficient
- No built-in cleanup mechanism
- Manual editing risks breaking MCP configurations
- Users resorting to backup/restore cycles
Request
Please prioritize this issue. It's not just a minor inconvenience - it's causing:
- Operational failures
- Data loss
- Significant user frustration
- Trust erosion in the tool
The community needs at minimum:
- An immediate hotfix for cleanup
- A roadmap for proper separation of concerns
- Clear communication about timeline
Thank you for your attention to this critical issue affecting daily workflows.
Related Issues
- History accumulation in .claude.json causes performance issues and storage bloat #5024 (main tracking issue)
- Bug: .claude.json automatically stores conversation history when it shouldn't #1449 (closed but unresolved)
- Unify MCP configuration and separate from conversation history #2539 (separation proposal)
- ~/.claude.json file JSON Configuration File Corruption with Chat Sessions #6181, [BUG]
.claude.jsonis trucated directly, and so occasionally gets corrupted #2593, claude code corrupts ~/.claude.json on mac while running 5 concurrent sessions #3117 (corruption reports)
Submitted on behalf of affected users who have been reporting this issue for months
Reacted by Thinh Dinh, cIrCuS_tIgEr, Robert, Jacob Hoehler, Aleksandr Kiusev, Dominic, David Patschke, Luke Memet, Craig Hughes, Paul Berg and 11 more
Metadata
Metadata
Assignees
Labels
area:corearea:securitybugSomething isn't workingSomething isn't workingduplicateThis issue or pull request already existsThis issue or pull request already existsmemoryperf:memory
Activity
github-actions commentedon Aug 23, 2025
Found 3 possible duplicate issues:
This issue will be automatically closed as a duplicate in 3 days.
🤖 Generated with Claude Code
tobalsan commentedon Aug 23, 2025
+1000 for this.
MCP management is particulary frustrating.
Much better experiencer to have a user-level
.mcp.json, or at the very least, add anmcpServerskey to~/.claude/settings.json. We are a lot to want to be able to:~/.claude.jsonfile.See also #3321.
jeffstone30 commentedon Aug 24, 2025
+10000 for this.
This is pretty crazy. I didn't realize copy + pasting images into Claude Code on my Mac Air was storing those images' binary data into the ~/.claude.json file!!!
I have been having issue over the past few days with Claude Code. Thought it was a degradation of the service. I went in and cleaned this 50MB file back down to about 25KB, and now Claude Code is working again....that is until I paste some more images into it. Pasted about 5 images and my .claude.json file is back up to 11MB and the service is having issues again.
This is drastically effecting the performance of this product and needs to be fixed.
dimension-zero commentedon Aug 25, 2025
Really do not understand this design decision!
ZmeiGorynych commentedon Aug 25, 2025
It's not just about bloat - Claude Code randomly overwrites my edits, such as MCP servers I add, in
~\.claude.json. Mixing up a global-scope config file with some kind of randomly overwritten internal cache functionality by CC is a really, really bad idea.dpatschke commentedon Aug 29, 2025
I ran into this bug today. Not sure what is causing it because it is not happening to a colleague who is running Claude Code via WSL on a Windows system. I'm on Ubuntu 20.04. Is it the OS? Is it the Claude version?
Opus told me to
sudo chattr -i ~/.claude.jsonwith a barebones.claude.json.Claude code won't even launch.
Whatever this is ... it's bad.
UPDATE: colleague not experiencing issues is on CC 1.0.77. I'm on 1.0.96.
dimension-zero commentedon Aug 29, 2025
I'm worried. Claude Code is the #1 Big Dog in agentic coding. But we have Gemini CLI, OpenAI Codex, Amazon Kiro, DeepSeek Coder, Kilo Code, RooCode, OpenCode, Qwen Coder, and others emerging as well as existing Cursor, Cline & RooCode. Yet @anthropics is possibly regressing Claude Code despite competition. Amodei et al. - please listen up. Fingers in ears doesn't work so I hope this is not the plan.
tobalsan commentedon Aug 30, 2025
I'll give Anthropic the benefit of the doubt. I don't think they are "fingers and ears." Rather, their small team, coupled with the huge popularity of Claude Code, means their ears are likely overwhelmed by the noise.
dimension-zero commentedon Aug 30, 2025
Very much hope you are right. Changing tools every few weeks is exhausting everyone. We all need a stable toolchain!
11 remaining items
tobalsan commentedon Sep 10, 2025
hey that’s cool stuff here.
I’m gonna put it in a hook I think.
ctoth commentedon Sep 27, 2025
How many SSDs will wear out prematurely because of this bug? Really hoping for some sort of response/recognition here even if it's automated triage? Seriously put the conversations in SQLite where they belong and use the config file for ... config and don't write an entire massive file on each action!
louis030195 commentedon Oct 6, 2025
i guess it's time to churn from anthropic since they don't seem to care about their own product
dpatschke commentedon Oct 6, 2025
I had hopes that Sonnet 4.5 and CC v2 would improve the UX, but alas .. my hopes have been crushed.
Today, Claude Code did unbelievably poorly for me on a task with a detailed to-do list.
I then asked Codex CLI to grade the implementation which came back as an "F".
I then asked CC to perform a deep dive self-assessment on where and why it went wrong and write this assessment out as a markdown file.
I took this markdown file and passed it into GPT 5-Thinking asking it for an executive summary for "HR-related" records.
Here is what was returned:
Assessment Summary (Executive-Level, HR Audit)
Core Shortcomings
Capability & Limitations When Extending Existing Systems
Experience Estimate
Rehire Recommendation
If low-supervision, high-reliability delivery is required, seek a more senior development resource.
I don't know about everyone else, but each one of the Core Shortcomings is what I'm experiencing on a repeated basis with CC and it has really only begun in the last several months. It didn't used to be this bad. Something has gone horribly, horribly wrong.
dimension-zero commentedon Oct 7, 2025
A fundamental issue with CC is its euphoric & premature over-celebration of its own achievements. This causes CC to cover-estimate delivery and stop early.
Aggressive negative language in prompts can mitigate this. Also you can prompt things like "Constructively critique your last response", "fact-check your claims" or "reality check your last response" and this can work well. But this is just papering over the "I've been at the happy pills" cheerleading stuff.
The system prompt needs to change to be more sober in its assessments but unless CC is open sourced or more configurable we don't have that option.
Absent that, CC's hopes of running long-running prompts are self-sabotaged as it interprets "wrote one line of code" as "delivered an entire tested system" etc.
Aside from this behavior, all those over-excited claims and emoji spam seriously grate. You don't get it from other agents.
smolcove commentedon Oct 10, 2025
This: much better experiencer to have a user-level .mcp.json, or at the very least, add an mcpServers key to ~/.claude/settings.json.
github-actions commentedon Dec 10, 2025
This issue has been inactive for 30 days. If the issue is still occurring, please comment to let us know. Otherwise, this issue will be automatically closed in 30 days for housekeeping purposes.
kolkov commentedon Dec 10, 2025
Not fixed still...
github-actions commentedon Jan 11, 2026
This issue has been automatically closed due to 60 days of inactivity. If you're still experiencing this issue, please open a new issue with updated information.
marcindulak commentedon Jan 11, 2026
This issue was closed incorrectly despite recent human comments. This behavior of the bot is reported at #16497
github-actions commentedon Jan 18, 2026
This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.