LLM API Pricing Calculator 2026
Compare token prices for 30 models from OpenAI, Anthropic, Google, xAI, DeepSeek, Mistral and Meta — and estimate your real monthly bill, including prompt-caching and batch discounts.
1 · Describe your workload
2 · Compare monthly cost across models
| Vendor | Model | Context | Input $/1M | Output $/1M | $ / request | Monthly ▲ |
|---|
All prices are the Standard tier, short-context rate — not Batch, Flex or Priority, and not the long-context tier. Vendors publish several rates per model; picking the wrong one can misstate your bill by 2× or more. Cache-hit input is billed at each vendor's published cached rate (10–25% of input, varies by vendor) where supported; models without published cached pricing ignore the cache slider. Batch discounts are applied per vendor to both input and output: −50% at OpenAI, Anthropic and Google, but −20% at xAI. Verified Sep 14, 2026 against each vendor's official pricing page. DeepSeek peak hours are 01:00–04:00 and 06:00–10:00 UTC, Monday–Friday; off-peak is half price and listed as its own row. Llama is open-weight and has no first-party list price — the rates shown are DeepInfra’s, and other inference providers charge differently.
Token counter — paste text, get a token estimate
Rule of thumb for English: 1 token ≈ 4 characters ≈ 0.75 words. Korean, Japanese and code typically use more tokens per character. Exact counts depend on each model's tokenizer.
How LLM API pricing works in 2026
Every major AI provider bills by the token — roughly a word fragment. You pay separately for input tokens (your prompt, system message, retrieved context) and output tokens (the model's reply). Output tokens cost 2–6× more than input tokens, so long-form generation is what really drives your bill.
Two discounts matter more than the sticker price. Prompt caching bills repeated prompt prefixes (system prompts, few-shot examples, long documents) at a reduced rate — 10% of the input rate at OpenAI, Anthropic and Google, but 16-25% at xAI and about 3% at DeepSeek. A chatbot with a 3,000-token system prompt saves dramatically at scale either way. The Batch API gives 50% off both directions at OpenAI, Anthropic and Google (20% at xAI) when you can wait minutes-to-hours for results, which suits evals, ETL and bulk summarization.
The spread between models is enormous: as of August 2026, a million output tokens runs from about $0.04 (Llama 3.1 8B on DeepInfra) to $180 (GPT‑5.5 Pro) — a 4,500× range. Picking the smallest model that clears your quality bar is the single biggest cost lever, ahead of caching, batching, or prompt trimming.
Frequently asked questions
How much does the GPT‑5.6 API cost?
How much does the Claude API cost?
What's the cheapest LLM API right now?
How many tokens is 1,000 words?
Do caching and batch discounts stack?
Where do these prices come from?
Go deeper
Every Anthropic model's current rates. OpenAI API pricing
GPT-5.6 Sol, Terra, Luna and the full lineup. Gemini API pricing
Google's tiers, incl. the long-context surcharge. Claude vs GPT
Tier-by-tier cost comparison with caching factored in. Cheapest LLM APIs
The 2026 budget leaderboard — and when cheap is enough. Prompt caching guide
The discount most teams leave on the table — 75% to 97%, by vendor. LLM API price change log
Every verified rate change, dated — and one of ours we got wrong. DeepSeek API pricing
The budget benchmark — and its sub-1% cache pricing. Gemini vs GPT
Identical flagships, very different budget tiers.
Sponsor TokenTally
Building an AI product, inference platform, or dev tool? Put it in front of developers actively comparing LLM costs. One tasteful placement, no tracking scripts. Get in touch →