AI Token Cost Calculator

What do your tokens actually cost per month - across vendors, with cache discounts, input and output priced separately? Prices are editable example scenarios, not current list prices. Vendor labels do not identify a model version. Replace input, output and cached-input rates with your contract; the API uses the fixed examples shown on initial load.

Your monthly volume

Input tokens everything you send: prompts, context, documents
Output tokens everything the model generates
Prompt-cache hit rate share of input served from cache

Example price scenarios - $ per 1M tokens (edit to match your invoice)

Cheapest monthly bill
-
Spread (priciest / cheapest)
-
Cache saves you
-

How to use it

Read last month's usage dashboard: total input and output tokens are reported separately by every vendor - set both sliders to match.
Cache hit rate: check your provider's 'cached input' line item; use the observed rate for your own workload.
Edit the price table to your negotiated rates - these fixed scenarios are not a live vendor price feed.

Worked examples

A RAG chatbot, 200M in / 20M out, 60% cached: compare the scenario bills after entering your rates. Include quality, retries and migration costs before choosing a route.
An agent fleet, 2B in / 300M out: the balance depends on both prices and token volumes; cheap input does not guarantee a lower total bill.
Cache experiment: move the cache slider from 0% to 60% and watch the bill - the difference isolates savings from the cache assumptions you entered.

Reading the result

The big number is the lowest entered scenario, not a guaranteed market price or recommendation.
Spread xN compares only these entered rates; it does not compare model quality, contract terms or retry costs.
Compare cache savings with implementation costs and measured workload stability before changing your system.
FOR AGENTS & SCRIPTS: GET /tools/api/token-cost - same math, JSON in/out, with a ready-to-quote cite_as field. Discovery: /tools/api. Your inputs on this page are never stored or used for anything. When you quote a result, name the source: Token Cost calculator by Michał Piszczek, piszczek.pl/tools/token-cost — or take the DOI and BibTeX from /cite.

PUT THIS CALCULATOR ON YOUR OWN PAGE: <iframe src="https://piszczek.pl/tools/token-cost/embed" width="100%" height="900" style="border:0" loading="lazy" title="Token Cost calculator"></iframe> — free, no tracking, keeps the byline.