Claude API pricing looks simple until the same prompt has a cache write, a cache read, or a long-context surcharge. I checked Anthropic API pricing and the model lifecycle pages on November 3, 2026, then priced the same coding workload across Claude’s models.

The short answer: Claude Haiku 5.5 starts at $0.10 per million input tokens and $0.50 per million output tokens; Sonnet 5.5 is $2/$10, Claude Opus pricing is $4/$20 for Opus 5.5, and Fable 5.1 is $10/$50. A 20,000-input/2,000-output turn costs $0.003 on Haiku, $0.06 on Sonnet, $0.12 on Opus, or $0.30 on Fable before caching. Prices are in USD and were checked November 3, 2026.

What is Claude API pricing for each model?

Anthropic’s 2026 pricing page is the source of truth for Claude model pricing, in rates per million tokens, checked November 2026.

Claude API modelContextInput / outputCache write, 5m / 1hCache readBatch input / outputLong-context price
Fable 5.11M$10 / $50$12.50 / $20$0.25$5 / $25Standard
Mythos 5.11M$10 / $50$12.50 / $20$0.25$5 / $25Standard
Fable 51M$10 / $50$12.50 / $20$1.00$5 / $25Standard
Mythos 51M$10 / $50$12.50 / $20$1.00$5 / $25Standard
Opus 5.51M$4 / $20$5 / $8$0.20$2 / $10Standard
Opus 51M$5 / $25$6.25 / $10$0.50$2.50 / $12.50Standard
Opus 4.81M$5 / $25$6.25 / $10$0.50$2.50 / $12.50Standard
Opus 4.71M$5 / $25$6.25 / $10$0.50$2.50 / $12.50Standard
Opus 4.61M$5 / $25$6.25 / $10$0.50$2.50 / $12.50Standard
Opus 4.5200K$5 / $25$6.25 / $10$0.50$2.50 / $12.50Standard
Sonnet 5.51M$2 / $10$2.50 / $4$0.10$1 / $5Standard
Sonnet 51M$2 / $10$2.50 / $4$0.20$1 / $5Standard
Sonnet 4.61M$3 / $15$3.75 / $6$0.30$1.50 / $7.50Standard
Sonnet 4.5*200K$3 / $15$3.75 / $6$0.30$1.50 / $7.50Standard
Haiku 5.51M$0.10 / $0.50 up to 100K input; $0.50 / $2.50 above$0.125 / $0.20 up to 100K; $0.625 / $1 above$0.01 up to 100K; $0.05 above$0.05 / $0.25 up to 100K; $0.25 / $1.25 aboveHigher rates above 100K input
Haiku 4.5200K$1 / $5$1.25 / $2$0.10$0.50 / $2.50Standard

“1M” means a one-million-token context window, not a million input tokens at one price tier. Anthropic says the current one-million-token models use standard rates at long context, except Haiku 5.5: prompts over 100,000 input tokens use the higher prices shown above.

Older active models such as Opus 4.5 and Haiku 4.5 have 200,000-token windows, as does the deprecated Sonnet 4.5. See Anthropic’s 2026 context-window reference for the model-by-model list.

Sonnet 4.5 remains callable while deprecated and is scheduled to retire November 30, 2026, so do not start a new integration on it.

How much does the Claude API cost for a coding turn?

For a simple Claude API pricing calculator, count input and output separately: input tokens ÷ 1,000,000 × input rate + output tokens ÷ 1,000,000 × output rate. I used 20,000 input tokens and 2,000 output tokens so the result is comparable across the four models Anthropic puts in its 2026 model overview.

ModelFresh turnWarm-cache turn100-turn session with a warm 1h cache
Haiku 5.5$0.003000$0.001380$0.141420
Sonnet 5.5$0.060000$0.025800$2.650200
Opus 5.5$0.120000$0.051600$5.300400
Fable 5.1$0.300000$0.124500$12.805500

The warm-cache turn assumes 18,000 input tokens are cache hits and 2,000 are new input; the output remains 2,000 tokens. For the 100-turn column, the first request writes that same 18,000-token prefix with the one-hour TTL, then the next 99 turns read it. Every turn adds 2,000 new input and produces 2,000 output tokens. The cache stays warm throughout the modeled session; tools, retries and other tokens are excluded.

Anthropic’s default cache lifetime is five minutes, and reuse refreshes an entry without an additional refresh charge. A real session that outlasts its cache window or adds more prompt tokens will cost more.

The cache changes the input bill most when a repeated prefix is large: for this turn, a warm cache cuts the modeled total by 54% on Haiku, 57% on Sonnet, 57% on Opus, and 59% on Fable. The Claude cache TTL guide explains when the one-hour write pays off; Prompt Caching Explained covers cache setup and break-even math.

If the work can finish asynchronously, Anthropic’s 2026 Batch processing docs say the Claude batch API (Message Batches) charges half the standard input and output prices. It suits bulk jobs and evaluations, not an interactive coding turn; most batches finish in under an hour. The LLM API pricing comparison compares this kind of workload math across providers.

Which Claude model should you pick for coding or an agent?

Start with the least expensive model that passes your own task evals, then move up only when the quality gap costs more than the added tokens. Anthropic’s 2026 model overview recommends Opus 5.5 for most workloads, Fable 5.1 for demanding reasoning or long-horizon agent work when Opus 5.5 still falls short, Sonnet 5.5 for a speed/intelligence balance, and Haiku 5.5 for high-volume, latency-sensitive classification, extraction and routing.

PickWhen it fitsPrice for the example turn
Haiku 5.5Routing, extraction, classification, or many short calls where latency and unit cost lead$0.003 fresh
Sonnet 5.5General coding turns and mixed work where you want the balanced default$0.06 fresh
Opus 5.5Long-running coding or knowledge work; use when your evals justify 2× Sonnet’s token rates$0.12 fresh
Fable 5.1Difficult reasoning or long agent runs that fail your Opus evals; the highest modeled turn cost here$0.30 fresh

A higher token rate does not prove a model is better for your repository. Run the same representative tasks on the candidates, record pass rate and token usage, then compare cost per accepted result. For deeper cost arithmetic across vendors, see the LLM API pricing comparison.

Which Claude models are retiring?

Anthropic distinguishes deprecated models, which still run but are no longer recommended, from retired models, whose requests fail. Its 2026 model deprecations table covers Anthropic-operated API endpoints; partner-operated platforms can set different schedules.

API modelStatus checked Nov 3, 2026Deprecation dateRetirement date
claude-sonnet-4-5-20250929DeprecatedSep 30, 2026Nov 30, 2026
claude-opus-4-1-20250805RetiredJun 5, 2026Aug 5, 2026
claude-opus-4-20250514RetiredApr 14, 2026Jun 15, 2026
claude-sonnet-4-20250514RetiredApr 14, 2026Jun 15, 2026
claude-3-7-sonnet-20250219RetiredOct 28, 2025Feb 19, 2026
claude-3-5-haiku-20241022RetiredDec 19, 2025Feb 19, 2026
claude-3-haiku-20240307RetiredFeb 19, 2026Apr 20, 2026

If you still call a deprecated ID, migrate and test before its retirement date. Anthropic says you can export the Console Usage page to find usage by API key and model.

Is Claude API pricing the same as Claude Pro or Max?

No. The API is usage-billed through Console credits or an invoicing arrangement; Claude subscriptions are separate products. Anthropic’s 2026 API billing guide says API calls are charged by successful request usage, and subscription credits have their own restrictions. If you mean Claude Code access through a consumer plan rather than API metering, see Is Claude Code Free?.

I build Octomind, so I have a stake in agent tooling. This guide uses Anthropic’s rates and a stated token model; use your own usage logs to budget a real codebase. Start with Sonnet 5.5 for a representative coding eval, route simple high-volume steps to Haiku 5.5, and pay for Opus or Fable only when they improve your measured result.