Cost · July 4, 2026 · 7 min read

LLM API Pricing in 2026: The Complete Cost Comparison

What every major LLM API actually costs in 2026, frontier and open weight, plus the batch and caching discounts that cut the real bill in half.

LLM API pricing in 2026 splits into two very different markets. Frontier models (GPT-5.5, Claude Opus 4.7, Gemini 2.5 Pro) are priced by their makers and cost dollars per million tokens. Open-weight models (Llama, DeepSeek, Qwen, gpt-oss) are served by a dozen competing hosts and cost cents. Most teams overpay because they price everything at frontier rates when 80 percent of their workload would run fine on an open model at 3 percent of the cost.

This guide gives you the full map: what the major models cost right now, the discounts that stack on top, and how to route work so the bill tracks the difficulty of the task, not your default habits.

How LLM pricing works

Every API bills per token, split into input (your prompt) and output (the model's reply). Output tokens are the expensive side, usually 3 to 5 times the input rate, and reasoning models can burn thousands of hidden thinking tokens per request that bill as output. That is why our live rankings track output-token prices: they dominate real bills.

Three price levers exist on almost every provider:

  • List price: what you pay per token by default.
  • Batch: submit jobs asynchronously (results within 24 hours) for a flat 50 percent discount on both OpenAI and Anthropic, and similar on Google.
  • Prompt caching: repeated prompt prefixes (system prompts, few-shot examples, long documents) bill at a fraction of the input rate on every major provider.

If your workload has any tolerance for latency, batch alone halves the bill. We cover the mechanics in prompt caching and batch discounts.

Frontier model pricing

Per 1M output tokens, list price versus batch, as of our July 2026 check:

ModelListBatch
GPT-5.530 dollars15 dollars
Claude Opus 4.725 dollars12.50 dollars
GPT-5.415 dollars7.50 dollars
Claude Sonnet 4.615 dollars7.50 dollars
Gemini 2.5 Pro10 dollars5 dollars
Claude Haiku 4.55 dollars2.50 dollars
GPT-5.4 mini4.50 dollars2.25 dollars
Gemini 2.5 Flash2.50 dollars1.25 dollars

Two patterns worth noticing. First, every vendor now ships a cheap tier (Haiku, mini, Flash) at 10 to 20 percent of its flagship price, and those tiers handle classification, extraction, and routine drafting well. Second, the spread between vendors at the same capability tier is real money: a flagship-only workload moved from GPT-5.5 to Gemini 2.5 Pro is a two-thirds cut before any other optimization.

Live per-model tables with resellers included: GPT-5.5, Claude Opus 4.7, Gemini 2.5 Pro.

Open-weight model pricing

Open models are where the market actually competes, because anyone with GPUs can serve them. Cheapest tracked endpoint per 1M output tokens right now:

ModelFromCheapest host
Mistral Nemo0.04 dollarsDeepInfra
Llama 3.1 8B0.05 dollarsDeepInfra
gpt-oss-20b0.14 dollarsDeepInfra
gpt-oss-120b0.17 dollarsDeepInfra
Llama 4 Scout0.30 dollarsDeepInfra
Llama 3.3 70B0.32 dollarsOpenRouter
DeepSeek-V30.90 dollarsDeepInfra
Kimi K22.00 dollarsDeepInfra
DeepSeek-R12.15 dollarsDeepInfra

The same model can differ 2 to 4x between hosts, and prices move monthly. Groq, Cerebras, Together, Fireworks, Novita, Nebius, and SambaNova all fight for this traffic, which is exactly why we re-check every endpoint weekly in the rankings rather than hardcoding numbers in guides.

A 120B-class open model at 17 cents per million output tokens is not a toy. For summarization, extraction, internal tools, and most agent scaffolding, it is functionally interchangeable with models that cost 100x more.

What a realistic bill looks like

Take a product doing 50M input and 10M output tokens a month:

  • Everything on GPT-5.5 list price: roughly 425 dollars.
  • Same workload on Gemini 2.5 Flash: about 40 dollars.
  • Routed: 80 percent to gpt-oss-120b, 15 percent to a Flash-tier model, 5 percent to a flagship with batch: under 25 dollars.

The routing version is not exotic. It is one conditional in your dispatch code plus a router like OpenRouter when you want one key across many hosts.

How to cut the bill, in order

  1. Route by difficulty. Default to a cheap open model; escalate to a frontier model only when quality checks fail.
  2. Turn on batch for anything asynchronous. Flat 50 percent off, no code redesign beyond queuing.
  3. Cache your prompt prefix. Long system prompts and shared context should never bill at full input rate twice.
  4. Re-shop your open-model hosts quarterly. The cheapest endpoint for a given model changes; switching is usually a base-URL swap.
  5. Claim credits before you pay cash. Most providers hand new accounts free usage, and startup programs go much further. Start with free AI API credits and the catalog.

Bottom line

Frontier output tokens cost dollars; open-weight output tokens cost cents; batch halves either. Price the task, not the vendor: route routine work to open models, reserve flagships for the few calls that need them, and check the live rankings before committing volume anywhere, because these numbers move every month.

Related reading: the cheapest way to run LLMs, prompt caching and batch discounts, OpenRouter vs direct APIs.

Frequently asked questions

What is the cheapest LLM API in 2026?

Per output token, small open-weight models are cheapest: Mistral Nemo and Llama 3.1 8B run around 4 to 5 cents per 1M output tokens on discount hosts like DeepInfra. Among frontier vendors, Gemini 2.5 Flash and GPT-5.4 mini are the value tiers.

How much cheaper are open-weight models than frontier models?

Typically 30x to 700x per output token. A 120B-class open model costs around 17 cents per 1M output tokens while flagship frontier models list at 25 to 30 dollars. For routine tasks the quality gap is far smaller than the price gap.

Do batch discounts really cut the bill in half?

Yes, for workloads that can wait. OpenAI and Anthropic both give a flat 50 percent discount on batch jobs with results within 24 hours, and Google offers similar batch pricing on Gemini.

Why do prices for the same model differ between hosts?

Open-weight models can be served by anyone with GPUs, so hosts compete on utilization, hardware, and margin. The same Llama or DeepSeek endpoint routinely varies 2 to 4x between hosts, which is why per-model price tracking matters.

Should I buy a subscription or pay per token?

For products, per-token APIs win because costs scale with usage and you can route by difficulty. Chat subscriptions are flat-fee consumer products and do not expose the routing and batch levers that actually cut production costs.

Keep reading

Building on AI? Don't pay full price.

Perkstack tracks 200+ verified AI credits, free signup credits and startup grants, each with a step-by-step claim guide.