Codex config.toml Overwritten by CC Switch, Plugins and Settings Lost
Quick fix
Upgrade to cc-switch v4.0.0; it removes full backup restoration and replaces only key fields when switching, preserving other Codex settings.
Symptom
Section titled “Symptom”The Codex theme, plugins, skills, MCP servers, memories, and other user settings are no longer in their latest state.Older versions of CC Switch may restore the entire Codex config.toml from a backup made before takeover when exiting or restarting, reverting themes, plugins, and other settings. Other configuration writes or sync paths can also change its contents: MCP sync exports all servers enabled in the database; generic configuration previously had append or merge issues; and backfilling could store runtime sections and local paths from the live configuration in provider templates. In the related issues, the maintainer stated that v4.0.0 removed backup restoration and backfilling; when switching, it replaces only key fields and leaves the rest unchanged.
Upgrade to cc-switch v4.0.0 or a later version. The maintainer says this version removed full backup restoration: on exit it writes back only key fields, and when switching providers it also replaces only key fields.
If MCP servers reappear after sync, delete unwanted entries in CC Switch's MCP management and check the MCP contents in each Codex provider configuration. MCP sync exports servers enabled in the database to the application configuration.
Affected Versions
Section titled “Affected Versions”Source Issues
Section titled “Source Issues”This page is distilled from 7 real issues
- #35不能给codex的配置文件添加mcp server服务
- #955[Bug] Codex MCP stale enabled_codex rows are re-injected on switch/sync and overwrite ~/.codex/config.toml
- #1028cc-switch的mcp配置问题
- #1189bug: Codex 通用配置写入 config.toml 采用追加而非智能插入逻辑
- #2670[Question] Codex 通用配置机制咨询(配置反复意外变化)
- #5395bug: Codex provider backfill stores live-only TOML sections and machine-local paths in settings_config
- #7235[Windows] Codex config.toml 被 CC Switch 覆盖,导致插件和外观设置丢失
- What should I do if the problem persists after upgrading to v4.0?
- The maintainer recommends adding the version and reproduction steps, then reopening the issue.
- If I manually added an MCP server in the Codex app, how can I have CC Switch manage it?
- First import it from the application configuration file in CC Switch's MCP management, then let CC Switch manage syncing centrally.
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.