LLMBenchmark.ai

Enter opens the highlighted result. Esc closes.

Claude Sonnet 4.5 vs Grok 4.7

Updated October 21, 2026. 57 benchmarks have a result for both. Coding is ranked on the Vibe Coding Index; every other board is shown as published.

Claude Sonnet 4.5Anthropic
Coding
59.1
Overall
20.7
Output $/M
$15.00
28
Grok 4.7xAI
Coding
75.0
Overall
46.4
Output $/M
$6.00
29
vs boards won of 57 shared

Decision reading

Pick Grok 4.7 for coding: it scores 75.0 on the Vibe Coding Index against 59.1 for Claude Sonnet 4.5.

Pick Claude Sonnet 4.5 when the context window is larger, 1M against 500K tokens, or when what matters is LMArena Text: coding or LMArena Text: software and IT, where it leads.

Shared results
57
Claude Sonnet 4.5 only
35
Grok 4.7 only
42
Like-for-like categories
8 of 9

Shared results can support a head-to-head reading. Results only one model has describe coverage, not superiority.

Which one for your work

Each card is decided by one number both models carry. Where only one has it, the card says so and makes no call.

At a glance

Coding index
Claude Sonnet 4.5 59.1 from 2 benchmarks, Grok 4.7 75.0 from 2 benchmarks.
Widest category
Agentic work, 41.9 points apart on average over 1 shared benchmark.
Widest single gap
Vibe Code Bench (Vals AI): Claude Sonnet 4.5 22.6% against Grok 4.7 86.2%, 63.5 points apart on a 0 to 100 scale.
Output price
Claude Sonnet 4.5 $15.00 against Grok 4.7 $6.00 per million output tokens, 2.5x apart.
Context window
Claude Sonnet 4.5 takes 1M tokens, Grok 4.7 500K.

Benchmark by benchmark

First the score: boards each model leads, per category, where both have a result. Then every board, a category to a fold; bars are each result on a 0 to 100 scale, so compare the two in a row, not one row with another.

Boards won, where both have a result
CategoryClaude Sonnet 4.5BarsGrok 4.7Ties
Coding24
Intelligence02
Agentic work01
Reasoning35
Math24
Knowledge43
Web design06
General174
All shared boards2829
CodingLike-for-likeFour of these boards feed the Vibe Coding Index24
Coding benchmarks for Claude Sonnet 4.5 and Grok 4.7
BenchmarkClaude Sonnet 4.5Grok 4.7Leader
SWE-bench Verified74.8%Not measuredOnly Claude Sonnet 4.5 measured
SWE-bench Multilingual67.0%Not measuredOnly Claude Sonnet 4.5 measured
LiveBench codingNot measured84.5%Only Grok 4.7 measured
LMArena WebDev13941637Grok 4.7
AA Coding Index52.1Not measuredOnly Claude Sonnet 4.5 measured
LiveCodeBench (Vals AI)73.0%Not measuredOnly Claude Sonnet 4.5 measured
SWE-bench Verified (Vals AI)70.0%Not measuredOnly Claude Sonnet 4.5 measured
Terminal-Bench 4 (Vals AI)Not measured28.8%Only Grok 4.7 measured
Vibe Code Bench (Vals AI)22.6%86.2%Grok 4.7
Code migration (Vals AI)Not measured44.8%Only Grok 4.7 measured
ProgramBench (Vals AI)Not measured0.5%Only Grok 4.7 measured
IOI (Vals AI)Not measured57.7%Only Grok 4.7 measured
Terminal-Bench 2.1 (Vals AI)Not measured73.4%Only Grok 4.7 measured
SWE-bench Multimodal (Vals AI)Not measured42.9%Only Grok 4.7 measured
CyberBench (Vals AI)Not measured69.5%Only Grok 4.7 measured
SciCodeNot measured57.8%Only Grok 4.7 measured
Terminal-Bench46.5%Not measuredOnly Claude Sonnet 4.5 measured
FrontierCodeNot measured47.6%Only Grok 4.7 measured
FrontierSWENot measured29.5%Only Grok 4.7 measured
GSO-Bench14.7%Not measuredOnly Claude Sonnet 4.5 measured
WeirdML47.7%Not measuredOnly Claude Sonnet 4.5 measured
Cybench60.0%Not measuredOnly Claude Sonnet 4.5 measured
LMArena Text: coding14881432Claude Sonnet 4.5
LMArena Text: software and IT14731421Claude Sonnet 4.5
LMArena WebDev: React13861663Grok 4.7
LMArena WebDev: HTML13991627Grok 4.7
LMArena WebDev: from an imageNot measured1586Only Grok 4.7 measured
Neither model has a result on the other 11 boards here
IntelligenceLike-for-likePublic boards, shown as published, kept out of the index02
Intelligence benchmarks for Claude Sonnet 4.5 and Grok 4.7
BenchmarkClaude Sonnet 4.5Grok 4.7Leader
AA Intelligence Index20.746.4Grok 4.7
Epoch Capabilities Index146.7154.4Grok 4.7
Agentic workLike-for-likePublic boards, shown as published, kept out of the index01
Agentic work benchmarks for Claude Sonnet 4.5 and Grok 4.7
BenchmarkClaude Sonnet 4.5Grok 4.7Leader
AA Agentic Index15.8Not measuredOnly Claude Sonnet 4.5 measured
Design Arena: agents building web apps1060Not measuredOnly Claude Sonnet 4.5 measured
Design Arena: agents building full-stack apps1050Not measuredOnly Claude Sonnet 4.5 measured
Design Arena: agents building mobile apps1137Not measuredOnly Claude Sonnet 4.5 measured
LiveBench researchNot measured86.4%Only Grok 4.7 measured
LiveBench browserNot measured60.0%Only Grok 4.7 measured
LiveBench long agenticNot measured50.1%Only Grok 4.7 measured
SREBench (Vals AI)Not measured3.8%Only Grok 4.7 measured
Finance Agent (Vals AI)Not measured52.3%Only Grok 4.7 measured
Tax Agent Bench (Vals AI)Not measured34.2%Only Grok 4.7 measured
Legal Research Bench (Vals AI)Not measured47.1%Only Grok 4.7 measured
Harvey's Legal Agent Benchmark (Vals AI)Not measured18.3%Only Grok 4.7 measured
Excel Modeling Benchmark (Vals AI)Not measured67.0%Only Grok 4.7 measured
BioMysteryBench (Vals AI)Not measured69.3%Only Grok 4.7 measured
Terminal-Bench-Science (Vals AI)Not measured10.0%Only Grok 4.7 measured
Vals Science IndexNot measured34.8%Only Grok 4.7 measured
Robo-bench (Vals AI)Not measured0.2%Only Grok 4.7 measured
APEX-AgentsNot measured54.6%Only Grok 4.7 measured
METR time horizons67.4%Not measuredOnly Claude Sonnet 4.5 measured
Remote Labor Index2.1%Not measuredOnly Claude Sonnet 4.5 measured
GDPval42.5%Not measuredOnly Claude Sonnet 4.5 measured
DeepResearch Bench52.6%Not measuredOnly Claude Sonnet 4.5 measured
OSWorld62.9%Not measuredOnly Claude Sonnet 4.5 measured
Vending-Bench 2$3,839$10,537Grok 4.7
Neither model has a result on the other 15 boards here
ReasoningLike-for-likePublic boards, shown as published, kept out of the index35
Reasoning benchmarks for Claude Sonnet 4.5 and Grok 4.7
BenchmarkClaude Sonnet 4.5Grok 4.7Leader
GPQA Diamond81.6%Not measuredOnly Claude Sonnet 4.5 measured
LiveBench reasoningNot measured82.7%Only Grok 4.7 measured
MysteryMechanism (Vals AI)Not measured25.2%Only Grok 4.7 measured
MMMU Pro (Vals AI)79.3%Not measuredOnly Claude Sonnet 4.5 measured
Humanity's Last Exam (Artificial Analysis run)Not measured43.1%Only Grok 4.7 measured
GPQA Diamond (Epoch AI run)82.3%92.7%Grok 4.7
ARC-AGI63.7%90.2%Grok 4.7
ARC-AGI-213.6%61.4%Grok 4.7
SimpleBench54.3%Not measuredOnly Claude Sonnet 4.5 measured
Chess puzzles10.0%41.0%Grok 4.7
Mystery game puzzles17.0%29.0%Grok 4.7
EBR-bench2.4%Not measuredOnly Claude Sonnet 4.5 measured
VPCT39.8%Not measuredOnly Claude Sonnet 4.5 measured
LMArena Text: hard prompts14621415Claude Sonnet 4.5
LMArena Text: expert14831439Claude Sonnet 4.5
LMArena Text: hard prompts in English14711427Claude Sonnet 4.5
LMArena Vision: diagramsNot measured1254Only Grok 4.7 measured
LMArena Vision: homeworkNot measured1309Only Grok 4.7 measured
Neither model has a result on the other 3 boards here
MathLike-for-likePublic boards, shown as published, kept out of the index24
Math benchmarks for Claude Sonnet 4.5 and Grok 4.7
BenchmarkClaude Sonnet 4.5Grok 4.7Leader
AIME88.2%Not measuredOnly Claude Sonnet 4.5 measured
MGSM (Vals AI)94.3%Not measuredOnly Claude Sonnet 4.5 measured
OTIS Mock AIME77.8%98.1%Grok 4.7
FrontierMath, tiers 1 to 323.9%53.0%Grok 4.7
FrontierMath, tier 42.4%17.1%Grok 4.7
ProofBench19.0%26.0%Grok 4.7
MATH level 597.7%Not measuredOnly Claude Sonnet 4.5 measured
LMArena Text: math14491414Claude Sonnet 4.5
LMArena Text: mathematical work14621435Claude Sonnet 4.5
Neither model has a result on the other 4 boards here
KnowledgeLike-for-likePublic boards, shown as published, kept out of the index43
Knowledge benchmarks for Claude Sonnet 4.5 and Grok 4.7
BenchmarkClaude Sonnet 4.5Grok 4.7Leader
MMLU Pro87.4%Not measuredOnly Claude Sonnet 4.5 measured
LegalBench (Vals AI)84.1%84.4%Grok 4.7
CaseLaw (Vals AI)62.2%Not measuredOnly Claude Sonnet 4.5 measured
CorpFin (Vals AI)62.0%Not measuredOnly Claude Sonnet 4.5 measured
TaxEval (Vals AI)73.3%Not measuredOnly Claude Sonnet 4.5 measured
MortgageTax (Vals AI)64.0%Not measuredOnly Claude Sonnet 4.5 measured
MedQA (Vals AI)94.7%Not measuredOnly Claude Sonnet 4.5 measured
MedCode (Vals AI)44.1%49.5%Grok 4.7
SimpleQA Verified30.7%56.0%Grok 4.7
LMArena Text: science14481419Claude Sonnet 4.5
LMArena Text: medicine and healthcare14441395Claude Sonnet 4.5
LMArena Text: legal and government14511423Claude Sonnet 4.5
LMArena Text: business and finance14401389Claude Sonnet 4.5
Neither model has a result on the other 4 boards here
Web designLike-for-likePublic boards, shown as published, kept out of the index06
Web design benchmarks for Claude Sonnet 4.5 and Grok 4.7
BenchmarkClaude Sonnet 4.5Grok 4.7Leader
Design Arena: websites11901255Grok 4.7
Design Arena: UI components11731271Grok 4.7
Design Arena: game dev11661314Grok 4.7
Design Arena: data viz11671227Grok 4.7
Design Arena: 3D11581269Grok 4.7
Design Arena: all code categories11831271Grok 4.7
Design Arena: SVG1114Not measuredOnly Claude Sonnet 4.5 measured
Design Arena: ASCII art1204Not measuredOnly Claude Sonnet 4.5 measured
LiveBench designNot measured78.0%Only Grok 4.7 measured
GeneralLike-for-likePublic boards, shown as published, kept out of the index174
General benchmarks for Claude Sonnet 4.5 and Grok 4.7
BenchmarkClaude Sonnet 4.5Grok 4.7Leader
Vals IndexNot measured58.6%Only Grok 4.7 measured
LiveBench data analysisNot measured76.9%Only Grok 4.7 measured
Public Benefits Bench (Vals AI)Not measured65.6%Only Grok 4.7 measured
SAGE (Vals AI)36.1%40.8%Grok 4.7
MedScribe (Vals AI)84.5%89.4%Grok 4.7
Long context reasoning (AA-LCR)Not measured80.0%Only Grok 4.7 measured
DTBench83.2%96.0%Grok 4.7
LMCA38.8%49.4%Grok 4.7
Furniture assemblyNot measured20.8%Only Grok 4.7 measured
LMArena Text14381399Claude Sonnet 4.5
LMArena Text: instruction following14591406Claude Sonnet 4.5
LMArena Text: creative writing14421381Claude Sonnet 4.5
LMArena VisionNot measured1231Only Grok 4.7 measured
LMArena Text: English14501411Claude Sonnet 4.5
LMArena Text: non-English14251386Claude Sonnet 4.5
LMArena Text: Chinese14601449Claude Sonnet 4.5
LMArena Text: German14271366Claude Sonnet 4.5
LMArena Text: Japanese13901359Claude Sonnet 4.5
LMArena Text: Korean14021383Claude Sonnet 4.5
LMArena Text: French14591431Claude Sonnet 4.5
LMArena Text: Spanish14581406Claude Sonnet 4.5
LMArena Text: Russian14371399Claude Sonnet 4.5
LMArena Text: Polish14231420Claude Sonnet 4.5
LMArena Text: multi-turn14651394Claude Sonnet 4.5
LMArena Text: longer queries14751416Claude Sonnet 4.5
LMArena Text: writing and language14421394Claude Sonnet 4.5
LMArena Text: entertainment and media14281376Claude Sonnet 4.5
LMArena Vision: EnglishNot measured1229Only Grok 4.7 measured
LMArena Vision: ChineseNot measured1250Only Grok 4.7 measured
LMArena Vision: reading textNot measured1241Only Grok 4.7 measured
LMArena Vision: creative writingNot measured1217Only Grok 4.7 measured
LMArena Document1450Not measuredOnly Claude Sonnet 4.5 measured
Neither model has a result on the other 14 boards here
Image generationNot comparablePublic boards, shown as published, kept out of the index0 boards, none shared
Image generation benchmarks for Claude Sonnet 4.5 and Grok 4.7
BenchmarkClaude Sonnet 4.5Grok 4.7Leader
Neither model has a result on 5 boards here

What each workload costs

Three fixed token mixes at each model's listed price, so per-token rates become a bill.

Chat turn

1K input + 500 output tokens

Claude Sonnet 4.5$0.011Fits in one request
Grok 4.7$0.0050Fits in one request

Grok 4.7 costs less

Repository review

50K input + 3K output tokens

Claude Sonnet 4.5$0.195Fits in one request
Grok 4.7$0.118Fits in one request

Grok 4.7 costs less

Agent loop

200K input + 10K output tokens

Claude Sonnet 4.5$0.750Fits in one request
Grok 4.7$0.460Fits in one request

Grok 4.7 costs less

Listed OpenRouter rates, without cache or batch discounts. A workload that does not fit a model's context window would need splitting.

Specification differences

The leading value in a row is marked; a row with a missing value names no leader. Our two rows are marked in red.

Specifications of Claude Sonnet 4.5 and Grok 4.7
SpecificationAnthropic Claude Sonnet 4.5SpaceXAI Grok 4.7
MakerAnthropicxAI
WeightsNo public weights listedNo public weights listed
ReleasedSeptember 29, 2025September 21, 2026
Context window1M500K
Input $/Mtok$3.00$2.00
Output $/Mtok$15.00$6.00
Coding index59.175.0
Independent measurements behind it22
Cost per solved task$1.16Not computable
SourceOpenRouter listingOpenRouter listing

Questions

Is Claude Sonnet 4.5 better than Grok 4.7 for coding?

Pick Grok 4.7 for coding: it scores 75.0 on the Vibe Coding Index against 59.1 for Claude Sonnet 4.5. Pick Claude Sonnet 4.5 when the context window is larger, 1M against 500K tokens, or when what matters is LMArena Text: coding or LMArena Text: software and IT, where it leads.

Which is cheaper, Claude Sonnet 4.5 or Grok 4.7?

Claude Sonnet 4.5 costs $3.00 per million input tokens and $15.00 per million output tokens; Grok 4.7 costs $2.00 and $6.00. Cost per solved task is known for Claude Sonnet 4.5 only.

Which has the bigger context window, Claude Sonnet 4.5 or Grok 4.7?

Claude Sonnet 4.5, with 1M tokens against 500K.

How many benchmarks is the Claude Sonnet 4.5 vs Grok 4.7 comparison based on?

57 benchmarks have a result for both models as of October 21, 2026. Claude Sonnet 4.5's coding index rests on 2 independent benchmarks and Grok 4.7's on 2. Where only one model has a result, the page says so instead of naming a winner.

Compare next

Embed this comparison on your site

Free under CC BY 4.0, while the source link stays visible. Preview the frame · Terms and other embeds

<iframe src="https://llmbenchmark.ai/embed/compare/claude-sonnet-4-5-vs-grok-4-7" title="Claude Sonnet 4.5 vs Grok 4.7, LLMBenchmark.ai" width="100%" height="360" style="border:0;max-width:100%" loading="lazy"></iframe>
<p style="font:13px/1.4 sans-serif;margin:6px 0 0">Source: <a href="https://llmbenchmark.ai/compare/claude-sonnet-4-5-vs-grok-4-7">LLMBenchmark.ai, Claude Sonnet 4.5 vs Grok 4.7</a></p>