Codex CLI 0.173.0 Shares MCP Connections by Default and Accepts Legacy Local Servers
Codex CLI 0.173.0 turns on MCP connection sharing by default and accepts legacy local MCP servers, cutting process sprawl for parallel agent fleets.
OpenAI shipped Codex CLI 0.173.0 on December 2, and the headline change is not a new UI surface — it is a plumbing default that changes how every Codex session on your machine talks to MCP servers. Codex now shares MCP connections by default and tolerates older local MCP servers that expect initialize as their first request. For operators running multiple sessions against the same local tool servers, that means fewer spawned processes and fewer mysterious startup failures against servers written before the current discovery flow existed.
The release notes list the change plainly: “Codex shares MCP connections by default and supports older local servers that require initialize as their first request.” The work landed in pull request 62552, which marks the mcp_connection_sharing feature stable and flips it on.

Why connection sharing matters
Before this release, each Codex session that needed an MCP server could end up with its own connection to it. Run three or four parallel sessions — a common pattern for agent fleets — and a single heavyweight local server gets spawned three or four times, each copy holding memory and a stdio pipe. Sharing one connection across sessions collapses that multiplication: one server process, many callers.
This is a direction the whole harness category is drifting. OpenCode added opt-in MCP connection pooling earlier this year, and Codex now goes one step further by making sharing the default rather than a toggle: treat MCP servers as shared machine-level services rather than per-session accessories.
The legacy-server fix is the quieter win
The more interesting half of #62552 is what it does for older servers. Modern Codex probes a local stdio MCP server with a server/discover request. Legacy servers never learned that method: they return an empty response, take longer to initialize than the discovery watchdog allows, or simply require initialize as their first request. Under the old behavior those servers failed to attach — and operators usually blamed the server.
The pull request fixes the handshake in three ways:
- An empty discovery response is now treated as an unsupported method rather than a failure.
- Legacy initialization falls back to the configured startup timeout instead of the shorter discovery watchdog.
- A legacy server that needs restarting gets a fresh timeout, while modern version retries stay inside the original deadline.
If you maintain MCP servers wired into Codex via config.toml and one of them has been flaky at startup, this release is the reason to retest it before you rewrite it. Our Codex MCP setup guide covers where those tables live.
What else ships in 0.173.0
Two other changes are worth an operator’s attention:
Blocking hook failures. Supported synchronous command and MCP tool hooks can now set onFailure to block. A failed PreToolUse check prevents the tool from running at all, rather than logging and continuing. That turns hooks into real pre-action gates instead of advisory checks — the same shift Claude Code made when failing hooks started blocking, and it changes what you can safely enforce on unattended lanes.
An administrator kill switch for daemon updates. Setting features.daemon_updates = false in managed requirements.toml or local MDM policy blocks both scheduled and manual daemon updates. Fleet operators who need to pin a known-good binary now have a supported way to stop the daemon from updating itself underneath them.
The release also adds alignable custom status lines — PR 62569 adds justify: "start" and justify: "between" to statusline rows, so two groups stay pinned to opposite terminal edges as the width changes — richer terminal Markdown rendering for Mermaid edge labels and LaTeX underbraces, automatic OAuth endpoint discovery for config servers when config_server.oauth is omitted, and a batch of fixes including sidebar previews that refresh when files change on disk and pasted image attachments that survive the original file being moved or deleted.
What to check after upgrading
- Retest legacy MCP servers. Anything that previously failed discovery should attach now. If a server still hangs, check the startup timeout rather than the discovery watchdog — see our MCP timeout guide for the knobs.
- Watch process counts. With sharing on, parallel sessions should reuse one server process. Confirm with your process monitor on a busy day; a drop in resident MCP processes is the visible effect.
- Audit your hooks. If you already run synchronous
PreToolUsechecks, decide explicitly whether a failure should block, and setonFailureaccordingly rather than inheriting whatever the default becomes. - Pin your daemon if you pin anything else. If your fleet pins model IDs and CLI versions,
daemon_updates = falsecloses the gap where the daemon updated itself anyway.
Connection sharing as a default is a small line in a long changelog, but it is the kind of default that compounds: every parallel-session fleet picks up lower memory use and faster session starts without changing a single line of configuration. Combined with real tolerance for legacy MCP servers, 0.173.0 quietly removes two of the most common reasons a Codex MCP setup misbehaved.