Cheapest per task
Price per token is not price per task
A cheap model that needs three attempts costs more than a mid model that gets it right once. The cheapest model for coding guide compares them by work done.
Short answer
As of October 29, 2026, the cheapest capable API models are Claude Haiku 5.5 and GPT-6 Luna, both at $0.10 per million input tokens and $0.50 per million output tokens. The mid tier, Claude Sonnet 5.5, GPT-6.1 Sol, and Gemini 4 Argon, costs $2 / $10. Frontier models run from Claude Opus 5.5 at $4 / $20 up to Claude Fable 5.1 and GPT-6 Astra at $10 / $50. Grok 4.7 is the cheapest frontier-class model on output, at $6.
Standard API list prices in USD, short-context rate, no batch discount. The last column is the uncached cost of 100 agentic coding turns (16,000 tokens in, 1,500 out), roughly an afternoon in Claude Code or Codex.
| Model | Tier | Input | Output | Cached input | 100 coding turns |
|---|---|---|---|---|---|
| Claude Fable 5.1Anthropic | Frontier | $10 | $50 | $0.25 | $23.50 |
| Claude Opus 5.5AnthropicFast mode costs $8 / $40. | Frontier | $4 | $20 | $0.20 | $9.40 |
| Claude Sonnet 5.5Anthropic | Mid | $2 | $10 | $0.10 | $4.70 |
| Claude Haiku 5.5AnthropicPrompts over 100K tokens (cache reads count) bill at 5x: $0.50 / $2.50. | Small | $0.10 | $0.50 | $0.01 | $0.24 |
| GPT-6 AstraOpenAI | Frontier | $10 | $50 | $1 | $23.50 |
| GPT-6.1 SolOpenAI | Mid | $2 | $10 | $0.10 | $4.70 |
| GPT-6.1 TerraOpenAI | Small | $1 | $5 | $0.05 | $2.35 |
| GPT-6 LunaOpenAI | Small | $0.10 | $0.50 | $0.01 | $0.24 |
| Gemini 4 ArgonGoogleLaunch price through Nov 30, 2026; $4 / $20 from Dec 1. | Frontier | $2 | $10 | $0.10 | $4.70 |
| Gemini 3.8 FlashGooglePrice doubles to $1.50 / $7.50 on Jan 1, 2027. | Small | $0.75 | $3.75 | $0.075 | $1.76 |
| Gemini 3.5 Flash-LiteGoogle | Small | $0.30 | $2.50 | $0.03 | $0.85 |
| Grok 4.7xAIPrompts of 200K tokens or more bill at 2x for the whole request. | Frontier | $2 | $6 | $0.50 | $4.10 |
| Grok Build 0.1xAI | Small | $1 | $2 | $0.20 | $1.90 |
| DeepSeek V4 ProDeepSeekPeak rate; off-peak hours are 50% off. | Mid | $1.32 | $3.96 | $0.044 | $2.71 |
| DeepSeek FlashDeepSeekPeak rate; off-peak hours are 50% off. | Small | $0.30 | $1.20 | $0.006 | $0.66 |
Promotional rates that expire and long-prompt surcharges change what the same workload costs. These are the ones in effect right now.
Cheapest per task
A cheap model that needs three attempts costs more than a mid model that gets it right once. The cheapest model for coding guide compares them by work done.
Route the work
Planning on a frontier model and execution on a cheap one is the biggest single saving. See model routing for the method and the math.
Subscriptions
Claude Pro and Max bill a flat fee with usage limits, not per token. Whether that beats the API depends on your volume; see is Claude Max worth it.
Short answers, computed from the same dated table as above.
Claude Haiku 5.5 and GPT-6 Luna tie at $0.10 / $0.50 per million tokens as of October 29, 2026. DeepSeek Flash is cheaper on cached input but costs more per output token. For coding agents, check the prompt length first: Claude Haiku 5.5 switches to $0.50 / $2.50 once a prompt passes 100,000 tokens.
Claude Haiku 5.5 costs $0.10 / $0.50 per million input and output tokens, Claude Sonnet 5.5 $2 / $10, Claude Opus 5.5 $4 / $20, and Claude Fable 5.1 $10 / $50. Cache hits cost a fraction of input (0.05x on Opus 5.5 and Sonnet 5.5), and the Batch API halves every rate.
Usually not for writing code. Claude Opus 5.5 costs $4 / $20 against Claude Sonnet 5.5's $2 / $10, and Anthropic's own launch numbers put Sonnet 5.5 level with or ahead of Opus 5.5 on agentic coding benchmarks. Keep Opus for planning and hard debugging, and let Sonnet or Haiku do the execution.
It depends mostly on context size. A typical agentic turn sends about 16,000 input tokens and gets 1,500 back. Without caching, 100 such turns cost $4.70 on Claude Sonnet 5.5 and $9.40 on Claude Opus 5.5. Prompt caching usually cuts the input share by most of that.
Price tables tell you the rate; your bill depends on how many tokens your tools really burn. Tokens 4 Breakfast reads the usage your tools already record on your Mac and shows real spend by model and project in the menu bar, so you can see whether switching models moved the number.
Sources
Every rate above was read from the provider's own pricing page on October 29, 2026 (DeepSeek on October 23, 2026). Prices change; check the source before a purchasing decision. The same rates power the cost math inside Tokens 4 Breakfast.