Codex download: every install route in one place

There is no single Codex download, because Codex is four surfaces that share an account. Decide which one you want first, and the rest is one command.

By the Continuum team. We build a workbench that runs Claude Code, Codex, and their peers, so the model rates quoted here are the ones our own cost analytics ship with.

The short version

For the terminal, run curl -fsSL https://chatgpt.com/codex/install.sh | sh on macOS and Linux, or powershell -ExecutionPolicy ByPass -c "irm https://chatgpt.com/codex/install.ps1 | iex" on Windows. npm install -g @openai/codex and brew install --cask codex also work. For the desktop app, download the ChatGPT desktop app and switch to Codex mode. For the editor, install the openai.chatgpt extension. All four sign in with the same ChatGPT account.

What you need to know
  • Terminal: curl -fsSL https://chatgpt.com/codex/install.sh | sh.
  • Windows: the install.ps1 one-liner. No WSL required.
  • Homebrew ships it as a cask: brew install --cask codex.
  • Desktop app = the ChatGPT desktop app. No separate Codex installer.
  • Air-gapped or proxied? Take the release archive, or force GitHub with CODEX_INSTALLER_USE_RELEASES_OPENAI_COM=false.
  • Every route ends at the same binary and the same ~/.codex.

Pick the surface first

Four downloads, one account. Verified August 2026.

You wantDownloadPlatforms
Codex in a terminalCodex CLImacOS, Linux, Windows
A desktop workbenchChatGPT desktop appmacOS (Apple Silicon), Windows
Codex beside your codeIDE extension openai.chatgptVS Code, Cursor, Windsurf
Nothing installedCodex webAny browser

The CLI, five ways

macOS and Linux. The same command updates an existing install.
curl -fsSL https://chatgpt.com/codex/install.sh | sh

codex --version
Windows. Native, no WSL needed.
powershell -ExecutionPolicy ByPass -c "irm https://chatgpt.com/codex/install.ps1 | iex"

npm

npm install -g @openai/codex

# update
npm install -g @openai/codex@latest

The npm route needs Node 18 or newer, and it inherits the classic global-npm failure: upgrade Node and the command disappears, because the global prefix moved. If that happens, reinstall or switch to the standalone installer.

Homebrew

It is a cask, not a formula.
brew install --cask codex

# update
brew upgrade --cask codex

# where it went
which codex     # $HOMEBREW_PREFIX/bin/codex

A release binary

Right choice for a locked-down machine, a container image, or any environment where piping a script into a shell is not allowed.

Assets on each GitHub release. Pick one.

PlatformAsset
macOS, Apple Siliconcodex-aarch64-apple-darwin.tar.gz
macOS, Intelcodex-x86_64-apple-darwin.tar.gz
Linux, x86_64codex-x86_64-unknown-linux-musl.tar.gz
Linux, arm64codex-aarch64-unknown-linux-musl.tar.gz
Windows, arm64codex-aarch64-pc-windows-msvc.exe.zip
Each archive holds one file, named for its platform. Rename it.
V=rust-v0.147.0
A=codex-aarch64-apple-darwin

curl -fsSLO "https://github.com/openai/codex/releases/download/$V/$A.tar.gz"
tar -xzf "$A.tar.gz"
mv "$A" ~/.local/bin/codex
chmod +x ~/.local/bin/codex

codex --version

DotSlash, for pinning a team

Every release also carries a DotSlash file simply named codex. Commit it and every contributor runs the identical version on whatever platform they use, without anyone installing anything. This is the cleanest answer to "our CI and our laptops are on different Codex versions".

Which route to actually pick

They all end at the same binary, so this is a maintenance decision rather than a capability one. The differences show up months later, when something upgrades underneath you.

RouteBest forFails when
Install scriptAlmost everyoneA proxy blocks both hosts
npmNode shops with an existing global setupYou upgrade Node and the prefix moves
HomebrewMacs where brew upgrade is already a habitNothing much, it is the tidiest on macOS
Release archiveContainers, locked-down machines, air gapsNobody remembers to update it
DotSlashTeams that need one pinned versionYou wanted per-developer freedom

The npm row is the one worth taking seriously. A global npm install lives under whichever Node version prefix was active when you ran it, so a later Node upgrade makes the command vanish with no error, no missing file and no obvious cause. If you have already been bitten by that with another CLI, take the standalone installer and stop thinking about it.

In a Dockerfile, prefer the release archive over any script. It pins a version, adds no package manager to the image, and does not depend on a network host staying reachable at build time. Extract the archive, rename the single file inside it to codex, and put it on PATH.

One thing no route gives you is a signed guarantee across every platform. The Linux musl archives ship with matching .sigstore bundles on each release; the macOS and Windows assets do not carry one in the same form. If your policy requires provenance verification, that asymmetry is worth checking before you standardise on a route rather than after.

Where the installers actually fetch from

Worth knowing before you debug a corporate proxy. The standalone installers download from https://releases.openai.com/codex by default and fall back to GitHub Releases when metadata or an asset is unavailable. You can force the GitHub path:

curl -fsSL https://chatgpt.com/codex/install.sh | CODEX_INSTALLER_USE_RELEASES_OPENAI_COM=false sh
$env:CODEX_INSTALLER_USE_RELEASES_OPENAI_COM='false'; irm https://chatgpt.com/codex/install.ps1 | iex

Requirements, and what to check after

From the openai/codex repository, August 2026.

RequirementDetail
Operating systemmacOS 12+, Ubuntu 20.04+ or Debian 10+, Windows 11
RAM4 GB minimum, 8 GB recommended
Git2.23+, optional, needed for the built-in PR helpers
NodeOnly for the npm route, 18+
AccountChatGPT Plus, Pro, Business, Edu or Enterprise, or an API key
Verify, then sign in.
codex --version
codex doctor            # diagnostic report

codex login             # browser flow, uses your ChatGPT plan
codex login status      # confirm which account is active

echo $OPENAI_API_KEY    # should be EMPTY for subscription billing

That last line matters more than it looks. A stray OPENAI_API_KEY exported months ago for an unrelated script takes precedence over the subscription login, and you will pay per token while holding a plan that already covers it.

Updating and removing

Installed withUpdateRemove
Install scriptRe-run the script, or codex updateDelete the binary
npmnpm i -g @openai/codex@latestnpm uninstall -g @openai/codex
Homebrewbrew upgrade --cask codexbrew uninstall --cask codex
Release archiveDownload the new oneDelete the binary
DotSlashCommit a new DotSlash fileDelete the file

Nothing above touches ~/.codex, so your config, credentials and transcripts survive a reinstall. The one exception is Homebrew's --zap, which deletes that directory on purpose.

Questions people ask

For the terminal run curl -fsSL https://chatgpt.com/codex/install.sh | sh on macOS or Linux, or the install.ps1 PowerShell one-liner on Windows. For the desktop app download the ChatGPT desktop app and switch to Codex mode. For your editor install the openai.chatgpt extension.

Not since July 2026. The standalone Codex app merged into the ChatGPT desktop app, where Codex is a mode alongside Chat and Work. One download covers both.

@openai/codex. Install it with npm install -g @openai/codex. It needs Node 18 or newer, and a later Node upgrade can move the global prefix and hide the command.

Yes, as a cask. brew install --cask codex installs the binary to $HOMEBREW_PREFIX/bin/codex and generates bash, zsh and fish completions. There is no Homebrew formula named codex.

Yes. Every GitHub release carries per-platform archives such as codex-aarch64-apple-darwin.tar.gz and codex-x86_64-unknown-linux-musl.tar.gz. Each archive contains a single file named for its platform, so rename it to codex after extracting.

Yes. The README ships a native PowerShell installer, and Windows binaries are published on every release. The repository requirements table still mentions WSL2, and sandboxing behaves differently between the two, so read the Windows guide before running anything unattended.

The installers fetch from releases.openai.com by default and fall back to GitHub Releases. One of those hosts is usually blocked. Set CODEX_INSTALLER_USE_RELEASES_OPENAI_COM=false to force GitHub, or download the release archive by hand.

Only where you want it to run. Codex web needs nothing installed, and the Remote feature lets a phone drive a desktop app already running on your own machine.

Sources

Every figure above was read from these pages on August 2026. Vendors reprice without notice; if you find a stale number, tell us.

  1. openai/codex on GitHub README install commands, verified 7 August 2026
  2. openai/codex: installing and building
  3. Codex documentation: CLI
  4. Homebrew cask: codex
Try it

Installed once,
watched everywhere.

Continuum tracks every Codex install you run, with live quota gauges, spend by repo, and the binary and model recorded per session.

free app · your subscriptions · local-first