Gemini 3.1 Pro Preview vs GLM 5.2
API pricing, context window and capabilities for Gemini 3.1 Pro Preview and GLM 5.2, side by side. Prices are the cheapest serving route per 1M tokens, verified against LiteLLM and OpenRouter.
Verdict
computed from the published numbersGemini 3.1 Pro Preview wins on context window. GLM 5.2 wins on price and on intelligence.
Price
GLM 5.2
Coding
Tied
Intelligence
GLM 5.2
Context window
Gemini 3.1 Pro Preview
Key takeaways
who wins on what, from the published numbersGemini 3.1 Pro Preview wins
- Larger context window (1M vs 262K)
- More serving providers (4 vs 1)
- Supports vision
- Supports audio
- Supports prompt caching
- Supports structured output
- Has web search
GLM 5.2 wins
- Cheaper input ($2.00 vs $1.40 /1M)
- Cheaper output ($12.00 vs $4.40 /1M)
- Higher max output (66K vs 262K)
Cheaper overall
GLM 5.2
$1.40 + $4.40 /1M
Larger context
Gemini 3.1 Pro Preview
1M
More providers
Gemini 3.1 Pro Preview
4 providers
Pricing & specs
cheapest serving route · per 1M tokens| Gemini 3.1 Pro Preview | GLM 5.2 | |
|---|---|---|
| Input $/1M | $2.00 | $1.40 best |
| Output $/1M | $12.00 | $4.40 best |
| Context window | 1M best | 262K |
| Max output | 66K | 262K best |
| Serving providers | 4 best | 1 |
| Released | 2026-02-19 | 2026-06-13 |
Benchmarks
Artificial Analysis indices, side by side| Gemini 3.1 Pro Preview | GLM 5.2 | |
|---|---|---|
| Intelligence | 46.5 | 51.1 best |
| Coding | 68.8 | 68.8 |
| GPQA Diamond | 94% best | 89% |
| Output speed | 154 t/s | 200 t/s best |
| Latency (TTFT) | 34.98s | 6.32s best |
Cost calculator
choose a serving route for each sideInput tokens / month
Output tokens / month
Gemini 3.1 Pro Preview
via Vertex AI
$22
GLM 5.2
via Cloudflare
$11
Capabilities
feature support, side by side| Feature | Gemini 3.1 Pro Preview | GLM 5.2 |
|---|---|---|
| Vision | ✓ | — |
| Tool use | ✓ | ✓ |
| Reasoning | ✓ | ✓ |
| Audio | ✓ | — |
| Prompt caching | ✓ | — |
| Structured output | ✓ | — |
| Web search | ✓ | — |
Related comparisons
Frequently asked questions
Which is cheaper, Gemini 3.1 Pro Preview or GLM 5.2?
GLM 5.2 is cheaper for input ($2.00 vs $1.40 per 1M tokens). GLM 5.2 is cheaper for output ($12.00 vs $4.40 per 1M tokens).
What is the context window difference between Gemini 3.1 Pro Preview and GLM 5.2?
Gemini 3.1 Pro Preview has a 1M-token context window and GLM 5.2 has 262K tokens, so Gemini 3.1 Pro Preview can take a larger prompt.
How do Gemini 3.1 Pro Preview and GLM 5.2 compare on benchmarks?
On the tracked Artificial Analysis indices, they score about the same on coding, and GLM 5.2 leads on intelligence.
Pricing verified against LiteLLM + OpenRouter + provider pages · refreshed daily
Every weekday
AI moves fast. Here's your debrief.
News, analysis, tools, and more.
For people who build with AI