LLM API Pricing & Cost Calculator
Compare API costs across OpenAI, Anthropic, Google, and DeepSeek. Model caching discounts and batch requests. Costs are estimates, refer to your provider for exact pricing.
Request Parameters
Not sure how many tokens your prompt is? Count it with the Token Counter.
Prices
Each model uses its cheapest provider. The chart notes which price won.
Add Models
Models and prices come live from OpenRouter at the cheapest provider's price, or the maker's own with Maker prices on. Retired models aren't listed.
Add a preset model
Loading presets from OpenRouter...
Cost Comparison
Model Specs (per 1M tokens)
| Model | Input | Cached Input | Output | Actions |
|---|
How to use this tool
Pick a model
Select a model from the dropdown (GPT-5.4, Claude Sonnet 4.6, Gemini 3.5 Flash, DeepSeek V4 Pro, and more). The calculator loads that model's per-million-token input and output pricing automatically.
Enter input and output token counts
Type the number of input tokens (the prompt) and output tokens (the response) you expect per request, or per month. Output tokens usually cost 3x to 5x more than input tokens.
Toggle caching and batch options
Turn on prompt caching to model the discount for repeated system prompts, or toggle Batch to add each provider's own batch prices. Batch discounts differ by provider, can differ between input and output, and some models have none. A custom model uses the batch discount you enter for it. For multi-turn or agentic workloads, enter the expected token volume and request count directly.
Read the cost estimate
The calculator returns the total cost for your token volume, broken down by input and output. Compare multiple models side by side to find the cheapest option that meets your latency and quality needs.
About this tool
The LLM API Pricing Calculator estimates the API cost of models like GPT-5.4, Claude Sonnet 4.6, or DeepSeek V4. Change the input and output token counts, prompt caching discounts, request volume, and batch processing to see how your monthly bill changes.
For multi-turn or agentic workloads, increase the input token count and request volume to match the growing context and repeated calls. The calculator does not have a separate Agentic Loop mode, so the estimate comes from the values you enter.
Prompt and Context Caching
Caching can cut a large share of an LLM bill. If you send the same 100K token system prompt repeatedly, you pay full price for it once, and a fraction (10% to 50%) for subsequent hits. The calculator lets you estimate what percentage of your input tokens will be cached.
Batch API Mode
If your application does not require real-time latency, you can route requests through a Batch API. In exchange for waiting on the results, providers charge less, but how much less depends on the provider and the model. The wait depends on the provider too, and many set a limit of up to 24 hours.
Batch mode uses each provider's listed batch rates, which can differ for input and output, and models without batch prices keep their normal rates.
Standard Chat vs Agentic Workflows
A standard chat prompt has a predictable 3:1 input-to-output ratio.
Autonomous agents accumulate context, and each turn can add another response or tool result to the prompt.
With an append-only history, context grows roughly linearly but uncached cumulative input processing can grow quadratically across turns. Caching repeated prefixes can reduce that cost.
Pricing by model family
Every model from one maker in one table, newest first.
Popular model pricing
Pre-computed API pricing calculators for current AI models.
API pricing comparisons
Head-to-head cost breakdowns of recent models, including Claude Opus 5, GPT-5.6 Terra/Luna, and Kimi K3.
Guides that use this tool
Longer walkthroughs that put this tool next to the others a reader needs.
Frequently asked questions
Does OpenAI support prompt caching?
What is Batch API and when should I use it?
Why is prompt caching so important for Agentic workflows?
Are input and output tokens billed differently?
Related tools
LLM Token Counter
Count tokens in any prompt for GPT, Claude, Gemini, and Llama with exact OpenAI tokenization.
Use toolLLM VRAM Calculator
Calculate the VRAM needed to run or fine-tune any LLM at any quantization.
Use toolPower Cost Estimator
Estimate annual electricity costs for your PC, Server, or TV.
Use toolData Transfer Calculator
Calculate file transfer time or the speed you need over USB, Wi-Fi or Ethernet, with latency.
Use toolUse this tool on your own site
Drop the LLM Pricing Calculator into your blog, docs, or CMS with one iframe snippet. Free, no signup. See all embeddable tools