The mcp I configured in .claude.json is reset as soon as the proxy starts - Claude Code
Quick fix
CC Switch syncs by full overwrite. Import your MCP servers and manage them all inside CC Switch rather than editing .claude.json.
Symptom
Section titled “Symptom”一启动代理我在.claude.json里配置的mcp就会被重置The mcp I configured in .claude.json is reset as soon as the proxy starts
The CC Switch database is the single source of truth (SSOT), and exporting configuration writes every enabled server into the config file of the matching application (`.claude.json` or `config.toml`) wholesale rather than merging incrementally. So if you add an MCP server or other configuration by hand on the application side, starting or restarting CC Switch overwrites those manual edits entirely and restores the original settings.
In the CC Switch MCP management screen, use the import feature to pull the MCP servers you added by hand back in from each application config file.
From then on, add, change, and delete MCP servers only inside CC Switch and let it sync to the application config files automatically — never edit those by hand.
Affected Versions
Section titled “Affected Versions”Source Issues
Section titled “Source Issues”This page is distilled from 2 real issues
- base_url reverts and my MCP configuration is lost after closing CC Switch. What now?
- That is the normal full-sync mechanism: on close, CC Switch cleans up the proxy configuration it manages. Make sure all your MCP configuration is imported into CC Switch, and turn it back on there after restarting — it writes the config file automatically.
- I broke the format editing .claude.json by hand and CC Switch stopped working. How do I handle that?
- Do not edit `.claude.json` directly. If the file is already corrupted, re-import or reconfigure through CC Switch and let it manage the configuration from then on.
Related problems
Section titled “Related problems”This is an unofficial community wiki with no affiliation to the cc-switch authors or the project itself. Its content is compiled from the project's public GitHub issues. This site distributes no software.