Enter opens the highlighted result. Esc closes.

GPT-5.1-Codex vs Grok 4.7

Grok 4.7 leads GPT-5.1-Codex on coding, 66.7 to 15.3 on the Vibe Coding Index, and Grok 4.7 costs 1.7x less per output token ($6.00 vs $10.00 per million). Updated October 21, 2026; 11 benchmarks have a result for both.

GPT-5.1-CodexOpenAI
Coding
15.3
Overall
No data
Output $/M
$10.00
0
Grok 4.7xAI
Coding
66.7
Overall
66.6
Output $/M
$6.00
11
vs boards won of 11 shared

GPT-5.1-Codex or Grok 4.7: which to pick

Pick Grok 4.7 for coding: it scores 66.7 on the Vibe Coding Index against 15.3 for GPT-5.1-Codex.

GPT-5.1-Codex is neither cheaper nor larger in context, and leads no benchmark both models were measured on.

Shared results
11
GPT-5.1-Codex only
15
Grok 4.7 only
88
Like-for-like categories
5 of 9

Only benchmarks that tested both models count toward a pick; a result only one model has is shown but not compared.

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
GPT-5.1-Codex 15.3 from 2 benchmarks, Grok 4.7 66.7 from 5 benchmarks.
Widest category
Coding, 52.7 points apart on average over 3 shared benchmarks.
Widest single gap
Vibe Code Bench (Vals AI): GPT-5.1-Codex 13.1% against Grok 4.7 86.2%, 73.1 points apart on a 0 to 100 scale.
Output price
GPT-5.1-Codex $10.00 against Grok 4.7 $6.00 per million output tokens, 1.7x apart.
Context window
GPT-5.1-Codex takes 400K 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
CategoryGPT-5.1-CodexBarsGrok 4.7Ties
Coding03
Intelligence01
Reasoning01
Web design05
General01
All shared boards011
CodingLike-for-likeSix of these boards feed the Vibe Coding Index03
Coding benchmarks for GPT-5.1-Codex and Grok 4.7
BenchmarkGPT-5.1-CodexGrok 4.7Leader
SWE-bench Verified66.0%Not measuredOnly GPT-5.1-Codex measured
LiveBench codingNot measured84.5%Only Grok 4.7 measured
LMArena WebDev13371637Grok 4.7
LiveCodeBench (Vals AI)85.5%Not measuredOnly GPT-5.1-Codex measured
Terminal-Bench 4 (Vals AI)Not measured28.8%Only Grok 4.7 measured
Vibe Code Bench (Vals AI)13.1%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
LiveCodeBench (Artificial Analysis run)84.9%Not measuredOnly GPT-5.1-Codex measured
SciCodeNot measured57.8%Only Grok 4.7 measured
Terminal-Bench Hard (Artificial Analysis run)34.8%Not measuredOnly GPT-5.1-Codex measured
Terminal-Bench57.8%Not measuredOnly GPT-5.1-Codex measured
FrontierCodeNot measured47.6%Only Grok 4.7 measured
FrontierSWENot measured29.5%Only Grok 4.7 measured
ALE-Bench1244.9Not measuredOnly GPT-5.1-Codex measured
LMArena Text: codingNot measured1432Only Grok 4.7 measured
LMArena Text: software and ITNot measured1421Only Grok 4.7 measured
LMArena WebDev: ReactNot measured1663Only Grok 4.7 measured
LMArena WebDev: HTML13461627Grok 4.7
LMArena WebDev: from an imageNot measured1586Only Grok 4.7 measured
Neither model has a result on the other 15 boards here
IntelligenceLike-for-likePublic boards, shown as published, kept out of the index01
Intelligence benchmarks for GPT-5.1-Codex and Grok 4.7
BenchmarkGPT-5.1-CodexGrok 4.7Leader
AA Intelligence Index23.746.4Grok 4.7
Epoch Capabilities IndexNot measured154.4Only Grok 4.7 measured
Agentic workDirectional onlyPublic boards, shown as published, kept out of the index19 boards, none shared
Agentic work benchmarks for GPT-5.1-Codex and Grok 4.7
BenchmarkGPT-5.1-CodexGrok 4.7Leader
Design Arena: agents building web apps1018Not measuredOnly GPT-5.1-Codex measured
Design Arena: agents building full-stack apps1086Not measuredOnly GPT-5.1-Codex measured
Design Arena: agents building mobile apps1191Not measuredOnly GPT-5.1-Codex 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
τ²-Bench Telecom83.0%Not measuredOnly GPT-5.1-Codex measured
APEX-AgentsNot measured54.6%Only Grok 4.7 measured
Vending-Bench 2Not measured$10,537Only Grok 4.7 measured
Neither model has a result on the other 22 boards here
ReasoningLike-for-likePublic boards, shown as published, kept out of the index01
Reasoning benchmarks for GPT-5.1-Codex and Grok 4.7
BenchmarkGPT-5.1-CodexGrok 4.7Leader
LiveBench reasoningNot measured82.7%Only Grok 4.7 measured
MysteryMechanism (Vals AI)Not measured25.2%Only Grok 4.7 measured
GPQA Diamond (Artificial Analysis run)86.0%Not measuredOnly GPT-5.1-Codex measured
Humanity's Last Exam (Artificial Analysis run)25.7%43.1%Grok 4.7
GPQA Diamond (Epoch AI run)Not measured92.7%Only Grok 4.7 measured
ARC-AGINot measured90.2%Only Grok 4.7 measured
ARC-AGI-2Not measured61.4%Only Grok 4.7 measured
Chess puzzlesNot measured41.0%Only Grok 4.7 measured
Mystery game puzzlesNot measured29.0%Only Grok 4.7 measured
LMArena Text: hard promptsNot measured1415Only Grok 4.7 measured
LMArena Text: expertNot measured1439Only Grok 4.7 measured
LMArena Text: hard prompts in EnglishNot measured1427Only Grok 4.7 measured
LMArena Vision: diagramsNot measured1254Only Grok 4.7 measured
LMArena Vision: homeworkNot measured1309Only Grok 4.7 measured
Neither model has a result on the other 8 boards here
MathDirectional onlyPublic boards, shown as published, kept out of the index8 boards, none shared
Math benchmarks for GPT-5.1-Codex and Grok 4.7
BenchmarkGPT-5.1-CodexGrok 4.7Leader
AA Math Index95.7Not measuredOnly GPT-5.1-Codex measured
AIME 2025 (Artificial Analysis run)95.7%Not measuredOnly GPT-5.1-Codex measured
OTIS Mock AIMENot measured98.1%Only Grok 4.7 measured
FrontierMath, tiers 1 to 3Not measured53.0%Only Grok 4.7 measured
FrontierMath, tier 4Not measured17.1%Only Grok 4.7 measured
ProofBenchNot measured26.0%Only Grok 4.7 measured
LMArena Text: mathNot measured1414Only Grok 4.7 measured
LMArena Text: mathematical workNot measured1435Only Grok 4.7 measured
Neither model has a result on the other 5 boards here
KnowledgeDirectional onlyPublic boards, shown as published, kept out of the index8 boards, none shared
Knowledge benchmarks for GPT-5.1-Codex and Grok 4.7
BenchmarkGPT-5.1-CodexGrok 4.7Leader
LegalBench (Vals AI)Not measured84.4%Only Grok 4.7 measured
MedCode (Vals AI)Not measured49.5%Only Grok 4.7 measured
MMLU Pro (Artificial Analysis run)86.0%Not measuredOnly GPT-5.1-Codex measured
SimpleQA VerifiedNot measured56.0%Only Grok 4.7 measured
LMArena Text: scienceNot measured1419Only Grok 4.7 measured
LMArena Text: medicine and healthcareNot measured1395Only Grok 4.7 measured
LMArena Text: legal and governmentNot measured1423Only Grok 4.7 measured
LMArena Text: business and financeNot measured1389Only Grok 4.7 measured
Neither model has a result on the other 10 boards here
Web designLike-for-likePublic boards, shown as published, kept out of the index05
Web design benchmarks for GPT-5.1-Codex and Grok 4.7
BenchmarkGPT-5.1-CodexGrok 4.7Leader
Design Arena: websites11621254Grok 4.7
Design Arena: UI components12371275Grok 4.7
Design Arena: game dev11381313Grok 4.7
Design Arena: data viz12131235Grok 4.7
Design Arena: 3DNot measured1270Only Grok 4.7 measured
Design Arena: all code categories11521271Grok 4.7
LiveBench designNot measured78.0%Only Grok 4.7 measured
Neither model has a result on the other 2 boards here
GeneralLike-for-likePublic boards, shown as published, kept out of the index01
General benchmarks for GPT-5.1-Codex and Grok 4.7
BenchmarkGPT-5.1-CodexGrok 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)Not measured40.8%Only Grok 4.7 measured
MedScribe (Vals AI)Not measured89.4%Only Grok 4.7 measured
IFBench70.0%Not measuredOnly GPT-5.1-Codex measured
Long context reasoning (AA-LCR)69.3%80.0%Grok 4.7
DTBenchNot measured96.0%Only Grok 4.7 measured
LMCANot measured49.4%Only Grok 4.7 measured
Furniture assemblyNot measured20.8%Only Grok 4.7 measured
LMArena TextNot measured1399Only Grok 4.7 measured
LMArena Text: instruction followingNot measured1406Only Grok 4.7 measured
LMArena Text: creative writingNot measured1381Only Grok 4.7 measured
LMArena VisionNot measured1231Only Grok 4.7 measured
LMArena Text: EnglishNot measured1411Only Grok 4.7 measured
LMArena Text: non-EnglishNot measured1386Only Grok 4.7 measured
LMArena Text: ChineseNot measured1449Only Grok 4.7 measured
LMArena Text: GermanNot measured1366Only Grok 4.7 measured
LMArena Text: JapaneseNot measured1359Only Grok 4.7 measured
LMArena Text: KoreanNot measured1383Only Grok 4.7 measured
LMArena Text: FrenchNot measured1431Only Grok 4.7 measured
LMArena Text: SpanishNot measured1406Only Grok 4.7 measured
LMArena Text: RussianNot measured1399Only Grok 4.7 measured
LMArena Text: PolishNot measured1420Only Grok 4.7 measured
LMArena Text: multi-turnNot measured1394Only Grok 4.7 measured
LMArena Text: longer queriesNot measured1416Only Grok 4.7 measured
LMArena Text: writing and languageNot measured1394Only Grok 4.7 measured
LMArena Text: entertainment and mediaNot measured1376Only Grok 4.7 measured
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
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 GPT-5.1-Codex and Grok 4.7
BenchmarkGPT-5.1-CodexGrok 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

GPT-5.1-Codex$0.0063Fits in one request
Grok 4.7$0.0050Fits in one request

Grok 4.7 costs less

Repository review

50K input + 3K output tokens

GPT-5.1-Codex$0.092Fits in one request
Grok 4.7$0.118Fits in one request

GPT-5.1-Codex costs less

Agent loop

200K input + 10K output tokens

GPT-5.1-Codex$0.350Fits in one request
Grok 4.7$0.460Fits in one request

GPT-5.1-Codex 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 GPT-5.1-Codex and Grok 4.7
SpecificationOpenAI GPT-5.1-CodexSpaceXAI Grok 4.7
MakerOpenAIxAI
WeightsNo public weights listedNo public weights listed
ReleasedNovember 13, 2025September 21, 2026
Context window400K500K
Input $/Mtok$1.25$2.00
Output $/Mtok$10.00$6.00
Coding index15.366.7
Independent measurements behind it25
Cost per solved task$0.892Not computable
SourceOpenRouter listingOpenRouter listing

Questions

Is GPT-5.1-Codex better than Grok 4.7 for coding?

Pick Grok 4.7 for coding: it scores 66.7 on the Vibe Coding Index against 15.3 for GPT-5.1-Codex. GPT-5.1-Codex is neither cheaper nor larger in context, and leads no benchmark both models were measured on.

Which is cheaper, GPT-5.1-Codex or Grok 4.7?

GPT-5.1-Codex costs $1.25 per million input tokens and $10.00 per million output tokens; Grok 4.7 costs $2.00 and $6.00. Cost per solved task is known for GPT-5.1-Codex only.

Which has the bigger context window, GPT-5.1-Codex or Grok 4.7?

Grok 4.7, with 500K tokens against 400K.

How many benchmarks is the GPT-5.1-Codex vs Grok 4.7 comparison based on?

11 benchmarks have a result for both models as of October 21, 2026. GPT-5.1-Codex's coding index rests on 2 independent benchmarks and Grok 4.7's on 5. 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/gpt-5-1-codex-vs-grok-4-7" title="GPT-5.1-Codex 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/gpt-5-1-codex-vs-grok-4-7">LLMBenchmark.ai, GPT-5.1-Codex vs Grok 4.7</a></p>