Free tool
AI API Cost Calculator
Estimate your monthly LLM API bill across GPT-4o, Claude, Gemini, DeepSeek and more. Enter tokens per call and monthly volume; every price is editable so you can match current provider rates.
| Model | $ / 1M input | $ / 1M output | Per call | Per month |
|---|---|---|---|---|
| GPT-4o | $0.00750 | $7.50 | ||
| GPT-4o mini | $0.00045 | $0.45 | ||
| Claude Sonnet | $0.01050 | $10.50 | ||
| Claude Haiku | $0.00350 | $3.50 | ||
| Claude Opus | $0.01750 | $17.50 | ||
| Gemini Pro | $0.00625 | $6.25 | ||
| Gemini Flash | $0.00155 | $1.55 | ||
| DeepSeek | $0.00082 | $0.82 |
Prices are editable defaults per 1M tokens — providers change rates often, so verify against the official pricing pages before budgeting.
What this tool is for
API pricing looks cheap per call and stops looking cheap at volume. The gap between a prototype's bill and production's is usually two or three orders of magnitude, and it is almost always discovered after the fact.
This estimates the monthly cost across the major providers so the comparison happens before the commitment rather than after.
How it works
Enter your input and output tokens per call and your expected monthly volume, and the calculator produces a monthly figure per model. Every price is editable, which matters: provider rates change often enough that any hard-coded table is wrong within months.
The prices shipped with the tool carry the date they were checked. Treat them as a starting point and confirm against the provider before you budget on them.
When to use it — and when not to
Use it before choosing a model for anything that will run at scale, and again when volume grows — the model that was obviously right at a thousand calls a month is often obviously wrong at a million.
It estimates API cost only. It does not account for retries, failed calls you still pay for, the tokens a system prompt adds to every single request, or engineering time. Those are frequently larger than the number this produces.
Things worth knowing
Output tokens usually cost three to five times input tokens, so the fastest way to cut a bill is almost never a cheaper model — it is asking for shorter answers. "Respond in under 100 words" can halve a monthly cost with no change in model.
The second lever is routing. Sending the easy majority of requests to a cheap model and only the hard cases to a flagship typically beats standardising on a mid-tier for both cost and quality.
Frequently asked questions
How do I calculate AI API costs?
Multiply your input tokens by the input price per million, add output tokens times the output price per million, then multiply by your monthly call volume. This calculator does that across eight models at once.
Why can I edit the prices?
AI providers change pricing frequently. Editable fields mean you can paste in current rates from the official pricing page and get accurate numbers rather than relying on stale defaults.
Which AI API is cheapest?
Generally the small models — GPT-4o mini, Gemini Flash and DeepSeek — cost a fraction of the flagship models. Enter your actual token volumes above to see the real comparison for your workload.