Enter opens the highlighted result. Esc closes.

Gemma 4 31B vs GLM 5.3 Flash

GLM 5.3 Flash leads Gemma 4 31B on coding, 54.0 to 22.0 on the Vibe Coding Index, and Gemma 4 31B costs 1.4x less per output token ($0.35 vs $0.50 per million). Updated December 6, 2026; 62 benchmarks have a result for both.

Gemma 4 31BGoogle
Coding
22.0
Overall
35.6
Output $/M
$0.35
2
GLM 5.3 FlashZ.ai
Coding
54.0
Overall
60.3
Output $/M
$0.50
60
vs boards won of 62 shared

Gemma 4 31B or GLM 5.3 Flash: which to pick

Pick GLM 5.3 Flash for coding: it scores 54.0 on the Vibe Coding Index against 22.0 for Gemma 4 31B.

Pick Gemma 4 31B for output tokens 1.4x cheaper ($0.35 vs $0.50 per million) and work measured by ALE-Bench or LMArena Vision: creative writing, where it leads.

Shared results
62
Gemma 4 31B only
15
GLM 5.3 Flash only
53
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
Gemma 4 31B 22.0 from 2 benchmarks, GLM 5.3 Flash 54.0 from 6 benchmarks.
Widest category
Agentic work, 35.9 points apart on average over 3 shared benchmarks.
Widest single gap
GDPval-AA: Gemma 4 31B 630 against GLM 5.3 Flash 1651, 70.9 points apart on a 0 to 100 scale.
Output price
Gemma 4 31B $0.35 against GLM 5.3 Flash $0.50 per million output tokens, 1.4x apart.
Context window
Gemma 4 31B takes 262K tokens, GLM 5.3 Flash 1.05M.

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
CategoryGemma 4 31BBarsGLM 5.3 FlashTies
Coding110
Intelligence02
Agentic work03
Reasoning011
Math03
Knowledge05
Web design01
General125
All shared boards260
CodingLike-for-likeSix of these boards feed the Vibe Coding Index110
Coding benchmarks for Gemma 4 31B and GLM 5.3 Flash
BenchmarkGemma 4 31BGLM 5.3 FlashLeader
LiveBench coding20.3%70.9%GLM 5.3 Flash
LMArena WebDev13711613GLM 5.3 Flash
LiveCodeBench (Vals AI)Not measured80.5%Only GLM 5.3 Flash measured
SWE-bench Verified (Vals AI)Not measured92.0%Only GLM 5.3 Flash measured
Terminal-Bench 4 (Vals AI)Not measured37.4%Only GLM 5.3 Flash measured
Vibe Code Bench (Vals AI)Not measured19.4%Only GLM 5.3 Flash measured
Code migration (Vals AI)Not measured20.5%Only GLM 5.3 Flash measured
ProgramBench (Vals AI)Not measured0.0%Only GLM 5.3 Flash measured
IOI (Vals AI)Not measured52.5%Only GLM 5.3 Flash measured
Terminal-Bench 2.1 (Vals AI)Not measured62.9%Only GLM 5.3 Flash measured
Vibe Code Bench 1-100 (Vals AI)Not measured16.0%Only GLM 5.3 Flash measured
SkillsBench (Vals AI)Not measured40.2%Only GLM 5.3 Flash measured
CyberBench (Vals AI)Not measured67.9%Only GLM 5.3 Flash measured
SciCode45.5%51.6%GLM 5.3 Flash
Terminal-Bench Hard (Artificial Analysis run)36.4%Not measuredOnly Gemma 4 31B measured
Terminal-Bench 4.0 (Artificial Analysis run)0.0%32.8%GLM 5.3 Flash
FrontierCode 2.00.0%17.2%GLM 5.3 Flash
FrontierCodeNot measured31.8%Only GLM 5.3 Flash measured
FrontierSWENot measured18.1%Only GLM 5.3 Flash measured
WeirdML52.3%Not measuredOnly Gemma 4 31B measured
ALE-Bench925.5303.6Gemma 4 31B
LMArena Text: coding14591509GLM 5.3 Flash
LMArena Text: software and IT14631501GLM 5.3 Flash
LMArena WebDev: React13631631GLM 5.3 Flash
LMArena WebDev: HTML13801582GLM 5.3 Flash
LMArena WebDev: from an imageNot measured1584Only GLM 5.3 Flash measured
SciCode8.9%Not measuredOnly Gemma 4 31B measured
GameBench 234.960.4GLM 5.3 Flash
Terminal-Bench 4.0Not measured36.7%Only GLM 5.3 Flash measured
Neither model has a result on the other 23 boards here
IntelligenceLike-for-likePublic boards, shown as published, kept out of the index02
Intelligence benchmarks for Gemma 4 31B and GLM 5.3 Flash
BenchmarkGemma 4 31BGLM 5.3 FlashLeader
AA Intelligence Index4.028.0GLM 5.3 Flash
Epoch Capabilities Index144.1153.6GLM 5.3 Flash
Agentic workLike-for-likePublic boards, shown as published, kept out of the index03
Agentic work benchmarks for Gemma 4 31B and GLM 5.3 Flash
BenchmarkGemma 4 31BGLM 5.3 FlashLeader
LiveBench research38.1%73.9%GLM 5.3 Flash
LiveBench browser0.0%59.8%GLM 5.3 Flash
LiveBench long agentic8.5%20.7%GLM 5.3 Flash
SREBench (Vals AI)Not measured0.8%Only GLM 5.3 Flash measured
Finance Agent (Vals AI)Not measured57.9%Only GLM 5.3 Flash measured
Tax Agent Bench (Vals AI)Not measured31.6%Only GLM 5.3 Flash measured
Legal Research Bench (Vals AI)Not measured45.2%Only GLM 5.3 Flash measured
Harvey's Legal Agent Benchmark (Vals AI)Not measured10.4%Only GLM 5.3 Flash measured
Excel Modeling Benchmark (Vals AI)Not measured55.9%Only GLM 5.3 Flash measured
Terminal-Bench-Science (Vals AI)Not measured2.9%Only GLM 5.3 Flash measured
τ²-Bench Telecom65.5%Not measuredOnly Gemma 4 31B measured
APEX-AgentsNot measured52.8%Only GLM 5.3 Flash measured
PostTrainBenchNot measured36.8%Only GLM 5.3 Flash measured
Toolathlon-VerifiedNot measured78.4%Only GLM 5.3 Flash measured
Neither model has a result on the other 30 boards here
ReasoningLike-for-likePublic boards, shown as published, kept out of the index011
Reasoning benchmarks for Gemma 4 31B and GLM 5.3 Flash
BenchmarkGemma 4 31BGLM 5.3 FlashLeader
GPQA DiamondNot measured86.4%Only GLM 5.3 Flash measured
LiveBench reasoning68.3%77.6%GLM 5.3 Flash
MMMU Pro (Vals AI)Not measured86.0%Only GLM 5.3 Flash measured
GPQA Diamond (Artificial Analysis run)85.7%91.2%GLM 5.3 Flash
Humanity's Last Exam (Artificial Analysis run)23.6%39.9%GLM 5.3 Flash
HLE-Diamond (Artificial Analysis run)7.2%18.2%GLM 5.3 Flash
CritPt v2, hard subset (Artificial Analysis run)4.0%24.5%GLM 5.3 Flash
GPQA Diamond (Epoch AI run)75.8%90.2%GLM 5.3 Flash
ARC-AGINot measured91.0%Only GLM 5.3 Flash measured
ARC-AGI-2Not measured65.8%Only GLM 5.3 Flash measured
Chess puzzlesNot measured21.0%Only GLM 5.3 Flash measured
Mystery game puzzlesNot measured8.0%Only GLM 5.3 Flash measured
LMArena Text: hard prompts14481491GLM 5.3 Flash
LMArena Text: expert14651514GLM 5.3 Flash
LMArena Text: hard prompts in English14561491GLM 5.3 Flash
LMArena Vision: diagrams12871320GLM 5.3 Flash
LMArena Vision: homework13101325GLM 5.3 Flash
Kagi LLM Benchmark63.5%Not measuredOnly Gemma 4 31B measured
Humanity's Last Exam (Scale run)Not measured16.8%Only GLM 5.3 Flash measured
Neither model has a result on the other 7 boards here
MathLike-for-likePublic boards, shown as published, kept out of the index03
Math benchmarks for Gemma 4 31B and GLM 5.3 Flash
BenchmarkGemma 4 31BGLM 5.3 FlashLeader
OTIS Mock AIME73.3%93.9%GLM 5.3 Flash
FrontierMath, tiers 1 to 3Not measured55.8%Only GLM 5.3 Flash measured
FrontierMath, tier 4Not measured17.1%Only GLM 5.3 Flash measured
ProofBenchNot measured21.0%Only GLM 5.3 Flash measured
LMArena Text: math14631506GLM 5.3 Flash
LMArena Text: mathematical work14641496GLM 5.3 Flash
Neither model has a result on the other 8 boards here
KnowledgeLike-for-likePublic boards, shown as published, kept out of the index05
Knowledge benchmarks for Gemma 4 31B and GLM 5.3 Flash
BenchmarkGemma 4 31BGLM 5.3 FlashLeader
MMLU ProNot measured86.1%Only GLM 5.3 Flash measured
LegalBench (Vals AI)Not measured83.9%Only GLM 5.3 Flash measured
CaseLaw (Vals AI)52.6%Not measuredOnly Gemma 4 31B measured
TaxEval (Vals AI)Not measured75.6%Only GLM 5.3 Flash measured
MortgageTax (Vals AI)61.4%Not measuredOnly Gemma 4 31B measured
AA-Omniscience-48.50.7GLM 5.3 Flash
SimpleQA Verified10.4%Not measuredOnly Gemma 4 31B measured
LMArena Text: science14561488GLM 5.3 Flash
LMArena Text: medicine and healthcare14501476GLM 5.3 Flash
LMArena Text: legal and government14381479GLM 5.3 Flash
LMArena Text: business and finance14311461GLM 5.3 Flash
FACTS Benchmark Suite50.1%Not measuredOnly Gemma 4 31B measured
PRBench FinanceNot measured51.7%Only GLM 5.3 Flash measured
PRBench LegalNot measured51.7%Only GLM 5.3 Flash measured
Neither model has a result on the other 7 boards here
Web designLike-for-likePublic boards, shown as published, kept out of the index01
Web design benchmarks for Gemma 4 31B and GLM 5.3 Flash
BenchmarkGemma 4 31BGLM 5.3 FlashLeader
Design Arena: websitesNot measured1305Only GLM 5.3 Flash measured
Design Arena: UI componentsNot measured1284Only GLM 5.3 Flash measured
Design Arena: game devNot measured1250Only GLM 5.3 Flash measured
Design Arena: data vizNot measured1249Only GLM 5.3 Flash measured
Design Arena: 3DNot measured1276Only GLM 5.3 Flash measured
Design Arena: all code categoriesNot measured1321Only GLM 5.3 Flash measured
Design Arena: SVGNot measured1319Only GLM 5.3 Flash measured
Design Arena: ASCII artNot measured1256Only GLM 5.3 Flash measured
LiveBench design56.5%73.7%GLM 5.3 Flash
GeneralLike-for-likePublic boards, shown as published, kept out of the index125
General benchmarks for Gemma 4 31B and GLM 5.3 Flash
BenchmarkGemma 4 31BGLM 5.3 FlashLeader
Vals IndexNot measured49.5%Only GLM 5.3 Flash measured
LiveBench data analysis53.3%76.4%GLM 5.3 Flash
SAGE (Vals AI)82.8%89.3%GLM 5.3 Flash
MedScribe (Vals AI)Not measured88.9%Only GLM 5.3 Flash measured
IFBench75.6%Not measuredOnly Gemma 4 31B measured
Long context reasoning (AA-LCR)69.7%80.0%GLM 5.3 Flash
GDPval-AA6301651GLM 5.3 Flash
DTBench82.7%Not measuredOnly Gemma 4 31B measured
LMCA39.3%Not measuredOnly Gemma 4 31B measured
Surface Evolver Bench30.6%52.5%GLM 5.3 Flash
LMArena Text14431472GLM 5.3 Flash
LMArena Text: instruction following14341480GLM 5.3 Flash
LMArena Text: creative writing14151443GLM 5.3 Flash
LMArena Vision12791296GLM 5.3 Flash
LMArena Text: English14511477GLM 5.3 Flash
LMArena Text: non-English14311461GLM 5.3 Flash
LMArena Text: Chinese14761528GLM 5.3 Flash
LMArena Text: GermanNot measured1457Only GLM 5.3 Flash measured
LMArena Text: JapaneseNot measured1449Only GLM 5.3 Flash measured
LMArena Text: KoreanNot measured1427Only GLM 5.3 Flash measured
LMArena Text: French14351488GLM 5.3 Flash
LMArena Text: Spanish14441478GLM 5.3 Flash
LMArena Text: Russian14611468GLM 5.3 Flash
LMArena Text: Polish14311452GLM 5.3 Flash
LMArena Text: multi-turn14521473GLM 5.3 Flash
LMArena Text: longer queries14451483GLM 5.3 Flash
LMArena Text: writing and language14311458GLM 5.3 Flash
LMArena Text: entertainment and media14051442GLM 5.3 Flash
LMArena Vision: English12731300GLM 5.3 Flash
LMArena Vision: Chinese13281355GLM 5.3 Flash
LMArena Vision: reading text12851306GLM 5.3 Flash
LMArena Vision: humor12791288GLM 5.3 Flash
LMArena Vision: captioning1209Not measuredOnly Gemma 4 31B measured
LMArena Vision: recognizing things12281275GLM 5.3 Flash
LMArena Vision: creative writing12871273Gemma 4 31B
LMArena Document1435Not measuredOnly Gemma 4 31B measured
EQ-Bench 41110Not measuredOnly Gemma 4 31B measured
Neither model has a result on the other 12 boards here
Image generationNot comparablePublic boards, shown as published, kept out of the index0 boards, none shared
Image generation benchmarks for Gemma 4 31B and GLM 5.3 Flash
BenchmarkGemma 4 31BGLM 5.3 FlashLeader
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

Gemma 4 31B$0.0003Fits in one request
GLM 5.3 Flash$0.0004Fits in one request

Gemma 4 31B costs less

Repository review

50K input + 3K output tokens

Gemma 4 31B$0.0079Fits in one request
GLM 5.3 Flash$0.0090Fits in one request

Gemma 4 31B costs less

Agent loop

200K input + 10K output tokens

Gemma 4 31B$0.031Fits in one request
GLM 5.3 Flash$0.035Fits in one request

Gemma 4 31B 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 Gemma 4 31B and GLM 5.3 Flash
SpecificationGoogle Gemma 4 31BZ.ai GLM 5.3 Flash
MakerGoogleZ.ai
WeightsOpen weightsOpen weights
ReleasedApril 2, 2026August 26, 2026
Context window262K1.05M
Input $/Mtok$0.1375$0.15
Output $/Mtok$0.35$0.50
Coding index22.054.0
Independent measurements behind it26
Cost per solved taskNot computable$0.02
SourceOpenRouter listingOpenRouter listing

Questions

Is Gemma 4 31B better than GLM 5.3 Flash for coding?

Pick GLM 5.3 Flash for coding: it scores 54.0 on the Vibe Coding Index against 22.0 for Gemma 4 31B. Pick Gemma 4 31B for output tokens 1.4x cheaper ($0.35 vs $0.50 per million) and work measured by ALE-Bench or LMArena Vision: creative writing, where it leads.

Which is cheaper, Gemma 4 31B or GLM 5.3 Flash?

Gemma 4 31B costs $0.1375 per million input tokens and $0.35 per million output tokens; GLM 5.3 Flash costs $0.15 and $0.50. Cost per solved task is known for GLM 5.3 Flash only.

Which has the bigger context window, Gemma 4 31B or GLM 5.3 Flash?

GLM 5.3 Flash, with 1.05M tokens against 262K.

How many benchmarks is the Gemma 4 31B vs GLM 5.3 Flash comparison based on?

62 benchmarks have a result for both models as of December 6, 2026. Gemma 4 31B's coding index rests on 2 independent benchmarks and GLM 5.3 Flash's on 6. 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/gemma-4-31b-it-vs-glm-5-3-flash" title="Gemma 4 31B vs GLM 5.3 Flash, 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/gemma-4-31b-it-vs-glm-5-3-flash">LLMBenchmark.ai, Gemma 4 31B vs GLM 5.3 Flash</a></p>