Gemini 3.1 Pro Preview vs GLM 4.7
GLM 4.7 leads Gemini 3.1 Pro Preview on coding, 55.1 to 32.3 on the Vibe Coding Index, and GLM 4.7 costs 5.5x less per output token ($2.20 vs $12.00 per million). Updated October 22, 2026; 74 benchmarks have a result for both.
Gemini 3.1 Pro Preview or GLM 4.7: which to pick
Pick GLM 4.7 for coding: it scores 55.1 on the Vibe Coding Index against 32.3 for Gemini 3.1 Pro Preview, though on 2 benchmarks against 4.
Pick Gemini 3.1 Pro Preview for a larger context window (1.05M against 205K tokens) and work measured by LMArena WebDev or AA Coding Index, where it leads.
- Shared results
- 74
- Gemini 3.1 Pro Preview only
- 59
- GLM 4.7 only
- 7
- 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.
Coding
Vibe Coding Index, six public coding benchmarks
GLM 4.7
GLM 4.7 scores 55.1 against 32.3.
4 and 2 benchmarks behind the scores
Intelligence
AA Intelligence Index
Gemini 3.1 Pro Preview
Gemini 3.1 Pro Preview leads, 29.7 against 22.2.
Same board, both measured
Agentic work
AA Agentic Index
No call
Only Gemini 3.1 Pro Preview has a AA Agentic Index result, 8.2.
Directional only
Reasoning
GPQA Diamond
Gemini 3.1 Pro Preview
Gemini 3.1 Pro Preview leads, 95.5% against 80.0%.
Same board, both measured
Math
AIME
Gemini 3.1 Pro Preview
Gemini 3.1 Pro Preview leads, 98.1% against 93.3%.
Same board, both measured
Knowledge
MMLU Pro
Gemini 3.1 Pro Preview
Gemini 3.1 Pro Preview leads, 91.0% against 82.7%.
Same board, both measured
Web design
Design Arena: websites
Gemini 3.1 Pro Preview
Gemini 3.1 Pro Preview leads, 1233 against 1225.
Same board, both measured
Long documents
Listed context window
Gemini 3.1 Pro Preview
Gemini 3.1 Pro Preview takes 1.05M tokens against 205K.
Listed by OpenRouter
Everyday cost
1K input + 500 output tokens
GLM 4.7
Gemini 3.1 Pro Preview $0.0080, GLM 4.7 $0.0017 per turn.
List prices
Cost per solved task
One SWE-bench Verified task, solved
GLM 4.7
Gemini 3.1 Pro Preview $0.99, GLM 4.7 $0.29.
Published attempt cost and pass rate
At a glance
- Coding index
- Gemini 3.1 Pro Preview 32.3 from 4 benchmarks, GLM 4.7 55.1 from 2 benchmarks.
- Widest category
- Reasoning, 15.3 points apart on average over 9 shared benchmarks.
- Widest single gap
- Terminal-Bench: Gemini 3.1 Pro Preview 80.2% against GLM 4.7 33.4%, 46.8 points apart on a 0 to 100 scale.
- Output price
- Gemini 3.1 Pro Preview $12.00 against GLM 4.7 $2.20 per million output tokens, 5.5x apart.
- Context window
- Gemini 3.1 Pro Preview takes 1.05M tokens, GLM 4.7 205K.
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.
| Category | Gemini 3.1 Pro Preview | Bars | GLM 4.7 | Ties |
|---|---|---|---|---|
| Coding | 11 | 0 | ||
| Intelligence | 1 | 0 | ||
| Agentic work | 2 | 4 | ||
| Reasoning | 9 | 0 | ||
| Math | 5 | 0 | ||
| Knowledge | 12 | 0 | ||
| Web design | 8 | 0 | ||
| General | 22 | 0 | ||
| All shared boards | 70 | 4 |
CodingLike-for-likeSix of these boards feed the Vibe Coding Index110
| Benchmark | Gemini 3.1 Pro Preview | GLM 4.7 | Leader |
|---|---|---|---|
| LMArena WebDev | 1447 | 1435 | Gemini 3.1 Pro Preview |
| AA Coding Index | 68.8 | 45.3 | Gemini 3.1 Pro Preview |
| LiveCodeBench (Vals AI) | 88.5% | 82.2% | Gemini 3.1 Pro Preview |
| SWE-bench Verified (Vals AI) | 78.8% | 69.4% | Gemini 3.1 Pro Preview |
| Terminal-Bench 4 (Vals AI) | 2.5% | Not measured | Only Gemini 3.1 Pro Preview measured |
| Vibe Code Bench (Vals AI) | 32.0% | Not measured | Only Gemini 3.1 Pro Preview measured |
| Code migration (Vals AI) | 17.3% | Not measured | Only Gemini 3.1 Pro Preview measured |
| ProgramBench (Vals AI) | 0.0% | Not measured | Only Gemini 3.1 Pro Preview measured |
| IOI (Vals AI) | 51.8% | Not measured | Only Gemini 3.1 Pro Preview measured |
| Terminal-Bench 2.1 (Vals AI) | 70.8% | Not measured | Only Gemini 3.1 Pro Preview measured |
| Vibe Code Bench 1-100 (Vals AI) | 6.7% | Not measured | Only Gemini 3.1 Pro Preview measured |
| LiveCodeBench (Artificial Analysis run) | Not measured | 89.4% | Only GLM 4.7 measured |
| SciCode | 58.7% | Not measured | Only Gemini 3.1 Pro Preview measured |
| Terminal-Bench Hard (Artificial Analysis run) | 53.8% | 31.8% | Gemini 3.1 Pro Preview |
| Terminal-Bench | 80.2% | 33.4% | Gemini 3.1 Pro Preview |
| GSO-Bench | 22.6% | Not measured | Only Gemini 3.1 Pro Preview measured |
| WeirdML | 72.1% | Not measured | Only Gemini 3.1 Pro Preview measured |
| MirrorCode | 8.9% | Not measured | Only Gemini 3.1 Pro Preview measured |
| ALE-Bench | 1160.6 | 399.5 | Gemini 3.1 Pro Preview |
| LMArena Text: coding | 1484 | 1454 | Gemini 3.1 Pro Preview |
| LMArena Text: software and IT | 1487 | 1453 | Gemini 3.1 Pro Preview |
| LMArena WebDev: React | 1438 | 1420 | Gemini 3.1 Pro Preview |
| LMArena WebDev: HTML | 1490 | 1447 | Gemini 3.1 Pro Preview |
| LMArena WebDev: from an image | 1481 | Not measured | Only Gemini 3.1 Pro Preview measured |
| SciCode | 14.3% | Not measured | Only Gemini 3.1 Pro Preview measured |
| Neither model has a result on the other 14 boards here | |||
IntelligenceLike-for-likePublic boards, shown as published, kept out of the index10
| Benchmark | Gemini 3.1 Pro Preview | GLM 4.7 | Leader |
|---|---|---|---|
| AA Intelligence Index | 29.7 | 22.2 | Gemini 3.1 Pro Preview |
| Epoch Capabilities Index | Not measured | 143.6 | Only GLM 4.7 measured |
Agentic workLike-for-likePublic boards, shown as published, kept out of the index24
| Benchmark | Gemini 3.1 Pro Preview | GLM 4.7 | Leader |
|---|---|---|---|
| AA Agentic Index | 8.2 | Not measured | Only Gemini 3.1 Pro Preview measured |
| Design Arena: agents building web apps | 1125 | Not measured | Only Gemini 3.1 Pro Preview measured |
| Design Arena: agents building full-stack apps | 1068 | 1050 | Gemini 3.1 Pro Preview |
| Design Arena: agents building mobile apps | 1094 | 1105 | GLM 4.7 |
| Design Arena: agents building Android apps | 1049 | 1112 | GLM 4.7 |
| Design Arena: agents building Godot games | 1236 | 1058 | Gemini 3.1 Pro Preview |
| Design Arena: agents building games | 1113 | Not measured | Only Gemini 3.1 Pro Preview measured |
| Design Arena: HTML slides | 1103 | Not measured | Only Gemini 3.1 Pro Preview measured |
| Design Arena: PowerPoint slides | 1041 | Not measured | Only Gemini 3.1 Pro Preview measured |
| SREBench (Vals AI) | 0.0% | Not measured | Only Gemini 3.1 Pro Preview measured |
| Finance Agent (Vals AI) | 43.0% | Not measured | Only Gemini 3.1 Pro Preview measured |
| Tax Agent Bench (Vals AI) | 9.3% | Not measured | Only Gemini 3.1 Pro Preview measured |
| Legal Research Bench (Vals AI) | 20.7% | Not measured | Only Gemini 3.1 Pro Preview measured |
| Excel Modeling Benchmark (Vals AI) | 52.6% | Not measured | Only Gemini 3.1 Pro Preview measured |
| BioMysteryBench (Vals AI) | 60.0% | Not measured | Only Gemini 3.1 Pro Preview measured |
| Terminal-Bench-Science (Vals AI) | 1.4% | Not measured | Only Gemini 3.1 Pro Preview measured |
| Vals Science Index | 27.4% | Not measured | Only Gemini 3.1 Pro Preview measured |
| τ²-Bench Telecom | 95.6% | 95.9% | GLM 4.7 |
| APEX-Agents | 35.1% | Not measured | Only Gemini 3.1 Pro Preview measured |
| METR time horizons | 77.0% | Not measured | Only Gemini 3.1 Pro Preview measured |
| BALROG | 57.0% | Not measured | Only Gemini 3.1 Pro Preview measured |
| DeepResearch Bench | 47.8% | Not measured | Only Gemini 3.1 Pro Preview measured |
| PostTrainBench | 22.0% | Not measured | Only Gemini 3.1 Pro Preview measured |
| Vending-Bench 2 | $911 | $2,377 | GLM 4.7 |
| BrowseComp-Plus | Not measured | 64.7% | Only GLM 4.7 measured |
| Neither model has a result on the other 16 boards here | |||
ReasoningLike-for-likePublic boards, shown as published, kept out of the index90
| Benchmark | Gemini 3.1 Pro Preview | GLM 4.7 | Leader |
|---|---|---|---|
| GPQA Diamond | 95.5% | 80.0% | Gemini 3.1 Pro Preview |
| MysteryMechanism (Vals AI) | 20.7% | Not measured | Only Gemini 3.1 Pro Preview measured |
| MMMU Pro (Vals AI) | 88.2% | Not measured | Only Gemini 3.1 Pro Preview measured |
| GPQA Diamond (Artificial Analysis run) | 94.1% | 85.9% | Gemini 3.1 Pro Preview |
| Humanity's Last Exam (Artificial Analysis run) | 47.0% | 27.4% | Gemini 3.1 Pro Preview |
| GPQA Diamond (Epoch AI run) | 94.4% | 83.3% | Gemini 3.1 Pro Preview |
| ARC-AGI | 98.0% | Not measured | Only Gemini 3.1 Pro Preview measured |
| ARC-AGI-2 | 77.1% | Not measured | Only Gemini 3.1 Pro Preview measured |
| SimpleBench | 79.6% | 47.7% | Gemini 3.1 Pro Preview |
| Chess puzzles | 51.0% | 21.0% | Gemini 3.1 Pro Preview |
| Mystery game puzzles | 34.0% | Not measured | Only Gemini 3.1 Pro Preview measured |
| EBR-bench | 14.3% | Not measured | Only Gemini 3.1 Pro Preview measured |
| LMArena Text: hard prompts | 1485 | 1443 | Gemini 3.1 Pro Preview |
| LMArena Text: expert | 1483 | 1424 | Gemini 3.1 Pro Preview |
| LMArena Text: hard prompts in English | 1480 | 1452 | Gemini 3.1 Pro Preview |
| LMArena Vision: diagrams | 1311 | Not measured | Only Gemini 3.1 Pro Preview measured |
| LMArena Vision: homework | 1316 | Not measured | Only Gemini 3.1 Pro Preview measured |
| Neither model has a result on the other 5 boards here | |||
MathLike-for-likePublic boards, shown as published, kept out of the index50
| Benchmark | Gemini 3.1 Pro Preview | GLM 4.7 | Leader |
|---|---|---|---|
| AIME | 98.1% | 93.3% | Gemini 3.1 Pro Preview |
| MGSM (Vals AI) | Not measured | 88.2% | Only GLM 4.7 measured |
| AA Math Index | Not measured | 95.0 | Only GLM 4.7 measured |
| AIME 2025 (Artificial Analysis run) | Not measured | 95.0% | Only GLM 4.7 measured |
| OTIS Mock AIME | 95.6% | 83.3% | Gemini 3.1 Pro Preview |
| FrontierMath, tiers 1 to 3 | 59.6% | Not measured | Only Gemini 3.1 Pro Preview measured |
| FrontierMath, tier 4 | 26.8% | Not measured | Only Gemini 3.1 Pro Preview measured |
| ProofBench | 26.0% | 6.0% | Gemini 3.1 Pro Preview |
| LMArena Text: math | 1486 | 1424 | Gemini 3.1 Pro Preview |
| LMArena Text: mathematical work | 1478 | 1411 | Gemini 3.1 Pro Preview |
| Neither model has a result on the other 3 boards here | |||
KnowledgeLike-for-likePublic boards, shown as published, kept out of the index120
| Benchmark | Gemini 3.1 Pro Preview | GLM 4.7 | Leader |
|---|---|---|---|
| MMLU Pro | 91.0% | 82.7% | Gemini 3.1 Pro Preview |
| LegalBench (Vals AI) | 87.4% | 83.4% | Gemini 3.1 Pro Preview |
| CaseLaw (Vals AI) | 64.8% | 54.9% | Gemini 3.1 Pro Preview |
| CorpFin (Vals AI) | 64.5% | 46.4% | Gemini 3.1 Pro Preview |
| TaxEval (Vals AI) | 72.9% | 68.8% | Gemini 3.1 Pro Preview |
| MortgageTax (Vals AI) | 69.4% | Not measured | Only Gemini 3.1 Pro Preview measured |
| MedQA (Vals AI) | 96.4% | 93.7% | Gemini 3.1 Pro Preview |
| MedCode (Vals AI) | 59.1% | 32.8% | Gemini 3.1 Pro Preview |
| MMLU Pro (Artificial Analysis run) | Not measured | 85.6% | Only GLM 4.7 measured |
| SimpleQA Verified | 73.5% | 32.2% | Gemini 3.1 Pro Preview |
| LMArena Text: science | 1497 | 1457 | Gemini 3.1 Pro Preview |
| LMArena Text: medicine and healthcare | 1486 | 1469 | Gemini 3.1 Pro Preview |
| LMArena Text: legal and government | 1487 | 1444 | Gemini 3.1 Pro Preview |
| LMArena Text: business and finance | 1459 | 1429 | Gemini 3.1 Pro Preview |
| FACTS Benchmark Suite | 67.4% | Not measured | Only Gemini 3.1 Pro Preview measured |
| Neither model has a result on the other 3 boards here | |||
Web designLike-for-likePublic boards, shown as published, kept out of the index80
| Benchmark | Gemini 3.1 Pro Preview | GLM 4.7 | Leader |
|---|---|---|---|
| Design Arena: websites | 1233 | 1225 | Gemini 3.1 Pro Preview |
| Design Arena: UI components | 1224 | 1196 | Gemini 3.1 Pro Preview |
| Design Arena: game dev | 1202 | 1188 | Gemini 3.1 Pro Preview |
| Design Arena: data viz | 1209 | 1195 | Gemini 3.1 Pro Preview |
| Design Arena: 3D | 1234 | 1190 | Gemini 3.1 Pro Preview |
| Design Arena: all code categories | 1231 | 1216 | Gemini 3.1 Pro Preview |
| Design Arena: SVG | 1285 | 1142 | Gemini 3.1 Pro Preview |
| Design Arena: ASCII art | 1270 | 1165 | Gemini 3.1 Pro Preview |
| Neither model has a result on the other 1 board here | |||
GeneralLike-for-likePublic boards, shown as published, kept out of the index220
| Benchmark | Gemini 3.1 Pro Preview | GLM 4.7 | Leader |
|---|---|---|---|
| Public Benefits Bench (Vals AI) | 53.8% | Not measured | Only Gemini 3.1 Pro Preview measured |
| SAGE (Vals AI) | 48.7% | Not measured | Only Gemini 3.1 Pro Preview measured |
| MedScribe (Vals AI) | 76.1% | 68.6% | Gemini 3.1 Pro Preview |
| Vals Multimodal Index | 56.1% | Not measured | Only Gemini 3.1 Pro Preview measured |
| IFBench | 77.1% | 67.9% | Gemini 3.1 Pro Preview |
| Long context reasoning (AA-LCR) | 82.0% | 71.0% | Gemini 3.1 Pro Preview |
| DTBench | 97.1% | Not measured | Only Gemini 3.1 Pro Preview measured |
| LMCA | 53.8% | Not measured | Only Gemini 3.1 Pro Preview measured |
| CL-bench | 20.8% | 15.9% | Gemini 3.1 Pro Preview |
| Furniture assembly | 26.7% | Not measured | Only Gemini 3.1 Pro Preview measured |
| ExploitBench | 26.1% | Not measured | Only Gemini 3.1 Pro Preview measured |
| CL-bench Life | 16.9% | 10.9% | Gemini 3.1 Pro Preview |
| LMArena Text | 1480 | 1435 | Gemini 3.1 Pro Preview |
| LMArena Text: instruction following | 1466 | 1412 | Gemini 3.1 Pro Preview |
| LMArena Text: creative writing | 1482 | 1401 | Gemini 3.1 Pro Preview |
| LMArena Vision | 1296 | Not measured | Only Gemini 3.1 Pro Preview measured |
| LMArena Text: English | 1478 | 1453 | Gemini 3.1 Pro Preview |
| LMArena Text: non-English | 1476 | 1417 | Gemini 3.1 Pro Preview |
| LMArena Text: Chinese | 1527 | 1495 | Gemini 3.1 Pro Preview |
| LMArena Text: German | 1490 | 1426 | Gemini 3.1 Pro Preview |
| LMArena Text: Japanese | 1491 | 1439 | Gemini 3.1 Pro Preview |
| LMArena Text: Korean | 1455 | 1399 | Gemini 3.1 Pro Preview |
| LMArena Text: French | 1487 | 1432 | Gemini 3.1 Pro Preview |
| LMArena Text: Spanish | 1481 | 1434 | Gemini 3.1 Pro Preview |
| LMArena Text: Russian | 1497 | 1423 | Gemini 3.1 Pro Preview |
| LMArena Text: Polish | 1498 | 1435 | Gemini 3.1 Pro Preview |
| LMArena Text: multi-turn | 1487 | 1446 | Gemini 3.1 Pro Preview |
| LMArena Text: longer queries | 1482 | 1432 | Gemini 3.1 Pro Preview |
| LMArena Text: writing and language | 1481 | 1411 | Gemini 3.1 Pro Preview |
| LMArena Text: entertainment and media | 1465 | 1400 | Gemini 3.1 Pro Preview |
| LMArena Vision: English | 1287 | Not measured | Only Gemini 3.1 Pro Preview measured |
| LMArena Vision: Chinese | 1364 | Not measured | Only Gemini 3.1 Pro Preview measured |
| LMArena Vision: reading text | 1304 | Not measured | Only Gemini 3.1 Pro Preview measured |
| LMArena Vision: humor | 1322 | Not measured | Only Gemini 3.1 Pro Preview measured |
| LMArena Vision: captioning | 1345 | Not measured | Only Gemini 3.1 Pro Preview measured |
| LMArena Vision: recognizing things | 1330 | Not measured | Only Gemini 3.1 Pro Preview measured |
| LMArena Vision: creative writing | 1324 | Not measured | Only Gemini 3.1 Pro Preview measured |
| LMArena Document | 1444 | Not measured | Only Gemini 3.1 Pro Preview measured |
| Neither model has a result on the other 8 boards here | |||
Image generationNot comparablePublic boards, shown as published, kept out of the index0 boards, none shared
| Benchmark | Gemini 3.1 Pro Preview | GLM 4.7 | Leader |
|---|---|---|---|
| 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 4.7 costs less
Repository review
50K input + 3K output tokens
GLM 4.7 costs less
Agent loop
200K input + 10K output tokens
GLM 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.
| Specification | Google Gemini 3.1 Pro Preview | Z.ai GLM 4.7 |
|---|---|---|
| Maker | Z.ai | |
| Weights | No public weights listed | Open weights |
| Released | February 19, 2026 | December 22, 2025 |
| Context window | 1.05M | 205K |
| Input $/Mtok | $2.00 | $0.60 |
| Output $/Mtok | $12.00 | $2.20 |
| Coding index | 32.3 | 55.1 |
| Independent measurements behind it | 4 | 2 |
| Cost per solved task | $0.99 | $0.29 |
| Source | OpenRouter listing | OpenRouter listing |
Questions
Is Gemini 3.1 Pro Preview better than GLM 4.7 for coding?
Pick GLM 4.7 for coding: it scores 55.1 on the Vibe Coding Index against 32.3 for Gemini 3.1 Pro Preview, though on 2 benchmarks against 4. Pick Gemini 3.1 Pro Preview for a larger context window (1.05M against 205K tokens) and work measured by LMArena WebDev or AA Coding Index, where it leads.
Which is cheaper, Gemini 3.1 Pro Preview or GLM 4.7?
Gemini 3.1 Pro Preview costs $2.00 per million input tokens and $12.00 per million output tokens; GLM 4.7 costs $0.60 and $2.20. Per solved SWE-bench Verified task, Gemini 3.1 Pro Preview costs $0.99 and GLM 4.7 $0.29.
Which has the bigger context window, Gemini 3.1 Pro Preview or GLM 4.7?
Gemini 3.1 Pro Preview, with 1.05M tokens against 205K.
How many benchmarks is the Gemini 3.1 Pro Preview vs GLM 4.7 comparison based on?
74 benchmarks have a result for both models as of October 22, 2026. Gemini 3.1 Pro Preview's coding index rests on 4 independent benchmarks and GLM 4.7's on 2. Where only one model has a result, the page says so instead of naming a winner.