OpenAI Codex CLI Pricing Guide 2026
Codex CLI is OpenAI's command-line tool for AI-assisted coding. It uses OpenAI's o-series models and GPT-4o under the hood. Like other CLI tools, the software is free — you pay for API usage.
Visit OpenAI Codex CLI →OpenAI Codex CLI Pricing Plans
| Component | Cost | Details |
|---|---|---|
| Codex CLI | Free | Open source CLI from OpenAI |
| o3 model | $10.00/M input, $40.00/M output | Latest reasoning model |
| o3-mini | $1.10/M input, $4.40/M output | Budget reasoning |
| gpt-4o | $2.50/M input, $10.00/M output | General purpose |
Best AI Models for OpenAI Codex CLI (2026)
Based on cost-effectiveness, coding quality, and availability. Data updated Apr 18, 2026.
GPT-4o mini
OpenAI · $0.150/M input
High-volume tasks, simple coding, cost-sensitive projects
View full pricing →GPT-4o mini
OpenAI · $0.150/M input
High-volume tasks, simple coding, cost-sensitive projects
View full pricing →GPT-4
OpenAI · $30.00/M input
Legacy applications requiring GPT-4 specifically
View full pricing →Cost Per Session with OpenAI Codex CLI
Estimated cost for a medium feature implementation (100K input + 10K output tokens).
| Model | Provider | Cost/Session | Input Price | Output Price |
|---|---|---|---|---|
| GPT-4o mini | OpenAI | $0.18 | $0.150/M | $0.600/M |
| GPT-4.1 mini | OpenAI | $0.46 | $0.400/M | $1.60/M |
| GPT-3.5 Turbo | OpenAI | $0.48 | $0.500/M | $1.50/M |
| OpenAI o1-mini | OpenAI | $1.27 | $1.10/M | $4.40/M |
| OpenAI o3-mini | OpenAI | $1.27 | $1.10/M | $4.40/M |
| OpenAI o4-mini | OpenAI | $1.27 | $1.10/M | $4.40/M |
Frequently Asked Questions
Is Codex CLI free?
The CLI is free and open source. You pay for OpenAI API usage.
What models does Codex CLI use?
Codex CLI uses OpenAI's o3, o3-mini, and GPT-4o models depending on the task complexity.
How much does a typical Codex CLI session cost?
With o3-mini, a medium feature costs about $0.15. With GPT-4o, about $0.35.
Compare OpenAI Codex CLI with Other Platforms
See how OpenAI Codex CLI stacks up against the competition.
View all AI coding platforms →