Current price table
| Model | Input / M | Output / M | Cache read | Batch |
| Claude Fable 5.1 | $10 | $50 | $0.25 | $5 / $25 |
| Claude Opus 5 | $5 | $25 | $0.50 | $2.50 / $12.50 |
| Claude Sonnet 5 | $2 | $10 | $0.20 | $1 / $5 |
| Claude Sonnet 4.6 | $3 | $15 | $0.30 | $1.50 / $7.50 |
| Claude Haiku 4.5 | $1 | $5 | $0.10 | $0.50 / $2.50 |
| GPT-5.5 | $5 | $30 | $0.50 | 50% off |
| GPT-5.4 | $2.50 | $15 | $0.25 | 50% off |
| GPT-5.4 mini | $0.75 | $4.50 | $0.075 | 50% off |
Anthropic prices from platform.claude.com; OpenAI from its API pricing page. Cache write on Claude is 1.25× input (5-minute TTL) or 2× (1-hour TTL). Claude 4.6+ models include 1M-token context at standard pricing.
Why input dominates — and why caching matters
People price the API by output tokens because that's what they see. But a coding request is 90%+ input: the system prompt, CLAUDE.md, tool definitions, the files Claude read, and the entire conversation so far. A fresh Claude Code request is 5,000–20,000 tokens of input for 500–3,000 of output; by turn fifteen of a session the input is 100,000+. Without caching, that session would cost dollars per turn on Opus. With caching, 80–95% of that input is served at a tenth of the price (a fortieth on Fable 5.1), which is how a long Sonnet session ends up at cents per turn. Claude Code shows the cache hit rate in /usage; if it's under 80%, something — a changing system prompt, tool definitions, a break longer than the cache lifetime — is invalidating it.
Presets explained
- Simple chat turn: a question with no files or tools. 2K in, 500 out — under a cent on Sonnet.
- Claude Code, fresh session: system prompt + CLAUDE.md + a few files. 15K in, 1.5K out, 80% cached after the first turn.
- Claude Code, long session: the all-day session. 120K in, 2K out, 90% cached. This is where
/clearearns its keep. - RAG / document Q&A: a big retrieved context and a short answer. Batch it if the answers aren't interactive.
- Agent tool-loop step: one step of an autonomous agent — growing context, small output, mostly cached. Multiply by steps per task.
Claude vs GPT at list price
Model for model, Sonnet 5 undercuts GPT-5.4 on both input and output, Opus 5 matches GPT-5.5 on input and beats it on output, and Haiku 4.5 is slightly pricier than GPT-5.4 mini. But per-token price is the wrong comparison for coding: what matters is tokens to completion. A model that solves the task in one pass at $5/M beats one that needs three attempts at $2/M. Use the calculator for the arithmetic, then measure real token counts on your own tasks before choosing.
API vs subscription
If your monthly API estimate for interactive coding lands above about $100, a Max plan is usually cheaper and comes with a 1-hour prompt-cache lifetime instead of 5 minutes. The API is the right tool for automation, CI, products you ship, batch jobs, and anything that needs no weekly cap. Anthropic's benchmark for interactive Claude Code on the API is about $13 per developer per active day, $150–250 per month.
Would a subscription be cheaper? →
Frequently asked questions
Claude API price per million tokens?
Sonnet 5 $2/$10, Opus 5 $5/$25, Fable 5.1 $10/$50, Sonnet 4.6 $3/$15, Haiku 4.5 $1/$5 (input/output). Cache reads 10% of input; batch 50% off.
How many tokens in a Claude Code request?
5–20K input and 0.5–3K output when fresh; 100K+ input in a long session, mostly cached.
Does caching really help?
Yes — cached input is 10% of the price, and steady sessions run 80–95% cached.
Are thinking tokens billed?
Yes, as output tokens. Lower the effort level on simple tasks.
Is there a long-context surcharge?
Not on Claude 4.6+; the 1M context is standard price.
What's the Batch API?
Half price for jobs that can wait up to 24 hours. Not for interactive work.