Very long inputs
Choose Gemini 3.1 Pro
Gemini 3.1 Pro reads up to 1.05M tokens per request, against 400k for GPT-5.1-Codex.
Choose Gemini 3.1 Pro for very long inputs, agentic coding, tool use and support agents, reasoning over long documents and the latest release; on the other points the two are level or the data is missing.
Each answer below comes straight from the published prices, specifications and independent benchmark results.
Choose Gemini 3.1 Pro
Gemini 3.1 Pro reads up to 1.05M tokens per request, against 400k for GPT-5.1-Codex.
Choose Gemini 3.1 Pro
Gemini 3.1 Pro scores 53.8% on Terminal-Bench Hard, against 34.8% for GPT-5.1-Codex.
Choose Gemini 3.1 Pro
Gemini 3.1 Pro scores 95.6% on τ²-Bench (agentic tool use), against 83% for GPT-5.1-Codex.
Choose Gemini 3.1 Pro
Gemini 3.1 Pro scores 82% on Long-context reasoning (AA-LCR), against 69.3% for GPT-5.1-Codex.
Choose Gemini 3.1 Pro
Gemini 3.1 Pro is the newer release (February 2026, against Nov 13, 2025 for GPT-5.1-Codex).
| Gemini 3.1 Pro | GPT-5.1-Codex | |
|---|---|---|
| Provider | OpenAI | |
| Category | Language models | Language models |
| Status | Preview | Deprecated |
| Headline price | $4.50 / 1M tokens | No data |
| Input | $2.00 / 1M tokens | No data |
| Output | $12.00 / 1M tokens | No data |
| Cached input | $0.20 / 1M tokens | No data |
| Context window | 1.05M | 400k |
| Max output | 66k | 128k |
| Released | February 2026 | Nov 13, 2025 |
| Knowledge cutoff | No data | September 2024 |
| Licence | Proprietary | Proprietary |
| Capabilities | Vision, Reasoning, Tool calling, Structured output, Prompt caching, Batch API | Vision, Reasoning, Tool calling, Structured output, Batch API |
| API model id | gemini-3.1-pro-preview | gpt-5.1-codex |
Leader in bold.
| Benchmark | Gemini 3.1 Pro | GPT-5.1-Codex |
|---|---|---|
| Terminal-Bench Hard | 53.8% | 34.8% |
| GPQA Diamond | 94.1% | 86% |
| Humanity's Last Exam | 47% | 25.7% |
| IFBench (instruction following) | 77.1% | 70% |
| τ²-Bench (agentic tool use) | 95.6% | 83% |
| MMMU-Pro (visual reasoning) | 82.4% | 72.5% |
| Long-context reasoning (AA-LCR) | 82% | 69.3% |
| Intelligence Index | 29.7 | No data |
| SciCode | 58.7% | No data |
Independent evaluations by Artificial Analysis, run the same way for every model, at the reasoning setting shown. Percentages unless marked as an index.
Choose Gemini 3.1 Pro for very long inputs, agentic coding, tool use and support agents, reasoning over long documents and the latest release; on the other points the two are level or the data is missing.
A price comparison is not possible: one of them has no comparable published price.
Gemini 3.1 Pro reads more per request: 1.05M tokens against 400k.
Gemini 3.1 Pro is made by Google and GPT-5.1-Codex by OpenAI. A price comparison is not possible: one of them has no comparable published price. Gemini 3.1 Pro reads more per request: 1.05M tokens against 400k. Gemini 3.1 Pro is the newer model (February 2026, against Nov 13, 2025). Only Gemini 3.1 Pro offers prompt caching.
Gemini 3.1 Pro scores 53.8% on Terminal-Bench Hard, against 34.8% for GPT-5.1-Codex.
Gemini 3.1 Pro was released on February 2026 and GPT-5.1-Codex on Nov 13, 2025.