Anthropic Claude vs Google Gemini — API Pricing Comparison

Compare Anthropic Claude and Google Gemini models side by side. Google dominates on price — Gemini Flash Lite ($0.075/M) is 13x cheaper than Haiku 4.5 ($1/M). But Anthropic's Sonnet 4.6 offers 1M context at $3/M for quality-focused workloads.

Pricing data verified: May 29, 2026

Cheapest Model
Google
Gemini Flash Lite at $0.075/M input (Anthropic's cheapest is Haiku at $1/M)
Best Context/Price
Google
Flash Lite: 1M context at $0.075/M vs Sonnet 4.6: 1M context at $3/M
Premium Quality
Anthropic
Opus 4.7 ($5/$25) and Sonnet 4.6 ($3/$15) lead on reasoning quality

All Models Compared

Every Anthropic Claude and Google Gemini model, ranked by input price.

Model Provider Tier Input (per 1M) Output (per 1M) Context
Gemini 2.0 Flash Lite Google Budget $0.075 $0.30 1M
Gemini 2.0 Flash Google Budget $0.10 $0.40 1M
Claude Haiku 4.5 Anthropic Budget $1.00 $5.00 200K
Gemini 2.5 Pro Google Mid $1.25 $10.00 1M
Gemini 3.1 Pro Google Mid $2.00 $12.00 1M
Claude Sonnet 4.6 Anthropic Mid $3.00 $15.00 1M
Claude Sonnet 4 Anthropic Mid $3.00 $15.00 200K
Claude Opus 4.7 Anthropic Premium $5.00 $25.00 1M
Claude 4 Opus Anthropic Premium $15.00 $75.00 200K

Calculate Your Exact Costs

Pick your Anthropic and Google models, enter your usage, see the savings.

vs
Anthropic
Claude Sonnet 4.6
$0.00
per month
Input cost $0.00
Output cost $0.00
Per request $0.00
Google
Gemini Flash Lite
$0.00
per month
Input cost $0.00
Output cost $0.00
Per request $0.00
Enter your usage above to see savings.

Which Should You Choose?

Chatbot / Customer Support

High volume, short responses. Cost per message matters most. Google's budget models are dramatically cheaper for high-volume chat.

Pick Google: Gemini Flash Lite ($0.075/$0.30) at 5,000 requests/day costs $3.38/month. Haiku 4.5 ($1/$5) at the same volume costs $375/month. That's a 111x difference.

Code Generation

Complex reasoning, longer outputs. Quality matters more than cost. Claude Sonnet 4.6 excels at code with 1M context for full codebase understanding.

Pick Anthropic: Sonnet 4.6 ($3/$15 with 1M context) delivers top-tier code quality. Gemini 2.5 Pro ($1.25/$10) is 58% cheaper but may need more retries for complex tasks, offsetting savings.

Long Document Analysis

Processing large documents, legal contracts, or codebases. Context window is critical. Both providers offer 1M context on select models.

Pick Google: Gemini Flash Lite gives you 1M context at $0.075/M — 40x cheaper than Sonnet 4.6's 1M context at $3/M. For pure document processing, Google's price-to-context ratio is unbeatable.

Startup MVP / Side Project

Minimize costs while building. Need reliable API at the lowest price. Google's free tier is unmatched for prototyping.

Pick Google: Free tier (1M tokens/day) for prototyping + Flash Lite ($0.075/M) for production. Anthropic has no free tier and no sub-$1 models. Google wins for bootstrapped projects.

Enterprise / Mission-Critical

Need the highest quality outputs, complex multi-step reasoning, and nuanced instruction following. Quality and reliability outweigh cost.

Pick Anthropic: Opus 4.7 ($5/$25) is Anthropic's flagship for the most demanding tasks. It outperforms Gemini 3.1 Pro ($2/$12) on complex reasoning benchmarks. When quality is non-negotiable, Anthropic justifies the premium.

Multi-Model Pipeline

Route different tasks to different models. Need variety in tiers. Both providers offer good tier granularity.

Pick Google: Route simple tasks to Flash Lite ($0.075), complex to Gemini 2.5 Pro ($1.25). Average cost under $0.50/M. Anthropic's cheapest model (Haiku at $1/M) is still 13x pricier than Google's cheapest.

Save More with APIpulse Pro

Get personalized cost optimization recommendations for your specific workload.

Save scenarios — compare up to 10 configs
Export reports — PDF cost analysis
Optimization tips — save up to 40%
Get Pro — $29

Frequently Asked Questions

Is Anthropic Claude or Google Gemini cheaper for API usage?

Google Gemini is cheaper at every comparable tier. Gemini Flash Lite ($0.075/$0.30 per 1M tokens) is 13x cheaper on input than Claude Haiku 4.5 ($1/$5). Gemini 2.5 Pro ($1.25/$10) is 58% cheaper on input than Claude Sonnet 4.6 ($3/$15). The one area where Anthropic competes on value is context: Sonnet 4.6 offers 1M context at $3/M input, while Gemini 3.1 Pro offers 1M context at $2/M.

What is the cheapest Anthropic Claude model?

Claude Haiku 4.5 at $1.00 input / $5.00 output per 1M tokens is Anthropic's cheapest model. It offers 200K context. For comparison, Google's cheapest model (Gemini Flash Lite at $0.075/$0.30) is 13x cheaper on input with 5x more context (1M).

Does Claude or Gemini have a larger context window?

Both providers offer 1M context on their best models, but Google offers it across more models. All four Gemini models support 1M tokens. On the Anthropic side, only Opus 4.7 and Sonnet 4.6 support 1M; Sonnet 4 and Haiku 4.5 max out at 200K. For budget long-document work, Google's Flash Lite at $0.075/M with 1M context is unbeatable.

When should I use Anthropic Claude over Google Gemini?

Choose Claude when you need top-tier reasoning, complex code generation, or nuanced instruction following. Claude Opus 4.7 and Sonnet 4.6 consistently rank among the best for quality. For cost-sensitive, high-volume, or long-document tasks, Google Gemini is the better choice. Sonnet 4.6 ($3/$15 with 1M context) is the sweet spot if you want Anthropic quality without the Opus premium.

Does Anthropic offer a free API tier?

Anthropic does not offer a free API tier. All usage is billed per token. Google offers the most generous free tier among major providers: 1M tokens/day for Gemini Flash models via Google AI Studio. For prototyping and experimentation, Google's free tier is the clear starting point.

Share This Comparison