OpenAI: GPT-5.1-Codex
🇺🇸 OpenAI · GPT-5.1-Codex
Overview
OpenAI: GPT-5.1-Codex is a large language model API from OpenAI, part of its GPT-5.1-Codex model family. Priced at $1.25 per million input tokens and $10.00 per million output tokens, it occupies the mid-range, balancing capability against running cost. Output tokens cost about 8× as much as input, so prompt-heavy workloads run noticeably cheaper than generation-heavy ones. A large 400K-token context window (≈600 pages of text) lets it take in whole books, large codebases, or lengthy transcripts in a single call. Beyond plain text it also accepts Image input, so it can be applied to multimodal tasks rather than text alone. On Artificial Analysis's Intelligence Index it scores 35 (C grade), a useful proxy for its general reasoning strength relative to the other models tracked here. All prices on this page reflect OpenRouter's routed rates and are re-synced automatically every day; confirm against the provider's official pricing before committing to production.
| Dimension | Unit | Price (USD) |
|---|---|---|
| Input | per 1M tokens | $1.25 |
| Output | per 1M tokens | $10.00 |
| Cached Input | per 1M tokens | $0.130 |
| Web Search | per search | $0.010 |
- Provider
- OpenAI
- Model Family
- GPT-5.1-Codex
- Version String
- openai/gpt-5.1-codex
- Status
- Active
- Modality
- Text, Image
- Context Window
- 400,000 tokens
- Output Limit
- 128,000 tokens
Index Metrics
Cross-domain capability indexes evaluated by Artificial Analysis — Artificial Analysis
Benchmark Scores
Data source: Artificial Analysis
Performance Metrics
Real-world benchmarks, updated every 72 hours by Artificial Analysis — Artificial Analysis
Use Case Analysis
Model strengths, weaknesses, and ideal use cases based on benchmarks and official documentation
Strength
- Agentic Coding Optimization Specifically trained for agentic coding tasks in Codex environments. Better at sustained long-horizon coding. Official
Best For
- Long-running Coding Agents Complex refactors, multi-hour agent loops, and sustained coding work in Codex. Official
Not Recommended
- General Purpose Tasks Use GPT-5 or GPT-5.5 for non-coding tasks. Official
90-Day Price Trend
Input / Output price (USD per 1M tokens)
Past 90 days of records; every price change is shown here
| Date | Dimension | Price (USD) | Source |
|---|---|---|---|
| Web Search | $0.010 | OpenRouter | |
| Cached Input | $0.130 | OpenRouter | |
| Output | $10.00 | OpenRouter | |
| Input | $1.25 | OpenRouter | |
| Web Search | $0.010 | OpenRouter | |
| Cached Input | $0.130 | OpenRouter | |
| Output | $10.00 | OpenRouter | |
| Input | $1.25 | OpenRouter | |
| Web Search | $0.010 | OpenRouter | |
| Cached Input | $0.130 | OpenRouter | |
| Output | $10.00 | OpenRouter | |
| Input | $1.25 | OpenRouter | |
| Web Search | $0.010 | OpenRouter | |
| Cached Input | $0.130 | OpenRouter | |
| Output | $10.00 | OpenRouter | |
| Input | $1.25 | OpenRouter | |
| Web Search | $0.010 | OpenRouter | |
| Cached Input | $0.130 | OpenRouter | |
| Output | $10.00 | OpenRouter | |
| Input | $1.25 | OpenRouter | |
| Web Search | $0.010 | OpenRouter | |
| Cached Input | $0.130 | OpenRouter | |
| Output | $10.00 | OpenRouter | |
| Input | $1.25 | OpenRouter | |
| Web Search | $0.010 | OpenRouter | |
| Cached Input | $0.130 | OpenRouter | |
| Output | $10.00 | OpenRouter | |
| Input | $1.25 | OpenRouter | |
| Web Search | $0.010 | OpenRouter | |
| Cached Input | $0.130 | OpenRouter | |
| Output | $10.00 | OpenRouter | |
| Input | $1.25 | OpenRouter | |
| Web Search | $0.010 | OpenRouter | |
| Cached Input | $0.130 | OpenRouter | |
| Output | $10.00 | OpenRouter | |
| Input | $1.25 | OpenRouter | |
| Web Search | $0.010 | OpenRouter | |
| Cached Input | $0.130 | OpenRouter | |
| Output | $10.00 | OpenRouter | |
| Input | $1.25 | OpenRouter | |
| Web Search | $0.010 | OpenRouter | |
| Cached Input | $0.130 | OpenRouter | |
| Output | $10.00 | OpenRouter | |
| Input | $1.25 | OpenRouter | |
| Web Search | $0.010 | OpenRouter | |
| Cached Input | $0.130 | OpenRouter | |
| Output | $10.00 | OpenRouter | |
| Input | $1.25 | OpenRouter | |
| Web Search | $0.010 | OpenRouter | |
| Cached Input | $0.130 | OpenRouter |
Key Insights
Key data points from this page for quick reference and citation.
- OpenAI: GPT-5.1-Codex Input price: $1.25/M tokens
- OpenAI: GPT-5.1-Codex Output price: $10/M tokens
- Context window: 400,000 tokens
- Provider: OpenAI
- Model family: GPT-5.1-Codex
- Modalities: Text, Image
- Data source: OpenRouter, updated daily