Enter opens the highlighted result. Esc closes.

GLM 5 vs Grok 4.7

Grok 4.7 leads GLM 5 on coding, 66.7 to 41.7 on the Vibe Coding Index, and GLM 5 costs 1.9x less per output token ($3.20 vs $6.00 per million). Updated October 21, 2026; 48 benchmarks have a result for both.

GLM 5Z.ai
Coding
41.7
Overall
54.3
Output $/M
$3.20
28
Grok 4.7xAI
Coding
66.7
Overall
66.6
Output $/M
$6.00
20
vs boards won of 48 shared

GLM 5 or Grok 4.7: which to pick

Pick Grok 4.7 for coding: it scores 66.7 on the Vibe Coding Index against 41.7 for GLM 5.

Pick GLM 5 for output tokens 1.9x cheaper ($3.20 vs $6.00 per million) and work measured by LMArena Text: coding or LMArena Text: software and IT, where it leads.

Shared results
48
GLM 5 only
28
Grok 4.7 only
51
Like-for-like categories
8 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
GLM 5 41.7 from 3 benchmarks, Grok 4.7 66.7 from 5 benchmarks.
Widest category
Agentic work, 38.2 points apart on average over 1 shared benchmark.
Widest single gap
Vibe Code Bench (Vals AI): GLM 5 23.4% against Grok 4.7 86.2%, 62.8 points apart on a 0 to 100 scale.
Output price
GLM 5 $3.20 against Grok 4.7 $6.00 per million output tokens, 1.9x apart.
Context window
GLM 5 takes 205K 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
CategoryGLM 5BarsGrok 4.7Ties
Coding24
Intelligence02
Agentic work01
Reasoning34
Math21
Knowledge41
Web design06
General171
All shared boards2820
CodingLike-for-likeSix of these boards feed the Vibe Coding Index24
Coding benchmarks for GLM 5 and Grok 4.7
BenchmarkGLM 5Grok 4.7Leader
SWE-bench Verified72.8%Not measuredOnly GLM 5 measured
SWE-bench Multilingual69.7%Not measuredOnly GLM 5 measured
LiveBench codingNot measured84.5%Only Grok 4.7 measured
LMArena WebDev14351637Grok 4.7
LiveCodeBench (Vals AI)81.9%Not measuredOnly GLM 5 measured
SWE-bench Verified (Vals AI)71.4%Not measuredOnly GLM 5 measured
Terminal-Bench 4 (Vals AI)Not measured28.8%Only Grok 4.7 measured
Vibe Code Bench (Vals AI)23.4%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-Bench Hard (Artificial Analysis run)43.2%Not measuredOnly GLM 5 measured
Terminal-Bench52.4%Not measuredOnly GLM 5 measured
FrontierCodeNot measured47.6%Only Grok 4.7 measured
FrontierSWENot measured29.5%Only Grok 4.7 measured
WeirdML48.2%Not measuredOnly GLM 5 measured
ALE-Bench765.6Not measuredOnly GLM 5 measured
LMArena Text: coding14611432GLM 5
LMArena Text: software and IT14601421GLM 5
LMArena WebDev: React14241663Grok 4.7
LMArena WebDev: HTML14501627Grok 4.7
LMArena WebDev: from an imageNot measured1586Only Grok 4.7 measured
Neither model has a result on the other 13 boards here
IntelligenceLike-for-likePublic boards, shown as published, kept out of the index02
Intelligence benchmarks for GLM 5 and Grok 4.7
BenchmarkGLM 5Grok 4.7Leader
AA Intelligence Index27.946.4Grok 4.7
Epoch Capabilities Index145.8154.4Grok 4.7
Agentic workLike-for-likePublic boards, shown as published, kept out of the index01
Agentic work benchmarks for GLM 5 and Grok 4.7
BenchmarkGLM 5Grok 4.7Leader
Design Arena: agents building full-stack apps1123Not measuredOnly GLM 5 measured
Design Arena: agents building mobile apps1136Not measuredOnly GLM 5 measured
Design Arena: agents building Android apps1146Not measuredOnly GLM 5 measured
Design Arena: agents building Godot games1144Not measuredOnly GLM 5 measured
Design Arena: HTML slides1148Not measuredOnly GLM 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
τ²-Bench Telecom98.2%Not measuredOnly GLM 5 measured
APEX-AgentsNot measured54.6%Only Grok 4.7 measured
Vending-Bench 2$4,432$10,537Grok 4.7
Neither model has a result on the other 20 boards here
ReasoningLike-for-likePublic boards, shown as published, kept out of the index34
Reasoning benchmarks for GLM 5 and Grok 4.7
BenchmarkGLM 5Grok 4.7Leader
GPQA Diamond83.3%Not measuredOnly GLM 5 measured
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)82.0%Not measuredOnly GLM 5 measured
Humanity's Last Exam (Artificial Analysis run)29.3%43.1%Grok 4.7
GPQA Diamond (Epoch AI run)87.8%92.7%Grok 4.7
ARC-AGI44.7%90.2%Grok 4.7
ARC-AGI-24.9%61.4%Grok 4.7
SimpleBench53.2%Not measuredOnly GLM 5 measured
Chess puzzlesNot measured41.0%Only Grok 4.7 measured
Mystery game puzzlesNot measured29.0%Only Grok 4.7 measured
LMArena Text: hard prompts14521415GLM 5
LMArena Text: expert14541439GLM 5
LMArena Text: hard prompts in English14601427GLM 5
LMArena Vision: diagramsNot measured1254Only Grok 4.7 measured
LMArena Vision: homeworkNot measured1309Only Grok 4.7 measured
Kagi LLM Benchmark75.0%Not measuredOnly GLM 5 measured
Neither model has a result on the other 5 boards here
MathLike-for-likePublic boards, shown as published, kept out of the index21
Math benchmarks for GLM 5 and Grok 4.7
BenchmarkGLM 5Grok 4.7Leader
AIME91.7%Not measuredOnly GLM 5 measured
OTIS Mock AIME80.0%98.1%Grok 4.7
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: math14401414GLM 5
LMArena Text: mathematical work14511435GLM 5
Neither model has a result on the other 6 boards here
KnowledgeLike-for-likePublic boards, shown as published, kept out of the index41
Knowledge benchmarks for GLM 5 and Grok 4.7
BenchmarkGLM 5Grok 4.7Leader
MMLU Pro86.0%Not measuredOnly GLM 5 measured
LegalBench (Vals AI)84.1%84.4%Grok 4.7
CaseLaw (Vals AI)52.5%Not measuredOnly GLM 5 measured
CorpFin (Vals AI)62.9%Not measuredOnly GLM 5 measured
TaxEval (Vals AI)70.0%Not measuredOnly GLM 5 measured
MedQA (Vals AI)94.3%Not measuredOnly GLM 5 measured
MedCode (Vals AI)Not measured49.5%Only Grok 4.7 measured
SimpleQA VerifiedNot measured56.0%Only Grok 4.7 measured
LMArena Text: science14601419GLM 5
LMArena Text: medicine and healthcare14551395GLM 5
LMArena Text: legal and government14531423GLM 5
LMArena Text: business and finance14301389GLM 5
Neither model has a result on the other 6 boards here
Web designLike-for-likePublic boards, shown as published, kept out of the index06
Web design benchmarks for GLM 5 and Grok 4.7
BenchmarkGLM 5Grok 4.7Leader
Design Arena: websites12471254Grok 4.7
Design Arena: UI components12301275Grok 4.7
Design Arena: game dev12341313Grok 4.7
Design Arena: data viz12281235Grok 4.7
Design Arena: 3D12291270Grok 4.7
Design Arena: all code categories12461271Grok 4.7
Design Arena: SVG1168Not measuredOnly GLM 5 measured
Design Arena: ASCII art1147Not measuredOnly GLM 5 measured
LiveBench designNot measured78.0%Only Grok 4.7 measured
GeneralLike-for-likePublic boards, shown as published, kept out of the index171
General benchmarks for GLM 5 and Grok 4.7
BenchmarkGLM 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)Not measured40.8%Only Grok 4.7 measured
MedScribe (Vals AI)Not measured89.4%Only Grok 4.7 measured
IFBench72.3%Not measuredOnly GLM 5 measured
Long context reasoning (AA-LCR)75.7%80.0%Grok 4.7
DTBenchNot measured96.0%Only Grok 4.7 measured
LMCANot measured49.4%Only Grok 4.7 measured
CL-bench18.7%Not measuredOnly GLM 5 measured
Furniture assemblyNot measured20.8%Only Grok 4.7 measured
LMArena Text14461399GLM 5
LMArena Text: instruction following14281406GLM 5
LMArena Text: creative writing14381381GLM 5
LMArena VisionNot measured1231Only Grok 4.7 measured
LMArena Text: English14581411GLM 5
LMArena Text: non-English14301386GLM 5
LMArena Text: Chinese15111449GLM 5
LMArena Text: German14471366GLM 5
LMArena Text: Japanese14161359GLM 5
LMArena Text: Korean14231383GLM 5
LMArena Text: French14561431GLM 5
LMArena Text: Spanish14541406GLM 5
LMArena Text: Russian14361399GLM 5
LMArena Text: Polish14341420GLM 5
LMArena Text: multi-turn14561394GLM 5
LMArena Text: longer queries14461416GLM 5
LMArena Text: writing and language14371394GLM 5
LMArena Text: entertainment and media14261376GLM 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
Neither model has a result on the other 13 boards here
Image generationNot comparablePublic boards, shown as published, kept out of the index0 boards, none shared
Image generation benchmarks for GLM 5 and Grok 4.7
BenchmarkGLM 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

GLM 5$0.0026Fits in one request
Grok 4.7$0.0050Fits in one request

GLM 5 costs less

Repository review

50K input + 3K output tokens

GLM 5$0.060Fits in one request
Grok 4.7$0.118Fits in one request

GLM 5 costs less

Agent loop

200K input + 10K output tokens

GLM 5$0.232Exceeds the context window
Grok 4.7$0.460Fits in one request

GLM 5 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 GLM 5 and Grok 4.7
SpecificationZ.ai GLM 5SpaceXAI Grok 4.7
MakerZ.aixAI
WeightsOpen weightsNo public weights listed
ReleasedFebruary 11, 2026September 21, 2026
Context window205K500K
Input $/Mtok$1.00$2.00
Output $/Mtok$3.20$6.00
Coding index41.766.7
Independent measurements behind it35
Cost per solved task$0.63Not computable
SourceOpenRouter listingOpenRouter listing

Questions

Is GLM 5 better than Grok 4.7 for coding?

Pick Grok 4.7 for coding: it scores 66.7 on the Vibe Coding Index against 41.7 for GLM 5. Pick GLM 5 for output tokens 1.9x cheaper ($3.20 vs $6.00 per million) and work measured by LMArena Text: coding or LMArena Text: software and IT, where it leads.

Which is cheaper, GLM 5 or Grok 4.7?

GLM 5 costs $1.00 per million input tokens and $3.20 per million output tokens; Grok 4.7 costs $2.00 and $6.00. Cost per solved task is known for GLM 5 only.

Which has the bigger context window, GLM 5 or Grok 4.7?

Grok 4.7, with 500K tokens against 205K.

How many benchmarks is the GLM 5 vs Grok 4.7 comparison based on?

48 benchmarks have a result for both models as of October 21, 2026. GLM 5's coding index rests on 3 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/glm-5-vs-grok-4-7" title="GLM 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/glm-5-vs-grok-4-7">LLMBenchmark.ai, GLM 5 vs Grok 4.7</a></p>