Claude Opus 4.7 vs GPT-5.2 Codex
Wins 6 of 8 areas
Coding · Agents · Reasoning · Facts · Images and charts · Math
Wins 2 of 8 areas
Long documents · Following instructions
Claude Opus 4.7 is the stronger all-rounder.GPT-5.2 Codex is cheaper and better at following instructions.
Scores updated · 28 tests both models report · How we compare
Where each one wins
Tests won in each of the eight areas we test. Each piece is one test, so a longer bar means more evidence; grey means the two scored within a point of each other.
- CodingWriting and fixing software51Claude Opus 4.75 of 7 tests · 1 tie
- ReasoningHard problems that need careful thinking40Claude Opus 4.74 of 4 tests
- FactsGetting facts right instead of making them up20Claude Opus 4.72 of 2 tests
- AgentsCarrying out multi-step tasks on its own10Claude Opus 4.71 of 1 test
- Images and chartsUnderstanding pictures, charts and video10Claude Opus 4.71 of 1 test
- MathCompetition and research-level math10Claude Opus 4.71 of 1 test
- Following instructionsDoing exactly what it is asked01GPT-5.2 Codex1 of 2 tests · 1 tie
- Long documentsFinding answers in very long texts01GPT-5.2 Codex1 of 1 test
Agents, images and charts, math and long documents rest on a single test each.
What it costs
Prices per million tokens, roughly 750,000 words. The bars show the cost of a million tokens read plus a million written.
GPT-5.2 Codex costs 48% less for the same work.
The biggest differences
The three tests each model wins by the widest margin. Scores are out of 100.
Where Claude Opus 4.7 pulls ahead
- Avoids making up answers it doesn't knowAA-Omniscience · Non-hallucination+31.1points ahead
- Fixes real GitHub issues in Python projectsSWE-bench Verified+14.8points ahead
- Hard command-line tasks in a real terminalTerminal-Bench Hard+14.4points ahead
Where GPT-5.2 Codex pulls ahead
- Follows unfamiliar, precisely checkable instructionsIFBench+19points ahead
- Reasons across sets of long documentsAA-LCR+3.6points ahead
- Programming problems, refreshed regularlyLiveBench · Coding+1.5points ahead
Every test, side by side
All 28 tests both models report. The winning score is in its model's colour; marks a score checked independently.
CodingClaude Opus 4.7
- LMArena · WebDevClaude Opus 4.7 by 219 rating points15581339+219 rating
- SWE-bench VerifiedClaude Opus 4.7 by 14.887.672.8+14.8
- Terminal-Bench HardClaude Opus 4.7 by 14.451.537.1+14.4
- SWE-bench ProClaude Opus 4.7 by 7.964.356.4+7.9
- LiveBench · CodingGPT-5.2 Codex by 1.582.183.6+1.5
- LiveBench · Agentic CodingClaude Opus 4.7 by 1.350.749.4+1.3
- SciCodetie54.554.6tie
ReasoningClaude Opus 4.7
- LiveBench · ReasoningClaude Opus 4.7 by 9.587.277.7+9.5
- Humanity's Last ExamClaude Opus 4.7 by 6.642.335.7+6.6
- CritPtClaude Opus 4.7 by 3.3128.7+3.3
- GPQA DiamondClaude Opus 4.7 by 1.591.489.9+1.5
FactsClaude Opus 4.7
- AA-Omniscience · Non-hallucinationClaude Opus 4.7 by 31.157.726.6+31.1
- AA-Omniscience · AccuracyClaude Opus 4.7 by 7.848.941.1+7.8
Images and chartsClaude Opus 4.7
- MMMU-ProClaude Opus 4.7 by 2.578.876.3+2.5
Following instructionsGPT-5.2 Codex
- IFBenchGPT-5.2 Codex by 1958.677.6+19
- LiveBench · Instruction Followingtie66.766.5tie
Other results9 tests, not counted
Tests outside the eight areas. They are not counted above: several are summary scores built from other tests, or the same test under another name.
- Artificial Analysis Coding IndexClaude Opus 4.7 by 30.673.643+30.6
- AA-OmniscienceClaude Opus 4.7 by 29.527.3-2.2+29.5
- AA Agentic IndexGPT-5.2 Codex by 1739.556.5+17
- AA IntelligenceClaude Opus 4.7 by 12.240.728.5+12.2
- Terminal-Bench 2.0Claude Opus 4.7 by 5.469.464+5.4
- livebench_languageClaude Opus 4.7 by 4.277.973.7+4.2
- τ²-Bench Telecom (AA run)GPT-5.2 Codex by 3.588.692.1+3.5
- LiveBenchClaude Opus 4.7 by 2.676.974.3+2.6
- livebench_data_analysistie78.378.2tie
Questions people ask
Which is better, Claude Opus 4.7 or GPT-5.2 Codex?
Claude Opus 4.7 wins six of the eight areas we test: coding, agents, reasoning, facts, images and charts and math. GPT-5.2 Codex wins long documents and following instructions, and costs 48% less.
Which is better for coding?
Claude Opus 4.7. It wins 5 of the 7 coding tests both models report; GPT-5.2 Codex wins 1, and 1 is a tie.
Which is cheaper?
Claude Opus 4.7 costs $5.00 per million input tokens and $25.00 per million output tokens; GPT-5.2 Codex costs $1.75 and $14.00. That makes GPT-5.2 Codex about 48% cheaper for the same work.
How do you compare the two?
We use the 28 benchmark tests both models have published scores on. The verdict counts the 19 tests in the eight capability areas, and a gap under one point (ten on rating-style scales) counts as a tie. The other 9 are listed but not counted, because several are summary scores or repeat a test. Each score is the one shown on the model's own page.