All tools
Cost · free, no sign-up

What will my API bill be?

API bills are driven by three things people rarely track: how long the prompt is, how often it is resent, and the fact that output costs several times input.

6 inputs4 questions answeredUpdated for 2026 hardware
API Token Cost Calculator — What will my API bill be?
Answer first

The short answer

Computed from this tool’s default settings — requests per day and the rest as most people start. Change them below for your own case.

Per month$410.40

About $410.40 a month, $228.00 of it output. If a large part of your input is a fixed prefix, prompt caching is the first thing to try — set the hit rate above to see the effect.

The calculator

API Token Cost Calculator

Monthly spend from requests, prompt length and price — with caching.

Your setup
0

Cached input typically bills at a tenth of the normal input rate.

Per month$410.40

About $410.40 a month, $228.00 of it output. If a large part of your input is a fixed prefix, prompt caching is the first thing to try — set the hit rate above to see the effect.

Per day$13.50
Per year$4,928
Input share$182.40/mo
Output share$228.00/mo
Tokens per month76.0M
Inputs

What each setting changes

Every input moves the result for a reason. This is what each one does and where to find the value for your own machine.

SettingDefaultWhat it changes
Requests per day1000Your own figure, starting from 1,000. Change it to match what you actually run.
Input tokens per request2000Your own figure, starting from 2,000. Change it to match what you actually run.
Output tokens per request500Your own figure, starting from 500. Change it to match what you actually run.
Input price3 per 1MYour own figure in per 1M, starting from 3. Change it to match what you actually run.
Output price15 per 1MYour own figure in per 1M, starting from 15. Change it to match what you actually run.
Prompt cache hit rate0 %Cached input typically bills at a tenth of the normal input rate.
Worked examples

Real answers across prompt cache hit rate

The same calculation run at a range of settings, with everything else left at its default. These are computed by the tool itself, not written by hand.

Prompt cache hit ratePer monthPer dayPer yearInput share
0$410.40$13.50$4,928$182.40/mo
25$369.36$12.15$4,435$141.36/mo
50$328.32$10.80$3,942$100.32/mo
75$287.28$9.45$3,449$59.28/mo
100$246.24$8.10$2,957$18.24/mo

About $410.40 a month, $228.00 of it output. If a large part of your input is a fixed prefix, prompt caching is the first thing to try — set the hit rate above to see the effect.

Method

How this is calculated

No lookup tables and no invented constants. Here is the arithmetic, so you can check it against your own numbers.

Providers bill input and output separately, and output is usually four to five times the input rate. Long system prompts are therefore cheap per token but expensive in aggregate, because they are resent on every request.

Prompt caching is the biggest single lever on a repetitive workload: a cached read commonly costs a tenth of a fresh input token, so a high hit rate on a large fixed prefix can change the bill by an order of magnitude.

API prices are inputs rather than constants, because providers change them and a hard-coded number would quietly go wrong. The defaults were current when this tool was written — check your provider’s pricing page and correct them if they have moved.

These are well-founded engineering estimates, not benchmark results. Your quantisation, runtime and context length all move the real number, and usable memory is an assumption rather than a specification. See the full methodology for every assumption behind these figures.

Use cases

Who this is for

The three situations that bring people to this calculation.

Use case 01

Before launch

Forecast the bill at your expected volume.

Use case 02

Cost overrun

Find whether input or output is the problem.

Use case 03

Evaluating caching

See what a good hit rate is worth.

Walkthrough

How to use this calculator

Four steps, no account, nothing leaves your browser.

  1. Set requests per day

    Start at the top of the panel. Every figure recalculates as you change it — there is no submit button, because watching the number move is the point.

  2. Adjust the rest to match your setup

    5 further settings: input tokens per request, output tokens per request, input price, output price, prompt cache hit rate. Defaults are the common case, so change only what differs for you.

  3. Read the headline, then the table

    The large figure answers the question. The table underneath shows how the answer changes across nearby settings, which is usually where the decision actually gets made.

  4. Check it against the method

    The arithmetic is written out above. If a number looks wrong for your hardware, the assumptions are the first place to look — usable memory and quantisation are the two that vary most.

Questions

What will my API bill be: common questions

The questions people ask about this, answered without hedging.

Why is my API bill higher than expected?

Usually the system prompt. It is resent on every request, so a long one multiplies across your whole volume. Output pricing is also typically four to five times input, so verbose responses cost more than they look.

How much does prompt caching save?

A cached input token commonly bills at about a tenth of a fresh one. With a large fixed prefix and a high hit rate, that can cut the input side by most of its value.

Should I optimise input or output tokens?

Whichever dominates your bill — set the numbers above and look. Chat workloads with long documents are input-heavy; generation and agent workloads are often output-heavy.

Do the default prices here stay current?

No, and they are inputs for exactly that reason. Check your provider’s pricing page and correct them; the arithmetic around the price is what does not go stale.

The rest of the set

All 50 run on the same arithmetic, so answers across them agree.

Coverage

Searches this page answers

Different ways of asking the same question, all resolved above.

api cost calculator llmopenai api cost estimatorclaude api pricing calculatortoken cost calculatorllm api bill estimateprompt caching savingsinput vs output token costwhat will my api bill beapi token cost calculatorapi token cost calculator onlinefree api token cost calculator
Next step

Now find the models that fit

Sizing is only half the problem. Model Radar takes your hardware and shows which models actually run on it, ranked by what they are good at — the same arithmetic as this page, applied to every model worth running.