multimodal

Claude Sonnet 4 6 vs Gemini 2.5 Flash

Side-by-side pricing, context window, features, and per-use-case verdict. Data sourced from LiteLLM, updated regularly.

Specifications

Feature Claude Sonnet 4 6 Gemini 2.5 Flash
Provider anthropic vertex ai-language-models
Model ID claude-sonnet-4-6 gemini-2.5-flash
Input / 1M tokens $3.00 $0.30 (90% cheaper)
Output / 1M tokens $15.00 $2.50 (83% cheaper)
Cached input / 1M $0.30 $0.03
Context window 1000kk tokens 1049kk tokens
Max output 64kk tokens 66kk tokens
Vision
Function calling
Prompt caching
Web search
JSON schema

Monthly cost comparison

No cache discount applied — pure token costs at three usage scales.

Scale Claude Sonnet 4 6 Gemini 2.5 Flash Winner
Small
1M in / 0.2M out
$6.00 $0.80 Gemini 2.5 Flash saves 87%
Medium
10M in / 2M out
$60.00 $8.00 Gemini 2.5 Flash saves 87%
Large
100M in / 20M out
$600 $80.00 Gemini 2.5 Flash saves 87%

Category winners

Cheapest input
Gemini 2.5 Flash
$0.30/M · 90% less than the other
Cheapest output
Gemini 2.5 Flash
$2.50/M · 83% less than the other
Larger context
Gemini 2.5 Flash
1049kk tokens · 5% larger window
More features
Gemini 2.5 Flash
5 / 5 capabilities

Better for…

High-volume RAG & repeated context
$0.03/M cached input — prompt caching makes repeated context retrieval significantly cheaper
Gemini 2.5 Flash
Short interactions & high-throughput APIs
$2.50/M output — 83% cheaper on output at scale
Gemini 2.5 Flash
Agentic workflows & tool use
Supports 5 of 5 tracked capabilities (vision, function calling, caching, web search, JSON schema)
Gemini 2.5 Flash
Cost-sensitive production at scale
$80.00/month at 100M-token scale — 87% cheaper than the alternative
Gemini 2.5 Flash

Deep-dive on each model

Pricing data sourced from LiteLLM and refreshed regularly. Always verify with each provider's official pricing page before making business decisions.