Skip to content

Claude vs Codex vs DeepSeek vs Gemini: Code, Autotests, Business Plans & Reasoning (2026)

Updated 2026-07-05

As of July 2026, no single model wins everything. Claude Opus 4.8 is the most balanced pick for daily coding and test automation; Codex (GPT-5.5) leads on FrontierMath and has the deepest GitHub-native agentic workflow; Gemini 3.1 Pro leads GPQA Diamond and ships the largest practical context window; DeepSeek V4-Pro is 5-10x cheaper than any of the other three and the only one you can self-host, but independently (NIST CAISI) trails the frontier by roughly 7 points on real software-engineering tasks. Every vendor's own benchmark numbers are higher than what independent evaluators measure — treat that gap as the headline finding, not a footnote.

Most "Claude vs GPT vs Gemini" pages on the internet just paste a vendor's own launch-blog table and call it a comparison. This one is built differently: four separate research passes (one per lab) cross-checked vendor claims against independent trackers — Artificial Analysis, NIST's CAISI, LMArena, aider's Polyglot leaderboard, and hands-on practitioner reviews — specifically for four use cases QA and dev teams actually care about: writing code, writing and running automated tests, drafting business plans and analytical documents, and working across large, long-lived codebases. We compare Anthropic's Claude (Opus 4.8), OpenAI's Codex (the agentic coding product, running on GPT-5.5), DeepSeek (V4-Pro), and Google's Gemini (3.1 Pro — the current publicly available flagship; Gemini 3.5 Pro was still in enterprise-only preview as of this snapshot). Every number below is labeled vendor-reported or independent, because that distinction changed the ranking more than any single benchmark did.

Key takeaways

  • No model wins every category: Claude Opus 4.8 is most balanced for daily coding, Codex/GPT-5.5 leads independent math/abstract-reasoning benchmarks, Gemini 3.1 Pro leads GPQA Diamond and Workspace integration, DeepSeek V4-Pro is 5-10x cheaper and the only self-hostable option.
  • Vendor-reported and independently-measured scores consistently disagree — NIST CAISI measured a 7-point gap between DeepSeek's own SWE-bench claim and its independently-tested score; Claude Fable 5's flagship benchmark was publicly disputed within 24 hours of launch.
  • DeepSeek V4-Pro has an independently-measured, quantified tendency to confidently fabricate answers rather than abstain (94-96% on AA-Omniscience) — a real risk for business-plan and analytical writing use cases specifically.
  • All four labs now ship 1M-token context windows, but long-context retrieval accuracy at the true 1M edge drops sharply for at least Gemini (84.9%→26.3%) and DeepSeek (0.82→0.59) per their own published long-context benchmarks.
  • Every score here is a July 2026 snapshot from a single research pass per model — re-check primary sources (vendor system cards, Artificial Analysis, NIST CAISI) before citing an exact percentage, since several figures in this space were found to conflict across secondary sources.

At a glance

Claude (Opus 4.8)Codex (GPT-5.5)DeepSeek (V4-Pro)Gemini (3.1 Pro)
Price (input / output per MTok)$5 / $25$5 / $30 (API)$0.44 / $0.87$2 / $12 (≤200K ctx)
Context window1M tokens1M API / 400K in Codex1M tokens1M tokens
Open weights / self-hostableNoNoYes (MIT license)No
Code — SWE-bench Verified (vendor-reported)88.6%82.6% (GPT-5.5, independent tracker)80.6%80.6%
Code — SWE-bench, independent evaluation (NIST CAISI, comparable tasks)not tested by CAISI in this pass81%74%not tested by CAISI in this pass
Code — Terminal-Bench 2.x (agentic CLI tasks)74.6% (v2.1)82.7% (v2.0, one tracker)67.9% (v2.0)76.2% (v2.1, vendor)
Code — real-world developer sentimentPraised for concise, disciplined output in agentic loops (HN)Strong on terminal/DevOps, weaker on frontend/UI (community)"Best value, not best coder" — good for volume, not hardest bugs (dev reviews)Benchmark-strong but described as over-engineered/verbose in real use (HN)
Autotests — independent hands-on review23/23 passing tests, 95% line coverage, but missed real edge cases (ontestautomation.com)Can run/iterate tests autonomously in cloud sandbox; reports of over-mocking / happy-path biasCommunity tutorials only; Flash tier reportedly lags Pro on multi-step debug loopsFirst-party IDE test generation (Android Studio); HN flags agentic harness-escape issues
Autotests — agentic tool-use benchmark proxyTerminal-Bench 2.1: 74.6%OSWorld-Verified: SOTA claimed (vendor)Terminal-Bench 2.0: 67.9%MCP Atlas: 83.6% (vendor)
Business writing — GPQA Diamond (PhD-level reasoning proxy)~91-94% (sources conflict, needs system-card check)93.6%90.1% (vendor)94.3% (independent-adjacent, DeepMind card)
Business writing — documented fabrication/hallucination riskNo specific figure found; anecdotal caution urged same as any LLMNo specific figure found in this pass94-96% hallucination rate ON questions it gets wrong (AA-Omniscience) — confidently wrong rather than abstainingNo specific figure found in this pass
Business writing — native office/workspace integrationNo native suite; strong via long-context chat/APINo native suite; ChatGPT app + APINo native suiteNative in Gmail/Docs/Sheets/Slides (Workspace)
Reasoning — ARC-AGI-2 (abstract reasoning, independent-friendly benchmark)72.1% (Opus 4.8, secondary source)85.0% (GPT-5.5, secondary source)46% (NIST CAISI, independent)77.1% (standard) / 84.6% (Deep Think mode)
Reasoning — competition math (AIME/FrontierMath)100% AIME 2025 w/ tools (Sonnet 4.5-era, dated)FrontierMath Tier 4: ~31-40% (Epoch AI, independent)OTIS-AIME-2025: 97% (NIST CAISI, independent)Reported behind GPT-5.4 on AIME; no confirmed figure
Reasoning — mechanismAdaptive thinking, effort param low→maxSelectable reasoning effort low→xhighHybrid thinking/non-thinking per requestDeep Think = extra inference-time compute, separate mode
Context — long-context retrieval at full window (MRCR-style, degradation check)Vendor claims ~91-94% multi-fact @500K; needs verificationMRCR 1M: 74.0% (jump from 36.6% prior gen, needs verificationMRCR 8-needle: 0.82 @256K → 0.59 @1M (real drop-off, vendor)MRCR: 84.9% @128K → 26.3% @1M (steep drop-off, vendor model card)
Independent composite score — Artificial Analysis Intelligence Index56 (Opus 4.8)60 (GPT-5.5, #1 overall of 361 models tracked)52 (#2 among open-weight models)not captured in this pass — check artificialanalysis.ai directly
Known risk / honest caveatNewest top-tier model (Fable 5) has disputed benchmarks and safety-routes sensitive queries to Opus 4.8MCP support status conflicting across sources as of this snapshot; verify before relying on itHosted app stores data in mainland China (governed by Chinese law); banned on gov't systems in several countriesFlagship successor (3.5 Pro) still enterprise-preview only; Gemini CLI was discontinued and replaced mid-2026

Why vendor benchmarks and independent benchmarks disagree

Every lab publishes SWE-bench Verified, GPQA Diamond, or Terminal-Bench numbers under its own best-case configuration: highest reasoning effort, full tool access, and often multiple attempts averaged together. Independent evaluators — Artificial Analysis, NIST's CAISI, Epoch AI's FrontierMath, and the community-run aider Polyglot and LMArena leaderboards — reproduce the same benchmark under one fixed harness, and the numbers are consistently lower. The gap isn't noise: NIST CAISI measured DeepSeek V4 at 74% on comparable software-engineering tasks against DeepSeek's own ~80.6% SWE-bench claim, and separately found DeepSeek's real-world capability trails the frontier by roughly eight months. Anthropic's newest Claude Fable 5 had its SWE-bench Pro claim publicly disputed by evaluators within 24 hours of launch. Treat any single vendor-reported number as a ceiling, not an expectation.

Code writing: how they actually compare

On vendor-reported SWE-bench Verified, Claude Opus 4.8 (88.6%) leads this group of four, with Codex/GPT-5.5, DeepSeek V4-Pro, and Gemini 3.1 Pro clustered near 80-83%. But the one independent, government-run evaluation found here (NIST CAISI) only tested GPT-5.5 and DeepSeek V4 head-to-head, and found a real 7-point gap (81% vs 74%) in GPT-5.5's favor on comparable tasks — a useful reminder that self-reported rankings and independently-measured rankings can diverge. Real-world developer sentiment (Hacker News, dev blogs) consistently describes Claude's agentic coding style as disciplined and concise, Codex as strong on terminal/DevOps workflows but weaker on frontend work, Gemini's raw output as powerful but frequently over-engineered, and DeepSeek as good value rather than best-in-class on the hardest bugs.

Autotests and test automation: how they actually compare

No vendor publishes a dedicated "writes good tests" benchmark — this is qualitative territory for all four models. The most useful data point found is an independent, hands-on QA-practitioner review (not vendor-affiliated): Claude Code generated a 23-test Java suite with 95% line coverage and 91% mutation coverage in minutes, but missed real edge cases (an HTTP 500 path, a boundary condition on interest calculations) and produced some redundant tests — the reviewer's conclusion was cautious optimism, not blind trust. Codex's advantage is architectural: it runs tests inside a sandboxed cloud container and can iterate autonomously before opening a PR, though community reports flag a tendency toward over-mocking and happy-path bias. Gemini ships first-party test generation inside Android Studio and Code Assist, but Hacker News threads on Gemini's agentic CLI environments specifically flag harness-escape and reliability issues relevant to unattended CI runs. DeepSeek's test-automation evidence is limited to community tutorials rather than evaluation — plausible but unverified that its cheaper Flash tier lags Pro on the multi-step debug-and-retest loop that test automation actually requires.

Business plans and analytical writing: how they actually compare

For long-form business documents, the most actionable finding isn't a benchmark score — it's a documented failure mode. DeepSeek V4-Pro scores well on GPQA Diamond (90.1%, vendor) and MMLU-Pro, but Artificial Analysis's AA-Omniscience benchmark found that when it doesn't know an answer, it guesses confidently wrong 94-96% of the time rather than admitting uncertainty — corroborated independently by a hands-on reviewer who noted it "will happily invent statistics if you let it." That's a real risk for stakes-bearing business writing. Gemini's differentiator here isn't a reasoning score at all — it's native integration into Gmail, Docs, Sheets, and Slides, letting it draft directly from existing Workspace files, which neither Claude, Codex, nor DeepSeek can do natively. Claude and Codex both have strong anecdotal reputations for long-form business writing and instruction-following, backed mainly by their large context windows rather than a dedicated business-writing benchmark, since no such standardized benchmark exists industry-wide.

Analytical reasoning approach: how they actually compare

The four labs solve reasoning differently, and it shows in where each one wins. Codex/GPT-5.5 leads the independently-run FrontierMath benchmark (Epoch AI, one of the hardest public math evals) and posts the highest ARC-AGI-2 abstract-reasoning score found in this research (85.0%). Gemini 3.1 Pro's standard mode scores 77.1% on ARC-AGI-2, but its "Deep Think" mode — which spends extra inference-time compute rather than using a bigger model — jumps to 84.6%, and separately posts the highest GPQA Diamond score found here. DeepSeek's RL-driven reasoning lineage (the same technique that produced R1) shows real, independently-verified strength on competition math (97% on OTIS-AIME-2025, per NIST CAISI) but a genuine, independently-measured weakness on novel abstract reasoning (46% ARC-AGI-2 — barely half of GPT-5.5's score). Claude's current reasoning architecture (adaptive thinking with a soft effort dial) trails GPT-5.5 on ARC-AGI-2 specifically, even though it leads Artificial Analysis's broader, agentic-weighted Intelligence Index in other configurations. The honest takeaway: "best at reasoning" depends entirely on which kind of reasoning you mean.

Context retention and project understanding: how they actually compare

All four now ship a 1M-token context window, but "1M tokens" and "reliable recall at 1M tokens" are different claims. Gemini 3.1 Pro's own model card shows retrieval accuracy on its MRCR long-context test collapsing from 84.9% at 128K tokens to 26.3% at the full 1M mark — a headline context size that significantly overstates practical reliability at the far end. DeepSeek shows the same pattern at a smaller scale (0.82 at 256K down to 0.59 at 1M) but backs it with real architectural efficiency gains (a new sparse-attention design cutting KV-cache memory to roughly a tenth of its prior generation at 1M-token scale). Codex has a genuinely confusing story here: GPT-5.5 supports 1M tokens via the API but only 400K tokens inside the Codex product itself, a gap worth checking directly before assuming your Codex session gets the full window. Claude's Sonnet 5, Opus 4.8, and Fable 5 all ship 1M tokens at flat per-token pricing with no long-context surcharge — a genuine, verifiable pricing differentiator — though the specific multi-needle benchmark numbers claiming Claude's lead over competitors traced back to vendor blog claims that couldn't be independently confirmed in this research pass.

Which model should you actually pick

For day-to-day coding and test automation, Claude Opus 4.8 is the most balanced choice across this research — strong independently-adjacent coding scores, a disciplined agentic style developers describe favorably, and a flat 1M-token context window. If your team is standardized on GitHub and wants autonomous PR-open-and-review workflows, Codex (GPT-5.5) is a credible, arguably deeper agentic-coding product, with the caveat that its Codex-product context window (400K) is smaller than its API window (1M). If cost is the binding constraint, or you need to self-host for compliance reasons, DeepSeek V4-Pro is 5-10x cheaper than the other three and the only genuinely open-weight option — accept that it independently trails the frontier by a real margin on hard software-engineering tasks and has a documented tendency to fabricate rather than abstain. If your organization already runs on Google Workspace or needs the largest practical context window for very large document sets, Gemini 3.1 Pro is the natural fit, with the caveat that its next flagship (3.5 Pro) was not yet generally available as of this snapshot. Within Claude's own lineup specifically, Sonnet 5 keeps most of Opus 4.8's coding score at roughly a third of the price for teams that don't need the absolute ceiling.

Honest caveats and risks worth knowing before you commit

Each vendor carries a real, current caveat that a purely benchmark-driven comparison would miss. Anthropic's newest top-tier model (Fable 5) had its flagship SWE-bench Pro claim publicly disputed by independent evaluators within a day of launch, and its own safety classifier automatically reroutes certain sensitive-domain requests to Opus 4.8 instead — meaning Fable 5's headline scores don't apply to every real request. OpenAI's Codex has conflicting reports across sources about current MCP (Model Context Protocol) support, which matters if your QA tooling depends on it — verify directly against current docs before building around it. DeepSeek's hosted app and API store consumer data on servers in mainland China, subject to Chinese data-access law, and it is currently restricted on government systems in several countries (Italy, Taiwan, Australia, and others) — a real consideration for regulated industries, even though the open-weight model can in principle be self-hosted outside that jurisdiction. Google discontinued Gemini CLI in mid-2026 in favor of a rewritten Antigravity CLI that reportedly launched without full feature parity — worth checking before building CI automation on top of it. None of these caveats make a model unusable, but an honest comparison should surface them rather than only comparing headline scores.

FAQ

On vendor-reported SWE-bench Verified, Claude Opus 4.8 leads this group of four (88.6%), with Codex/GPT-5.5, DeepSeek V4-Pro, and Gemini 3.1 Pro clustered near 80-83%. The one independent, government-run evaluation available (NIST CAISI) only directly compared GPT-5.5 and DeepSeek V4 and found GPT-5.5 ahead by about 7 points on comparable tasks. Real-world developer sentiment favors Claude and Codex for disciplined agentic coding style, with Gemini's output frequently described as over-engineered despite strong benchmark numbers.

Sources

Related guides