Skip to content

A disabled MCP becomes active again after restarting the machine - Codex

Quick fix

No official fix yet: clean the conflicting MCP nodes out of the config file by hand, and use deeplink import carefully so custom settings survive.

Error output
重启电脑,打开 Codex 终端,会发现禁用的 MCP  会再次生效
English translation

Restart the machine and open the Codex terminal, and you find the disabled MCP active again

cc-switch rebuilds and overwrites templates when managing Codex config. On a system restart, or when importing a provider through a deeplink, the underlying `build_codex_settings` regenerates a fixed TOML template, so a disabled MCP service (`[mcp_servers.time]`, for example) is written back and becomes active again, while non-provider custom settings such as `web_search` are discarded. Separately, Codex uses TOML while Claude uses JSON, so managing the same MCP service under different CLIs readily creates config conflicts. Since no fix has been merged for the related issues (some closed as stale), manual intervention is the only option today.

  1. With no automatic fix available officially, open the Codex config file by hand and delete or comment out the MCP nodes that came back (`[mcp_servers.time]` or `[mcp_servers.serena]`, for example).

  2. When importing a provider deeplink, avoid links carrying an inline `config` payload, so `build_codex_settings` does not rebuild the template and overwrite your custom fields.

ToolCodex
VersionUnknown
PlatformsWindows
Why does configuring the same MCP service in Codex and Claude create a conflict?
Because the config formats of the two CLIs differ — Codex uses TOML while Claude uses JSON — so managing them together can overwrite or conflict.
Why did my `web_search` and other custom config disappear after importing a deeplink?
After you confirm the import, `build_codex_settings` rebuilds a fixed TOML template, and that process discards non-provider Codex custom settings.

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.