Skip to main content

Model comparison

Claude Sonnet 5 vs GPT-4.1

Data verified

Head-to-head evidence from 12 shared benchmark results across 4 categories. Overall scores shown here use the public BenchAlign v5 ranking lane.

65.32/100
Margin
14.2pts
← winning
OpenAI
51.11/100
1 category wins1 category wins

Public leaderboard positions: Claude Sonnet 5 #29 (Estimated); GPT-4.1 #108 (Supported). Intervals and evidence labels describe ranking uncertainty, not a guarantee for a specific workload.

Evidence parity. Claude Sonnet 5 and GPT-4.1 share 12 comparable benchmark results. 2 of 8 categories are comparable. 24 results are unique to Claude Sonnet 5; 8 to GPT-4.1.

Updated July 23, 2026
Shared results
12
Claude Sonnet 5 only
24
GPT-4.1 only
8
Comparable categories
2 / 8

Pick Claude Sonnet 5 if you want the stronger benchmark profile. GPT-4.1 only becomes the better choice if knowledge is the priority or you want the cheaper token bill.

Confidence note. This is a partial-evidence comparison with 12 shared benchmark results across 4 evidence categories; 2 of 8 categories currently have scoreable aggregates for both models. Treat the verdict as directional until coverage is more balanced.

Why this result

Claude Sonnet 5 is clearly ahead on the BenchAlign aggregate, 65.32 to 51.11. The gap is large enough that you do not need to squint at the spreadsheet to see the difference.

Claude Sonnet 5's sharpest advantage is in coding, where it averages 76.7 against 54.6. The single biggest benchmark swing on the page is SWE-bench Verified, 85.2% to 54.6%. GPT-4.1 does hit back in knowledge, so the answer changes if that is the part of the workload you care about most.

Claude Sonnet 5 is also the more expensive model on tokens at $2.00 input / $10.00 output per 1M tokens, versus $2.00 input / $8.00 output per 1M tokens for GPT-4.1. Claude Sonnet 5 is the reasoning model in the pair, while GPT-4.1 is not. That usually helps on harder chain-of-thought-heavy tests, but it can also mean more latency and more token spend in real use.

Category breakdown

Exact category averages are shown below. Not measured means BenchLM does not have enough sourced public coverage for that model and category.

Category scores and score margins for Claude Sonnet 5 and GPT-4.1
CategoryClaude Sonnet 5ΔGPT-4.1
CodingClaude Sonnet 576.7Margin 22.1GPT-4.154.6
KnowledgeClaude Sonnet 557.4Margin 8.9GPT-4.166.3
AgenticClaude Sonnet 581.9MarginNo overlapGPT-4.1Not measured
MathClaude Sonnet 5Not measuredMarginNo overlapGPT-4.14.1
MultimodalClaude Sonnet 588.3MarginNo overlapGPT-4.1Not measured
Inst. FollowingClaude Sonnet 5Not measuredMarginNo overlapGPT-4.187.4

Decisive benchmark drivers

The largest measured benchmark gaps in this matchup, with exact reported values.

More
A · Claude Sonnet 5B · GPT-4.1
  1. SWE-bench Verified

    Coding
    Source ↗
    A 85.2%B 54.6%
    Winner: Claude Sonnet 5Δ 30.6
    SWE-bench Verified: Claude Sonnet 5 scored 85.2%; GPT-4.1 scored 54.6%. Claude Sonnet 5 wins this benchmark.

Operational comparison

Runtime and commercial metrics are compared only when both models have a complete sourced value.

MetricClaude Sonnet 5GPT-4.1Comparison
Input / output priceUSD per 1M tokensClaude Sonnet 5$2 input / $10 outputGPT-4.1$2 input / $8 outputGPT-4.1 has the lower combined listed price.
Generation speedtokens per secondClaude Sonnet 5Not availableGPT-4.1108 tok/sA complete speed comparison is not available.
First-answer latencyseconds to first tokenClaude Sonnet 5Not availableGPT-4.11.02 sA complete latency comparison is not available.
Context windowmaximum listed tokensClaude Sonnet 51MGPT-4.11MListed context windows are equal.

Benchmark Deep Dive

Agentic
BenchmarkClaude Sonnet 5GPT-4.1Result
Terminal-Bench 2.0Source 80.4%Not comparable
BrowseCompSource 84.7%Not comparable
HLE w/ toolsSource 57.4%Not comparable
OSWorld-VerifiedSource 81.2%Not comparable
GDPval-AASource 1607Not comparable
AA Agentic IndexSource 46.7%Not comparable
GDPval-AASource 55.4%Not comparable
AA BriefcaseSource 1388Not comparable
AA AutomationBenchSource 39.2%Not comparable
AA EnterpriseOps-GymSource 44.7%Not comparable
AA Harvey LABSource 90.1%Not comparable
AA Tau3 BankingSource 28.2%Not comparable
aaTerminalBench21Source 80.5%Not comparable
τ²-bench resultsSource 47.1%Not comparable
Gert LabsSource 25.65%Not comparable
CodingClaude Sonnet 5 wins
BenchmarkClaude Sonnet 5GPT-4.1Result
SWE-bench VerifiedSource 85.2%54.6%Claude Sonnet 5 leads
SWE-bench ProSource 63.2%Not comparable
SWE MultilingualSource 78.3%Not comparable
SWE MultimodalSource 28.1%Not comparable
Terminal-Bench 2.0Source 80.4%Not comparable
FrontierCode 1.1 MainSource 42.7%Not comparable
cursorBench32Source 61.5%Not comparable
AA Coding IndexSource 71.5%Not comparable
AA-SciCodeSource 53.6%38.1%Claude Sonnet 5 leads
Reasoning
BenchmarkClaude Sonnet 5GPT-4.1Result
AA-LCRSource 70.7%61.0%Claude Sonnet 5 leads
CritPtSource 16.9%0.0%Claude Sonnet 5 leads
KnowledgeGPT-4.1 wins
BenchmarkClaude Sonnet 5GPT-4.1Result
HLESource 57.4%Not comparable
HLE w/o toolsSource 43.2%Not comparable
Artificial Analysis Intelligence IndexSource 53.4%19.4%Claude Sonnet 5 leads
AA-GPQA DiamondSource 91.1%66.6%Claude Sonnet 5 leads
AA-HLESource 39.6%4.6%Claude Sonnet 5 leads
AA-Omniscience IndexSource 15.3%-36.2%Claude Sonnet 5 leads
AA-Omniscience AccuracySource 38.3%24.2%Claude Sonnet 5 leads
AA-Omniscience Hallucination RateSource 37.3%79.6%Claude Sonnet 5 leads
MMLUSource 90.2%Not comparable
GPQASource 66.3%Not comparable
Math
BenchmarkClaude Sonnet 5GPT-4.1Result
FrontierMath v2 (Tiers 1-3)Source 5.517%Not comparable
FrontierMath v2 (Tier 4)Source 0.000%Not comparable
Multimodal
BenchmarkClaude Sonnet 5GPT-4.1Result
CharXivSource 88.3%Not comparable
CharXiv w/o toolsSource 77%Not comparable
AA-MMMU-ProSource 77.3%61.2%Claude Sonnet 5 leads
Design Arena WebsiteSource 13141068Claude Sonnet 5 leads
Inst. Following
BenchmarkClaude Sonnet 5GPT-4.1Result
IFEvalSource 87.4%Not comparable
AA-IFBenchSource 43.0%Not comparable
Frequently Asked Questions (3)

Which is better, Claude Sonnet 5 or GPT-4.1?

Claude Sonnet 5 is ahead on BenchLM's BenchAlign leaderboard, 65.32 to 51.11. The biggest single separator in this matchup is SWE-bench Verified, where the scores are 85.2% and 54.6%.

Which is better for knowledge tasks, Claude Sonnet 5 or GPT-4.1?

GPT-4.1 has the edge for knowledge tasks in this comparison, averaging 66.3 versus 57.4. Inside this category, AA-Omniscience Index is the benchmark that creates the most daylight between them.

Which is better for coding, Claude Sonnet 5 or GPT-4.1?

Claude Sonnet 5 has the edge for coding in this comparison, averaging 76.7 versus 54.6. Inside this category, SWE-bench Verified is the benchmark that creates the most daylight between them.

Related Comparisons

Last updated: July 23, 2026

Choose a model with this week’s evidence

Join 2,000+ readers for ranking moves, pricing changes, and the claims that still need proof.

One email each week. Unsubscribe anytime.