[BUG] mcp add project overwrites existing mcps in project
Resolved 💬 5 comments Opened Feb 23, 2026 by jimweller Closed Mar 26, 2026
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
claude mcp add -s project violator -- violate overwrites existing mcp servers.
What Should Happen?
new mcp should be inserted instead of overwriting existing
Error Messages/Logs
Steps to Reproduce
cat .mcp.json
{
"mcpServers": {
"secret": {
"type": "stdio",
"command" : "secret",
"args": [
"${SECRET}"
],
"env": [
"SECRET", "${SECRET}"
]
}
}
}
claude mcp add -s project violator -- violate
Added stdio MCP server violator with command: violate to project config
File modified: /Users/jimweller/tmp/_crap/.mcp.json
cat .mcp.json
{
"mcpServers": {
"violator": {
"type": "stdio",
"command": "violate",
"args": [],
"env": {}
}
}
}
claude --version
2.1.50 (Claude Code)
Claude Model
None
Is this a regression?
I don't know
Last Working Version
_No response_
Claude Code Version
2.1.50
Platform
Anthropic API
Operating System
macOS
Terminal/Shell
iTerm2
Additional Information
_No response_
This issue has 5 comments on GitHub. Read the full discussion on GitHub ↗