Codex CLI daemon explained: since v0.157.0 it starts a background server and self-updater. Three ways to disable it and a disk cleanup checklist.
Since Codex CLI 0.157.0 on 25 September 2026, starting an interactive codex session also starts a background daemon that keeps running after you close the terminal, and one user reports that daemon is backed by a roughly 374 MB copy of the platform package. A Hacker News thread on 12 October 2026 drew more than 400 points and 218 comments, and the linked GitHub issue is openai/codex #48195, still open when this was written. The shortest fix is one command: codex features disable daemon_auto_start. That command comes from the issue and the HN thread, not from OpenAI's CLI documentation, which does not mention the daemon at all. Below: what the daemon does, why people are angry, three ways to disable it, a disk cleanup checklist, and how Claude Code compares.
What the Codex CLI daemon actually does
OpenAI's Codex changelog lists the change under CLI 0.157.0, dated 2026-09-25: "Enabled automatic background-server startup for eligible interactive sessions." The matching pull request title is "Enable automatic daemon startup by default" (#47179). That is the entire user-facing description. One sentence, no config key named.
The reporter of issue #48195 (Linux and WSL2, CLI 0.157.0, installed through npm) spells out what happens in practice. Four things, according to that report:
- The first interactive session starts a persistent process,
codex app-server --managed-daemon, which survives closing the window and gets reparented to PID 1. - Codex copies the platform package, about 374 MB, into
~/.codex/packages/app-server-daemon/releases/<version>/and runs the daemon from that copy. Its version is therefore decoupled from the npm-installed CLI. - A detached updater,
codex app-server daemon pid-update-loop, checks for updates five minutes after start and hourly after that, then restarts the backend. The reporter links #40969, where a restart killed an active turn. - The daemon inherits the environment of whichever session started it. Later sessions' variables, such as
HTTPS_PROXY, are ignored.
These are one user's observations on one platform. I could not reproduce them here, and OpenAI has not published a design note that confirms the byte counts or the five-minute and hourly timings. Treat the numbers as reported, not specified.
A fifth claim deserves its own paragraph. A commenter on the issue says the daemon leaks environment variables from the first directory where Codex ran, with direnv-loaded values such as GH_TOKEN as the example. It is a single report with a suggestion to file it separately. If you load secrets per directory, it is worth testing before you assume your tokens stay scoped to one project.
Why people are angry
Three complaints dominate the HN thread. None of them is that a daemon exists. Plenty of tools run one. The complaint is that it arrived on by default, with one changelog sentence, and with an opt-out that is not in the config reference. A commenter on the GitHub issue made the same point: the opt-out "is still invisible in the official config reference."
Disk usage
The HN numbers are anecdotes, but they are consistent with each other. One commenter says old versions piled up to roughly 12 GB. Another says ~/.codex/packages/standalone/releases keeps every old version, each binary about 300 MB. A third found 11 separate codex and codex-code-mode-host binaries in a Bun install cache under @openai, again about 300 MB each. Eleven times 300 MB is 3.3 GB before you count the daemon copy.
Background processes that outlive the session
A process that survives exit surprises people on laptops, in containers, and on shared dev boxes. The issue adds a specific bug: codex app-server daemon stop stops the app server but leaves the pid-update-loop updater running, so you kill it by hand.
Auto-updates and read-only paths
One HN commenter reports that auto-updates made .git and other paths read-only, which blocked their work. I found no confirmation from OpenAI, and no GitHub issue in the material I read that reproduces it. Treat it as a single user report. The related complaint is better documented: an updater that restarts the backend can interrupt a running turn, which is the #40969 case.
OpenAI is patching around the edges. The changelog for 0.162.0 (2026-10-08) includes "Skip daemon auto-start for Windows-mounted WSL homes" (#50555), and 0.162.1 (2026-10-09) fixes a startup failure caused by mismatched feature settings on a running background server. Neither changes the default on Linux or macOS. Downstream, a Nix packaging commit dated 28 September disables the auto-start by default, which tells you what packagers think of it.
Comments · 0
Beta: comments are stored locally on your device and not visible to other readers.
No comments yet. Be the first to share your thoughts.