Codex GUI/CLI setup
GUI installation
Install the desktop app that includes Codex.
- Windows
- Linux
- macOS
Windows provides an official installer and also supports installation from the Microsoft Store with winget. Either method works.
Download the official Windows installer ↗
Install with winget
Open PowerShell and run the official installation command below:
winget install --id 9PLM9XGG6VKS -s msstore
After installation, open ChatGPT from the Start menu and sign in.
The Linux desktop app is currently an official preview for Ubuntu, Debian, Fedora, and Arch Linux, with x64 and ARM64 builds.
First check your processor architecture:
uname -m
x86_64 means x64; aarch64 or arm64 means ARM64.
Ubuntu / Debian: download and install the .deb package
Download x64 .deb ↗ · Download ARM64 .deb ↗
After downloading, open a terminal, go to your Downloads directory, and install the matching package:
cd ~/Downloads
sudo apt install ./chatgpt_amd64.deb
cd ~/Downloads
sudo apt install ./chatgpt_arm64.deb
Fedora: download and install the .rpm package
Download x64 .rpm ↗ · Download ARM64 .rpm ↗
After downloading, open a terminal, go to your Downloads directory, and install the matching package:
cd ~/Downloads
sudo dnf install ./chatgpt.x86_64.rpm
cd ~/Downloads
sudo dnf install ./chatgpt.aarch64.rpm
Arch Linux: use the official installation script
The official script detects your processor architecture, configures the signed OpenAI package repository, and installs ChatGPT.
curl --proto '=https' --tlsv1.2 -fL -o install-arch.sh \
https://persistent.oaistatic.com/codex-app-prod/linux/install-arch.sh
sudo bash install-arch.sh
After installation, open ChatGPT from the application menu, or run chatgpt from a terminal. View the official Linux guide ↗
macOS 14 or later supports both Apple Silicon and Intel. The official download page automatically provides the installer for your Mac.
View the full installation steps
- Open the official download page and download the .dmg installer offered for your Mac.
- Open the downloaded .dmg file.
- Drag ChatGPT into the Applications folder.
- Open ChatGPT from Applications, then sign in.
CLI installation
Choose your operating system to install the terminal client.
- Windows
- Linux
- macOS
Choose one method to install Codex CLI in PowerShell.
- curl
- npm
Use curl to download and run the official Windows installer. Node.js is not required.
$codexInstaller = curl.exe -fsSL https://chatgpt.com/codex/install.ps1
if ($LASTEXITCODE -eq 0) {
Invoke-Expression ($codexInstaller -join [Environment]::NewLine)
}
Don’t have curl? Install curl
Recent Windows 10 versions and Windows 11 normally include curl. Check first:
curl.exe --version
If the command is not found, download the archive for your system architecture from the official site. Extract it, add its bin directory to your user Path environment variable, then reopen PowerShell.
Download curl for Windows ↗Install with Chocolatey
If Chocolatey is installed, open PowerShell as administrator and run:
choco install curl -y
No Chocolatey? Official installation guide ↗
Reopen PowerShell after installation. Choose only one installation method.
If Node.js and npm are already installed, run:
npm.cmd install -g @openai/codex
Don’t have npm? Install Node.js and npm
Choose the LTS version on the Node.js website, download the Windows installer (.msi), and complete installation with the default options. npm is included.
Install Node.js ↗Install with Chocolatey
If Chocolatey is installed, open PowerShell as administrator and run:
choco install nodejs-lts -y
No Chocolatey? Official installation guide ↗
Reopen PowerShell after installation. Choose only one installation method.
Reopen PowerShell and check the installation:
node --version
npm.cmd --version
After installation, reopen PowerShell and check the Codex version:
cmd /c codex --version
For WSL, select Linux and install, configure, and run Codex inside WSL.
A version number confirms installation. Use the same installation method when updating to avoid conflicting versions.
Install Node.js LTS for your distribution, then install Codex in a terminal.
node --version
npm --version
npm install -g @openai/codex
codex --version
A version number confirms installation. Use the same installation method when updating to avoid conflicting versions.
Install with Homebrew in Terminal. If you do not have Homebrew, you can use the npm option below.
brew install --cask codex
codex --version
Already have Node.js? Install with npm
Don’t have Node.js? Install Node.js ↗
npm install -g @openai/codex
codex --version
A version number confirms installation. Use the same installation method when updating to avoid conflicting versions.
Connect to Supakook
The GUI and CLI use the same configuration. Prepare your Supakook API key and configure it once.
- Windows
- Linux
- macOS
Find the .codex folder in your user home directory and edit config.toml. If the folder does not exist, create it with the PowerShell commands below.
User configuration file: .codex\config.toml
New-Item -ItemType Directory -Force "$env:USERPROFILE\.codex" | Out-Null
notepad "$env:USERPROFILE\.codex\config.toml"
User configuration file: ~/.codex/config.toml
- Use nano
- Use Vim
mkdir -p ~/.codex
nano ~/.codex/config.toml
Paste the configuration, press Ctrl+O and Enter to save, then Ctrl+X to exit.
No nano? Install nano
Run the command for your Linux distribution, then run the editor command above.
sudo apt update
sudo apt install nano
sudo dnf install nano
sudo pacman -Syu nano
mkdir -p ~/.codex
vim ~/.codex/config.toml
Press i to enter insert mode and paste the configuration. Press Esc, type :wq, and press Enter to save and exit.
No Vim? Install Vim
Run the command for your Linux distribution, then run the editor command above.
sudo apt update
sudo apt install vim
sudo dnf install vim
sudo pacman -Syu vim
User configuration file: ~/.codex/config.toml
mkdir -p ~/.codex
touch ~/.codex/config.toml
open -e ~/.codex/config.toml
Add the following configuration to config.toml and save it.
model_provider = "OpenAI"
model = "gpt-5.5"
review_model = "gpt-5.5"
disable_response_storage = true
network_access = "enabled"
windows_wsl_setup_acknowledged = true
[model_providers.OpenAI]
name = "OpenAI"
base_url = "https://api.supakook.com/v1"
wire_api = "responses"
requires_openai_auth = true
[features]
goals = true
Create auth.json in the same .codex folder, enter your API key, and save it.
- Windows
- Linux
- macOS
.codex\auth.json
New-Item -ItemType Directory -Force "$env:USERPROFILE\.codex" | Out-Null
notepad "$env:USERPROFILE\.codex\auth.json"
~/.codex/auth.json
- Use nano
- Use Vim
mkdir -p ~/.codex
nano ~/.codex/auth.json
Paste the configuration, press Ctrl+O and Enter to save, then Ctrl+X to exit.
No nano? Install nano
Run the command for your Linux distribution, then run the editor command above.
sudo apt update
sudo apt install nano
sudo dnf install nano
sudo pacman -Syu nano
mkdir -p ~/.codex
vim ~/.codex/auth.json
Press i to enter insert mode and paste the configuration. Press Esc, type :wq, and press Enter to save and exit.
No Vim? Install Vim
Run the command for your Linux distribution, then run the editor command above.
sudo apt update
sudo apt install vim
sudo dnf install vim
sudo pacman -Syu vim
~/.codex/auth.json
mkdir -p ~/.codex
touch ~/.codex/auth.json
open -e ~/.codex/auth.json
{
"OPENAI_API_KEY": "YOUR_API_KEY"
}
You can also use CC Switch. If you set CODEX_HOME, use that directory. WSL and native Windows use separate user directories.
Restart and verify
GUI
Fully quit and reopen the app if it is running. Open Codex and a project, then send “Hello” to check the basic connection.
CLI
Exit any running CLI session, then run this in your project folder:
codex
Windows PowerShell can also use:
cmd /c codex
Send “Hello”. This configuration uses the OpenAI provider and gpt-5.5 model.
Troubleshooting
- Command not found: reopen the terminal and check PATH.
- Missing key: check
OPENAI_API_KEYin.codex/auth.json. - 401/403: check your key, balance, and model permissions.
- 404: check the Base URL, Responses support, and model name.
- Settings ignored: check
CODEX_HOME, project settings, and launch arguments.
Official desktop guide · Official CLI guide · Authentication