Claude Opus 4.8 vs Gemini 3.1 Pro Preview

API pricing, context window and capabilities for Claude Opus 4.8 and Gemini 3.1 Pro Preview, side by side. Prices are the cheapest serving route per 1M tokens, verified against LiteLLM and OpenRouter.

Verdict

computed from the published numbers

Claude Opus 4.8 wins on coding and on intelligence. Gemini 3.1 Pro Preview wins on price.

Price
Gemini 3.1 Pro Preview
Coding
Claude Opus 4.8
Intelligence
Claude Opus 4.8
Context window
Tied

Key takeaways

who wins on what, from the published numbers

Claude Opus 4.8 wins

  • Higher max output (128K vs 66K)

Gemini 3.1 Pro Preview wins

  • Cheaper input ($5.00 vs $2.00 /1M)
  • Cheaper output ($25.00 vs $12.00 /1M)
  • Supports audio
  • Has web search
Cheaper overall
Gemini 3.1 Pro Preview
$2.00 + $12.00 /1M
Larger context
Tied
More providers
Tied

Pricing & specs

cheapest serving route · per 1M tokens
Claude Opus 4.8Gemini 3.1 Pro Preview
Input $/1M$5.00 $2.00 best
Output $/1M$25.00 $12.00 best
Context window1M 1M
Max output128K best66K
Serving providers4 4
Released2026-05-28 2026-02-19

Benchmarks

Artificial Analysis indices, side by side
Claude Opus 4.8Gemini 3.1 Pro Preview
Intelligence55.7 best46.5
Coding74.3 best68.8
GPQA Diamond92% 94% best
Output speed68 t/s 154 t/s best
Latency (TTFT)38.57s 34.98s best

Cost calculator

choose a serving route for each side
Input tokens / month
Output tokens / month
Claude Opus 4.8
via Amazon Bedrock
$50
Gemini 3.1 Pro Preview
via Vertex AI
$22

Capabilities

feature support, side by side
FeatureClaude Opus 4.8Gemini 3.1 Pro Preview
Vision
Tool use
Reasoning
Audio
Prompt caching
Structured output
Web search

Related comparisons

Frequently asked questions

Which is cheaper, Claude Opus 4.8 or Gemini 3.1 Pro Preview?
Gemini 3.1 Pro Preview is cheaper for input ($5.00 vs $2.00 per 1M tokens). Gemini 3.1 Pro Preview is cheaper for output ($25.00 vs $12.00 per 1M tokens).
What is the context window difference between Claude Opus 4.8 and Gemini 3.1 Pro Preview?
Both Claude Opus 4.8 and Gemini 3.1 Pro Preview have about a 1M-token context window.
How do Claude Opus 4.8 and Gemini 3.1 Pro Preview compare on benchmarks?
On the tracked Artificial Analysis indices, Claude Opus 4.8 leads on coding, and Claude Opus 4.8 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