Codex Desktop renderer spins at high CPU while codex MCP servers are idle
Summary
Codex Desktop appears to have a renderer CPU spin issue. A Codex Helper (Renderer) process stayed around 85-120% CPU for roughly an hour, causing a macOS laptop to heat up. Killing/restarting the helper stopped the high CPU, and the machine began cooling down immediately.
The Codex CLI and codex mcp-server processes themselves were low CPU, so this looks like a Desktop/Electron renderer issue rather than backend compute.
Environment
- OS: macOS
- App: Codex Desktop
- Related setup: multiple Claude sessions configured with
codex mcp-server - Workload: long-running Codex Desktop conversation with large outputs/tables and several background MCP server connections
Observed behavior
A Codex Desktop renderer process consumed high CPU continuously:
Codex Helper (Renderer) ~85-120% CPU
RSS ~240 MB
Runtime ~1 hour
At the same time, related backend processes were mostly idle:
codex ~0.5-2% CPU
codex mcp-server 0% CPU
node codex mcp-server 0% CPU
After killing/restarting the renderer/helper process, the high CPU disappeared.
Expected behavior
The Codex Desktop renderer should not remain at high CPU while the Codex CLI and MCP server processes are idle. If there are many MCP connections, long chat history, or heavy tool output, the renderer should throttle, batch UI updates, or otherwise avoid a sustained busy loop.
Possible trigger
This may be related to one or more of:
- Multiple Claude sessions connected to
codex mcp-server - Several simultaneous MCP server connections
- Long chat history / large rendered outputs
- Continuous MCP status or tool event updates
- Electron/React renderer repeatedly re-rendering state even when backend processes are idle
The MCP server itself did not appear to be the CPU source.
Reproduction sketch
- Run Codex Desktop on macOS.
- Configure multiple Claude sessions/processes to use
codex mcp-server. - Keep a long Codex Desktop conversation open with large tool outputs or tables.
- Let the system run for an extended period.
- Observe
Codex Helper (Renderer)in Activity Monitor or viaps.
Suggested areas to inspect
- Renderer update loop for MCP connection state
- Rendering of long tool outputs / long chat histories
- Event batching or throttling for MCP status updates
- Handling of detached or idle MCP connections
- Possible React/Electron re-render loop triggered by multiple MCP clients
If this repo is not the right place for Codex Desktop issues, please route or close with the right tracker.
6 Comments
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
+1
/feedback trace:
2e5ae587-2f13-4fdd-8e7b-0048ea00e492
Adding a more specific root-cause data point from a recurrence on macOS with Codex Alpha Desktop.
The hot process was again the Electron renderer, not the agent backend:
What looked causal in this reproduction:
state db backfill not complete at /Users/lmac/.codex (status: pending)thread/listaround 1.7 MB andapp/listaround 714 KB~/.codex/sessionswas about 1.0 GB total:2026/04: ~704 MB2026/03: ~204 MB2026/02: ~119 MB2026/01: ~32 MBMitigation that did fix it locally:
~/.codex/sessions/2026/01through2026/04aside~/.codex/archived_sessionsasideAfter that, live
~/.codex/sessionsdropped from roughly 1.0 GB to about 15 MB. On relaunch, the renderer stayed near 0.1% CPU and app-server stayed near 0% after startup. The app was still able to run with the current-day session preserved.There were also stale auth/plugin warnings in the fresh logs:
invalid_tokeninvalid_grant: Invalid refresh tokenworkspace_dependenciesmcpServerStatus/listtook about 19s once at startupThose warnings appear worth cleaning up, but they did not correlate with the sustained renderer spin after the session-history/backfill load was removed. The strongest root-cause hypothesis from this repro is: large local session history triggers expensive state DB backfill / thread indexing / renderer hydration on Desktop startup, and the renderer can get stuck in a sustained high-CPU state while processing that state.
Suggested areas to inspect:
~/.codex/sessionstreesthread/listresultsNo raw logs attached here because the local logs may contain sensitive paths/auth context, but I can provide targeted excerpts if useful.
I want to upvote this issue. Codex is using pretty crazy amount of CPU 61% on M5 Pro even when it's idle.
Feedback id: 019deb4d-0626-7a13-8ef2-055bd70c3294
It should include the cpu usage informaiton.
A useful diagnostic would split renderer work from agent/backend work.
When CPU stays high, collect renderer route/view, visible message count, pending MCP connection count, last render cause, transcript size, and app-server activity. If MCP servers are idle, the report should make that clear so the investigation stays on rendering, polling, or virtualization.
---
_Generated with ax._
Note: We've announced that the mcp-server is deprecated and will be removed in a future release. We recommend using the app server interface instead. We won't be prioritizing any bug fixes in the mcp-server, so I'm going to close this issue.