Download Codex
Every official way to install Codex on Windows, macOS and Linux, with the right binary for your architecture — and the install route that causes most problems.
Get the right build#
Pick your platform below, or browse the latest release directly.
The fastest route: the official install script#
This is what OpenAI ships, and it picks the right binary for your machine automatically.
# macOS and Linux
curl -fsSL https://chatgpt.com/codex/install.sh | sh# Windows
powershell -ExecutionPolicy ByPass -c "irm https://chatgpt.com/codex/install.ps1 | iex"Then confirm it worked — always do this before involving any GUI or editor extension:
codex --version
codex loginStandalone installers pull from https://releases.openai.com/codex.
Or install with npm#
npm install -g @openai/codex
codex --versionOr download a binary directly#
Zero dependencies, no Node required. Pick the file matching your platform and architecture from the latest release:
| Platform | Asset |
|---|---|
| Windows x64 | codex-x86_64-pc-windows-msvc.exe |
| Windows ARM64 | codex-aarch64-pc-windows-msvc.exe |
| macOS Apple Silicon | codex-aarch64-apple-darwin.tar.gz |
| macOS Intel | codex-x86_64-apple-darwin.tar.gz |
| Linux x64 | codex-x86_64-unknown-linux-musl.tar.gz |
| Linux ARM64 | codex-aarch64-unknown-linux-musl.tar.gz |
A release carries over a hundred assets — build tooling, sandbox helpers, the app-server, signature files. The table above is the short list of what most people actually want. There is also a codex-aarch64-apple-darwin.dmg if you prefer a disk image on Apple Silicon.
Just the app-server#
If you're building a client rather than using Codex interactively, the app-server ships as its own binary:
codex-app-server-x86_64-pc-windows-msvc.exe
codex-app-server-aarch64-apple-darwin.tar.gz
codex-app-server-x86_64-unknown-linux-musl.tar.gzThere are also codex-app-server-package-* archives if you want the bundled form.
Verifying what you downloaded#
Linux musl builds ship .sigstore bundles alongside them — for example codex-x86_64-unknown-linux-musl.sigstore. If you're deploying Codex somewhere that matters, verify the signature rather than trusting the transfer:
cosign verify-blob \
--bundle codex-x86_64-unknown-linux-musl.sigstore \
codex-x86_64-unknown-linux-musl.tar.gzThis is also the correct answer to "should I download Codex from a mirror?" — if a build isn't accompanied by a signature you can check against OpenAI's identity, don't run it.
Avoid the Microsoft Store build#
If you're on Windows, this is the single most useful thing on this page.
The Store/MSIX package is heavily over-represented in reported failures. Everything under C:\Program Files\WindowsApps\ carries restrictive ACLs by design, and running the packaged executable directly returns "Access is denied". That surfaces later as failed to start codex app-server (os error 3).
In issue #20048, a user on Store build 26.422.8496.0 reported that restarting Windows, repairing the app, resetting it, reinstalling it, and even installing the npm CLI alongside it all failed. Reinstalling the same Store package brings the same ACLs back with it.
The fix is to change install method, not to reinstall:
# remove the Store version first, then
powershell -ExecutionPolicy ByPass -c "irm https://chatgpt.com/codex/install.ps1 | iex"
# or
npm i -g @openai/codexThe Store package is also implicated in the manifest entry is missing family, where a non-atomic update leaves the native-messaging manifest pointing at a removed AppX directory.
Which method should you pick?#
| You want | Use |
|---|---|
| The simplest thing that works | Official install script |
| To manage it with your other global tools | npm i -g @openai/codex |
| No Node.js dependency at all | Direct binary from releases |
| To pin an exact version | Direct binary, or npm i -g @openai/codex@<version> |
| Only the app-server, for a custom client | codex-app-server-* asset |
| Windows, and you want fewest problems | Install script or npm — not the Store |
A note on Windows sandboxing#
Codex on native Windows uses an AppContainer-based sandbox that restricts filesystem writes and limits network access by default, and OpenAI still labels Windows sandbox support as experimental.
If Codex appears to run but can't write files where you expect, that's the sandbox rather than a broken install. Running inside WSL avoids this entirely, at the cost of keeping your repository and toolchain on the WSL side — mixing the two causes its own problems.
After installing#
codex --version # confirm the binary resolves
codex login # authenticate
codex # start a session, standaloneGet all three working before connecting an editor extension or a GUI like T3 Code. Those launch Codex as a subprocess, so anything broken at this level shows up there as a confusing, unrelated-looking error.
FAQ#
Where do I download Codex?#
From OpenAI's official install script at chatgpt.com/codex/, from npm as @openai/codex, or as a prebuilt binary from the openai/codex GitHub releases page. Standalone installers are served from releases.openai.com/codex.
How do I install Codex without the Microsoft Store?#
Use the PowerShell install script, powershell -ExecutionPolicy ByPass -c "irm https://chatgpt.com/codex/install.ps1 | iex", or npm i -g @openai/codex. Both avoid the WindowsApps directory whose restrictive ACLs cause a large share of reported startup failures.
Why does my Codex install not work after npm install?#
The most common cause is installing the wrong package. It must be @openai/codex with the scope — the unscoped codex on npm is an unrelated project from 2012.
Which Codex file should I download for my computer?#
Windows x64 needs codex-x86_64-pc-windows-msvc.exe, Apple Silicon needs codex-aarch64-apple-darwin.tar.gz, and Linux x64 needs codex-x86_64-unknown-linux-musl.tar.gz. The detector at the top of this page picks the right one automatically.
Can I download just the Codex app-server?#
Yes. Each release publishes codex-app-server-* binaries for every platform, plus codex-app-server-package-* archives, which is what you want if you're building your own client rather than using Codex interactively.
Is it safe to download Codex from a third-party site?#
Don't. Use OpenAI's install script, npm, or the GitHub releases page. Linux builds ship .sigstore signature bundles you can verify with cosign — if a build has no verifiable signature tied to OpenAI's identity, don't run it.