Skip to content
c17 .ioJoin list

Compare / LLM APIs

Hosted LLM API pricing, normalized

Uncached list rates, checked 18 Oct 2026. The cheapest published cheap/fast model is Groq Llama 3.1 8B Instant at $0.05 / $0.08 per 1M input/output. Among flagships, Mistral Large 4 is $0.68 / $2.09 on the listed sale (regular $1.36 / $4.18), DeepSeek V4 Pro peak cache-miss is $1.32 / $3.96, and Groq Llama 3.3 70B is $0.59 / $0.79. Frontier APIs cost more: grok-4.7 $2 / $6, Claude Sonnet 5.5 and Gemini 4 Argon $2 / $10, GPT-5.2 $1.75 / $14. OpenRouter does not have its own model rates — it passes through providers (plus 5.5% on credits), so those cells are em dashes.

Prices from each provider's official pricing page, checked 18 Oct 2026. USD, excluding tax. Headline cells are uncached list rates. Cached-input, batch, off-peak, and sale-regular figures are in the cell tooltips, not the headline. Blended = (3 × input + 1 × output) ÷ 4, a 3:1 input:output mix. "Not published" means the page did not list a first-party rate. Estimates, not guarantees.

Start on Railway

Price per 1,000,000 tokens, uncached list rates

OpenAI
Details
Cheap / fast model
GPT-5-mini $0.25 / $2.00 — per 1M input/output. Cached input $0.025. Batch 50% off.
Flagship model
GPT-5.2
Cheap / fast model
GPT-5-mini
Prompt cap on that rate
Standard list; longer-context SKUs are separate rows on the pricing page
Cached input / batch
Cached input 0.1×; Batch 50% off (tooltip only)
Notes
OpenAI API
$1.75 GPT-5.2 uncached. Cached input $0.175. Batch 50% off.$14.00 GPT-5.2. Batch 50% off ($7).$4.81 (3 × $1.75 + $14.00) ÷ 4 = $4.8125. Cached/batch in the input and output tooltips.GPT-5-mini $0.25 / $2.00 per 1M input/output. Cached input $0.025. Batch 50% off.
Anthropic
Details
Cheap / fast model
Haiku 5.5 $0.10 / $0.50 — per 1M, prompts ≤100k. Above 100k: $0.20 / $2.50. Cache-hit and Batch 50% off in the Anthropic table.
Flagship model
Claude Sonnet 5.5
Cheap / fast model
Claude Haiku 5.5
Prompt cap on that rate
Sonnet list is ≤200k prompt tokens; Haiku cheap rate is ≤100k
Cached input / batch
Prompt-cache hits and Batch 50% off (tooltip only)
Notes
Anthropic API / Amazon Bedrock / Google Vertex (first-party rates here)
$2.00 Sonnet 5.5 uncached, prompts ≤200k. Cache-write 1.25×; cache-hit 0.1×. Batch 50% off.$10.00 Sonnet 5.5. Batch 50% off ($5).$4.00 (3 × $2.00 + $10.00) ÷ 4. Cache/batch in the input and output tooltips.Haiku 5.5 $0.10 / $0.50 per 1M, prompts ≤100k. Above 100k: $0.20 / $2.50. Cache-hit and Batch 50% off in the Anthropic table.
Google Gemini
Details
Cheap / fast model
3.5 Flash-Lite $0.30 / $2.50 — per 1M input/output. Batch 50% off.
Flagship model
Gemini 4 Argon
Cheap / fast model
Gemini 3.5 Flash-Lite
Prompt cap on that rate
Argon promo through 30 Nov 2026, then $4 / $20
Cached input / batch
Batch 50% off; cached input cheaper (tooltip only)
Notes
Gemini Developer API (ai.google.dev)
$2.00 Gemini 4 Argon through 30 Nov 2026. Then $4.00. Batch 50% off. Cached input is cheaper.$10.00 Gemini 4 Argon through 30 Nov 2026. Then $20.00. Batch 50% off.$4.00 (3 × $2.00 + $10.00) ÷ 4 through 30 Nov 2026. After that (3 × $4 + $20) ÷ 4 = $8.00.3.5 Flash-Lite $0.30 / $2.50 per 1M input/output. Batch 50% off.
xAI
Details
Cheap / fast model
grok-4.20 $1.25 / $2.50 — per 1M input/output. Cached input cheaper.
Flagship model
grok-4.7
Cheap / fast model
grok-4.20
Prompt cap on that rate
Flagship list is <200k prompt tokens; 200k+ is 2×
Cached input / batch
Cached input cheaper (tooltip only)
Notes
xAI API
$2.00 grok-4.7, prompts <200k. Above 200k: $4.00. Cached input is cheaper.$6.00 grok-4.7, prompts <200k. Above 200k: $12.00.$3.00 (3 × $2.00 + $6.00) ÷ 4 below 200k. Above 200k: (3 × $4 + $12) ÷ 4 = $6.00.grok-4.20 $1.25 / $2.50 per 1M input/output. Cached input cheaper.
Mistral AI
Details
Cheap / fast model
Small 4 $0.15 / $0.60 — per 1M input/output. Cached input 0.1×.
Flagship model
Mistral Large 4
Cheap / fast model
Mistral Small 4
Prompt cap on that rate
Sale is the listed current rate; regular is in the tooltip
Cached input / batch
Cached input 0.1× (tooltip only)
Notes
Mistral API (La Plateforme)
$0.68 Large 4 listed sale. Regular $1.36. Cached input 0.1× ($0.136 regular / $0.068 sale).$2.09 Large 4 listed sale. Regular $4.18.$1.03 Sale (3 × $0.68 + $2.09) ÷ 4 = $1.0325. Regular blended $2.07.Small 4 $0.15 / $0.60 per 1M input/output. Cached input 0.1×.
DeepSeek
Details
Cheap / fast model
Flash $0.30 / $1.20 — per 1M peak cache-miss. Off-peak half. Cache-hit input cheaper.
Flagship model
DeepSeek V4 Pro
Cheap / fast model
DeepSeek Flash
Prompt cap on that rate
Peak cache-miss is the conservative headline; off-peak is half
Cached input / batch
Cache-hit and off-peak in the tooltip, not the cell
Notes
DeepSeek API
$1.32 V4 Pro peak, cache-miss. Cache-hit is much cheaper. Off-peak is half.$3.96 V4 Pro peak. Off-peak is half ($1.98).$1.98 (3 × $1.32 + $3.96) ÷ 4 peak cache-miss. Off-peak half. Cache-hit omitted from the headline.Flash $0.30 / $1.20 per 1M peak cache-miss. Off-peak half. Cache-hit input cheaper.
Groq
Details
Cheap / fast model
Llama 3.1 8B Instant $0.05 / $0.08 — per 1M input/output. GPT OSS 120B is $0.15 / $0.60.
Flagship model
Llama 3.3 70B
Cheap / fast model
Llama 3.1 8B Instant
Prompt cap on that rate
On-demand list; reserved/compound SKUs are separate
Cached input / batch
Not used as a headline discount
Notes
GroqCloud
$0.59 Llama 3.3 70B on-demand. Not a frontier model — a fast hosted open weight.$0.79 Llama 3.3 70B on-demand.$0.64 (3 × $0.59 + $0.79) ÷ 4 = $0.64.Llama 3.1 8B Instant $0.05 / $0.08 per 1M input/output. GPT OSS 120B is $0.15 / $0.60.
Together AI
Details
Cheap / fast model
GLM-5.3 Flash $0.15 / $0.50 — per 1M input/output. Cached input cheaper.
Flagship model
GLM-5.3
Cheap / fast model
GLM-5.3 Flash
Prompt cap on that rate
Serverless list; dedicated endpoints are a different product
Cached input / batch
Cached input and Batch up to 50% off (tooltip only)
Notes
Together serverless
$1.40 GLM-5.3 serverless. Cached input cheaper. Batch up to 50% off.$4.40 GLM-5.3 serverless. Batch up to 50% off.$2.15 (3 × $1.40 + $4.40) ÷ 4. Cache/batch in the input and output tooltips.GLM-5.3 Flash $0.15 / $0.50 per 1M input/output. Cached input cheaper.
Fireworks AI
Details
Cheap / fast model
GLM 5.3 Flash $0.15 / $0.50 — per 1M input/output. Cached input cheaper. Batch 50% off.
Flagship model
GLM 5.3
Cheap / fast model
GLM 5.3 Flash
Prompt cap on that rate
Serverless list; on-demand deployments are a different product
Cached input / batch
Cached input cheaper; Batch 50% off (tooltip only)
Notes
Fireworks serverless
$1.40 GLM 5.3 serverless. Cached input cheaper. Batch 50% off.$4.40 GLM 5.3 serverless. Batch 50% off.$2.15 (3 × $1.40 + $4.40) ÷ 4. Cache/batch in the input and output tooltips.GLM 5.3 Flash $0.15 / $0.50 per 1M input/output. Cached input cheaper. Batch 50% off.
OpenRouter
Details
Cheap / fast model
Pass-through — Same model can route to several hosts. Pay-as-you-go credits add 5.5% on top of the provider price.
Flagship model
Whatever model you pick
Cheap / fast model
Whatever model you pick
Prompt cap on that rate
No first-party list rate — omitted rather than copied
Cached input / batch
Some listed models are $0; that is the host, not OpenRouter
Notes
Router in front of many providers
— Pass-through of each provider's price, not a first-party model table. Credits add 5.5%.— Pass-through of each provider's price, not a first-party model table. Credits add 5.5%.— Pass-through; no first-party blended rate to publish.Pass-through Same model can route to several hosts. Pay-as-you-go credits add 5.5% on top of the provider price.

What you actually get

OpenAI GPT-5.2 GPT-5-mini Standard list; longer-context SKUs are separate rows on the pricing page Cached input 0.1×; Batch 50% off (tooltip only) OpenAI API
Anthropic Claude Sonnet 5.5 Claude Haiku 5.5 Sonnet list is ≤200k prompt tokens; Haiku cheap rate is ≤100k Prompt-cache hits and Batch 50% off (tooltip only) Anthropic API / Amazon Bedrock / Google Vertex (first-party rates here)
Google Gemini Gemini 4 Argon Gemini 3.5 Flash-Lite Argon promo through 30 Nov 2026, then $4 / $20 Batch 50% off; cached input cheaper (tooltip only) Gemini Developer API (ai.google.dev)
xAI grok-4.7 grok-4.20 Flagship list is <200k prompt tokens; 200k+ is 2× Cached input cheaper (tooltip only) xAI API
Mistral AI Mistral Large 4 Mistral Small 4 Sale is the listed current rate; regular is in the tooltip Cached input 0.1× (tooltip only) Mistral API (La Plateforme)
DeepSeek DeepSeek V4 Pro DeepSeek Flash Peak cache-miss is the conservative headline; off-peak is half Cache-hit and off-peak in the tooltip, not the cell DeepSeek API
Groq Llama 3.3 70B Llama 3.1 8B Instant On-demand list; reserved/compound SKUs are separate Not used as a headline discount GroqCloud
Together AI GLM-5.3 GLM-5.3 Flash Serverless list; dedicated endpoints are a different product Cached input and Batch up to 50% off (tooltip only) Together serverless
Fireworks AI GLM 5.3 GLM 5.3 Flash Serverless list; on-demand deployments are a different product Cached input cheaper; Batch 50% off (tooltip only) Fireworks serverless
OpenRouter Whatever model you pick Whatever model you pick No first-party list rate — omitted rather than copied Some listed models are $0; that is the host, not OpenRouter Router in front of many providers

Best for

  1. OpenAI

    The default frontier API when you want GPT-5.2 and will pay the output rate.

  2. Anthropic

    Claude quality at a published $2 / $10 Sonnet rate, or Haiku at $0.10 / $0.50 for cheap classification.

  3. Google Gemini

    Gemini 4 Argon at the current $2 / $10 promo, or Flash-Lite when cheap/fast Google is enough.

  4. xAI

    Grok when you want a $2 / $6 flagship (cheaper output than Sonnet or GPT-5.2).

  5. Mistral AI

    The cheapest published frontier-class flagship on the current Large 4 sale.

  6. DeepSeek

    A cheap capable flagship when you will miss cache at peak and still beat Sonnet on price.

  7. Groq

    The cheapest published tokens when an 8B or 70B Llama on an LPU is enough.

  8. Together AI

    Hosted GLM-5.3 when you want an open model without running a GPU yourself.

  9. Fireworks AI

    The same GLM 5.3 serverless rates as Together, on Fireworks' API.

  10. OpenRouter

    One key in front of many hosts, knowing the cell cannot show a single official rate.

A $0.05/1M cheap model vs a $2/$10 frontier API vs a pass-through router

These pages compare hosted inference APIs, not self-hosted vLLM. One row is one provider. The headline number is the flagship's uncached list rate. A representative cheap or fast sibling sits in the last column as text so it does not mix into the flagship color scale. Cached-input hits, Batch (often 50% off), DeepSeek off-peak (half), Mistral's listed sale vs regular, and Gemini 4 Argon's post-30 Nov 2026 rate live in tooltips.

Blended 3:1 is (3 × input + 1 × output) ÷ 4. That is a common chat mix — more prompt than completion — stated on every page that uses it. A 1:1 mix would move the blended number toward the output rate. Worked examples use the same 3:1 ratio at three monthly volumes.

OpenRouter is a router, not a model host. It charges the provider's price and adds 5.5% when you pay with account credits. Those cells are em dashes rather than a copied vendor rate, because the official page does not publish a first-party model table of its own.

What would a real project cost?

Estimates, not guarantees. Built from the published rates above (checked 18 Oct 2026); check each provider's current pricing before you commit. Tax is not included. Numbers marked unverified or not published were left out rather than guessed.

OpenAI $1.83 GPT-5-mini$128.38 GPT-5.2 uncached$1,283.80 GPT-5.2 uncached
Anthropic $0.53 Haiku 5.5 ≤100k$106.70 Sonnet 5.5$1,067.00 Sonnet 5.5
Google Gemini $2.27 3.5 Flash-Lite$106.70 Gemini 4 Argon promo$1,067.00 Gemini 4 Argon promo
xAI $4.17 grok-4.20$80.02 grok-4.7 <200k$800.20 grok-4.7 <200k
Mistral AI $0.70 Small 4$27.54 Large 4 sale; regular ~$55.08$275.40 Large 4 sale; regular ~$550.80
DeepSeek $1.40 Flash peak cache-miss$52.81 V4 Pro peak cache-miss$528.13 V4 Pro peak cache-miss
Groq $0.15 Llama 3.1 8B Instant$17.07 Llama 3.3 70B$170.69 Llama 3.3 70B
Together AI $0.63 GLM-5.3 Flash$57.35 GLM-5.3$573.48 GLM-5.3
Fireworks AI $0.63 GLM 5.3 Flash$57.35 GLM 5.3$573.48 GLM 5.3
OpenRouter — Pass-through; no first-party rate— Pass-through; no first-party rate— Pass-through; no first-party rate
  1. Small: hobby chatbot

    Try first: Groq Llama 3.1 8B Instant at about $0.15 — cheapest published cheap-model bill at this volume.

    Runner-up: Anthropic Haiku 5.5 at about $0.53, or Mistral Small 4 at about $0.70, when you want a provider model instead of an 8B Llama.

    Avoid: OpenRouter as a priced row (pass-through, omitted) and frontier flagships for a hobby bot — GPT-5.2 at this volume on the cheap SKU is already about $1.83, and the flagship would be about $12.84.

  2. Medium: production SaaS feature

    Try first: Mistral Large 4 at about $27.54 on the listed sale — cheapest published frontier-class flagship at this volume (regular would be about $55.08).

    Runner-up: DeepSeek V4 Pro peak cache-miss at about $52.81, or Groq Llama 3.3 70B at about $17.07 if a fast 70B open weight is enough and you do not need a frontier model.

    Avoid: Paying GPT-5.2 ($128.38) or Sonnet/Argon ($106.70) for this volume when Mistral Large 4 or DeepSeek Pro still fit, and treating OpenRouter as a priced platform.

  3. Large: high-volume pipeline

    Try first: Mistral Large 4 at about $275.40 on the listed sale (regular about $550.80).

    Runner-up: DeepSeek V4 Pro peak cache-miss at about $528.13, or Groq Llama 3.3 70B at about $170.69 if the 70B quality is enough. Batch/cache (tooltips) can cut these further.

    Avoid: GPT-5.2 at about $1,283.80 uncached, and OpenRouter as a first-party price. Hyperscaler model gardens are not extra rows — use the first-party pages above.

Show the math

Project — Small: hobby chatbot
2,000,000 input tokens and 667,000 output tokens a month on the cheap/fast model (3:1). A personal bot, light RAG, or weekend prototype. Tax not included. Cheap 3:1: OpenAI mini 2×$0.25 + 0.667×$2.00 = $1.83. Haiku 2×$0.10 + 0.667×$0.50 = $0.53. Flash-Lite 2×$0.30 + 0.667×$2.50 = $2.27. grok-4.20 2×$1.25 + 0.667×$2.50 = $4.17. Mistral Small 2×$0.15 + 0.667×$0.60 = $0.70. DeepSeek Flash 2×$0.30 + 0.667×$1.20 = $1.40. Groq 8B 2×$0.05 + 0.667×$0.08 = $0.15. GLM Flash 2×$0.15 + 0.667×$0.50 = $0.63. OpenRouter omitted.
Project — Medium: production SaaS feature
20,000,000 input tokens and 6,670,000 output tokens a month on the flagship (3:1). One product feature: support replies, an agent, or structured extraction. Uncached list rates. Tax not included. Flagship 3:1: GPT-5.2 20×$1.75 + 6.67×$14.00 = $128.38. Sonnet/Argon 20×$2.00 + 6.67×$10.00 = $106.70. grok-4.7 20×$2.00 + 6.67×$6.00 = $80.02. Mistral Large sale 20×$0.68 + 6.67×$2.09 = $27.54. DeepSeek Pro 20×$1.32 + 6.67×$3.96 = $52.81. Groq 70B 20×$0.59 + 6.67×$0.79 = $17.07. GLM 20×$1.40 + 6.67×$4.40 = $57.35. OpenRouter omitted.
Project — Large: high-volume pipeline
200,000,000 input tokens and 66,700,000 output tokens a month on the flagship (3:1). A batch or streaming pipeline. Headline still uses uncached list rates — real bills drop if you hit cache or Batch. Tax not included. 10× the medium flagship bills: GPT-5.2 $1,283.80. Sonnet/Argon $1,067.00. grok-4.7 $800.20. Mistral Large sale $275.40. DeepSeek Pro $528.13. Groq 70B $170.69. GLM $573.48. OpenRouter omitted.
OpenAI
Official: GPT-5.2 $1.75 / $14 per 1M; cached input $0.175; Batch 50% off. GPT-5-mini $0.25 / $2.00; cached $0.025. Blended 3:1 = (3×1.75 + 14) ÷ 4 = $4.81. Source: https://developers.openai.com/api/docs/pricing (checked 18 Oct 2026)
Anthropic
Official: Sonnet 5.5 $2 / $10 per 1M (≤200k). Haiku 5.5 $0.10 / $0.50 (≤100k); $0.20 / $2.50 above. Cache-write 1.25×, cache-hit 0.1×, Batch 50% off. Blended 3:1 = $4.00. Source: https://platform.claude.com/docs/en/about-claude/pricing (checked 18 Oct 2026)
Google Gemini
Official: Gemini 4 Argon $2 / $10 per 1M through 30 Nov 2026, then $4 / $20. Gemini 3.5 Flash-Lite $0.30 / $2.50. Batch 50% off. Blended 3:1 on the promo = $4.00. Source: https://ai.google.dev/gemini-api/docs/pricing (checked 18 Oct 2026)
xAI
Official: grok-4.7 $2 / $6 per 1M below 200k; $4 / $12 above. grok-4.20 $1.25 / $2.50. Cached input cheaper. Blended 3:1 below 200k = $3.00. Source: https://docs.x.ai/developers/pricing (checked 18 Oct 2026)
Mistral AI
Official: Large 4 $0.68 / $2.09 sale (regular $1.36 / $4.18). Small 4 $0.15 / $0.60. Cached input 0.1×. Blended 3:1 on sale = $1.03. Source: https://docs.mistral.ai/inference/pricing (checked 18 Oct 2026)
DeepSeek
Official: V4 Pro peak cache-miss $1.32 / $3.96 per 1M; Flash $0.30 / $1.20. Off-peak is half. Cache-hit input is much cheaper — tooltip only. Blended 3:1 peak miss = $1.98. Source: https://api-docs.deepseek.com/quick_start/pricing/ (checked 18 Oct 2026)
Groq
Official on-demand: Llama 3.3 70B $0.59 / $0.79 per 1M. Llama 3.1 8B Instant $0.05 / $0.08. GPT OSS 120B $0.15 / $0.60. Blended 3:1 on 70B = $0.64. Source: https://home.cloud.groq.io/pricing (checked 18 Oct 2026)
Together AI
Official serverless: GLM-5.3 $1.40 / $4.40 per 1M. GLM-5.3 Flash $0.15 / $0.50. Cached input cheaper; Batch up to 50% off. Blended 3:1 = $2.15. Source: https://www.together.ai/pricing (checked 18 Oct 2026)
Fireworks AI
Official serverless: GLM 5.3 $1.40 / $4.40 per 1M. GLM 5.3 Flash $0.15 / $0.50. Cached input cheaper; Batch 50% off. Blended 3:1 = $2.15. Source: https://docs.fireworks.ai/serverless/pricing (checked 18 Oct 2026)
OpenRouter
Official: OpenRouter passes through the selected provider's price. Account credits add 5.5%. No first-party per-model table is treated as a c17 headline — cells are em dashes. Source: https://openrouter.ai/pricing (checked 18 Oct 2026)

FAQ

What is the cheapest hosted LLM API?
On published cheap/fast models, Groq Llama 3.1 8B Instant is $0.05 / $0.08 per 1M. Haiku 5.5 is $0.10 / $0.50. Among flagships, Groq Llama 3.3 70B is $0.59 / $0.79 and Mistral Large 4 is $0.68 / $2.09 on the listed sale. Frontier APIs start around $2 / $6–$14.
What does blended 3:1 mean?
Three input tokens for every output token. The column is (3 × input + 1 × output) ÷ 4, in USD per 1 million tokens. The worked examples use the same ratio at 2M / 20M / 200M input tokens.
Why are cached and batch prices in the tooltip?
Those rates only apply when you hit cache or submit Batch jobs. The headline is the uncached list rate you pay on a normal request. Hover or tap the cell for cache, Batch, off-peak, and sale-regular figures.
Why is OpenRouter an em dash?
OpenRouter passes through each provider's price and adds 5.5% on credits. It is not a first-party model host, so there is no official OpenRouter $/1M to put in the cell.
Is Groq comparable to GPT-5.2 or Sonnet?
No. Groq hosts fast open weights (Llama 8B/70B, GPT OSS). It wins on published $/1M and latency. It is not a frontier-model substitute. The try-first picks use Groq for the hobby bot and Mistral Large 4 for production flagship volume.
What would a real project cost?
Estimates from published uncached rates: a hobby bot at 2M+667k cheap tokens is about $0.15 on Groq 8B, $0.53 on Haiku, $0.70 on Mistral Small. A production feature at 20M+6.67M flagship tokens is about $28 on Mistral Large 4 (sale), $53 on DeepSeek Pro, $107 on Sonnet or Gemini 4 Argon, $128 on GPT-5.2. Ten times that volume is ten times those bills.

Related pages

Stack of the Week

Get one stack a week that replaces a SaaS bill.