Token and cost calculator for 245 models
Two numbers decide what a prompt costs: how many tokens go in, and how many come back. Everything else is a list price. This page gives the arithmetic first, then the table, so you can compute any prompt against any of the 245 models the site publishes rather than trusting a per-prompt figure someone else calculated.
The catalogue behind the table is pages/assets/models/model-selection.json: 245 models across 40 suppliers, context windows from 32,000 to 10,000,000 tokens, and a rate on 241 of the 245 rows. The four rows without a rate carry no price in the catalogue, so this page says nothing about them rather than guessing.
The arithmetic, in three lines
- Estimate tokens as characters divided by four. That is the same estimate the application's scorer uses for its length category, and it is accurate enough for a budget. A 12,000-character brief is about 3,000 tokens; code is closer to three characters per token, so add a third if the brief is mostly code.
- Cost one run as
(input tokens / 1,000,000 × input price) + (output tokens / 1,000,000 × output price), with the prices taken per million tokens, which is how every row in the catalogue is quoted. - Multiply by runs. The useful unit is 1,000 runs, because it turns the arithmetic into one line: an 8,000-token input and a 1,500-token answer cost
8 × input price + 1.5 × output priceper thousand runs, in dollars.
That third line is why the last column below can be read straight off the two prices beside it. It also shows the thing people miss: at these proportions the output price matters about five times as much as the input price per unit, because 1.5 units of output against 8 of input still carries most of the money once the rates differ by an order of magnitude.
Twelve rows, from cheapest to dearest
Cost of 1,000 runs of an 8,000-token prompt with a 1,500-token answer, computed from the catalogue's own rates. The rows are a spread, not a recommendation: the cheapest row is not automatically the right row, and the last section says why.
| Model | Supplier | Window | USD / 1M in | USD / 1M out | USD / 1,000 runs |
|---|---|---|---|---|---|
| Amazon Nova Micro | Amazon | 128,000 | 0.035 | 0.14 | 0.49 |
| Hy4-Flash | Tencent | 1,048,576 | 0.035 | 0.1405 | 0.49 |
| Llama 3.1 8B Instant (Groq) | Groq | 131,072 | 0.05 | 0.08 | 0.52 |
| DeepSeek V4-Flash (DeepInfra) | DeepInfra | 1,048,576 | 0.09 | 0.18 | 0.99 |
| DeepSeek V4-Flash (Fireworks) | Fireworks AI | 1,000,000 | 0.14 | 0.28 | 1.54 |
| Qwen3 Coder | Alibaba (Qwen) | 262,144 | 0.22 | 1.00 | 3.26 |
| Codestral 2508 | Mistral AI | 131,072 | 0.3 | 0.9 | 3.75 |
| DeepSeek V4.1 Flash 1017 | DeepSeek | 1,000,000 | 0.3 | 1.2 | 4.20 |
| Qwen3 Coder Flash | Alibaba (Qwen) | 1,000,000 | 0.3 | 1.5 | 4.65 |
| Kimi K3.1 Pro | Moonshot AI | 1,048,576 | 2.00 | 10.00 | 31.00 |
| GPT-5.5 | OpenAI | 1,050,000 | 5.00 | 30.00 | 85.00 |
| Claude Fable 5.2 | Anthropic | 1,000,000 | 8.00 | 40.00 | 124.00 |
A worked example: 800 runs in a month
A 12,000-character brief, about 3,000 tokens, with a 1,200-token answer, run 40 times a day for 20 working days. That is 800 runs a month, which is a realistic figure for one developer using an agent all day.
| Model | One run | 800 runs |
|---|---|---|
| DeepSeek V4-Flash (DeepInfra) | USD 0.00049 | USD 0.39 |
| Kimi K3.1 Pro | USD 0.018 | USD 14.40 |
| GPT-5.5 | USD 0.051 | USD 40.80 |
| Claude Fable 5.2 | USD 0.072 | USD 57.60 |
The spread is 148 times between the first row and the last, for the same 800 prompts. Two of those numbers are affordable without a decision and two are the cost of a licence every month, which is the only cost argument this page makes: the price of the tool is a rounding error beside the price of the calls, and the calls are the part nobody budgets.
What this table cannot tell you
- Cache and batch rates. Some suppliers publish a lower rate for a repeated prefix or a delayed batch. The catalogue holds a list rate per model; where a model has a batch variant it appears as its own row (Claude Fable 5.2 Batch, for instance), and where it does not, the discount is not in this arithmetic.
- Thinking tokens. A reasoning model bills its reasoning as output. A 1,200-token answer that thought for 4,000 tokens is billed for 5,200, and no table without your own measurements can predict that.
- Retries. A failed run that is retried is paid for twice. At a 5% retry rate, add 5%.
- What is in the window. A long conversation resends its history on every turn, so run twenty of a session costs far more than run one. This is the subject of context is a budget, and it is usually a larger number than the model choice.
The per-model pages at /model-limits render the same catalogue row by row, with the window and both rates, and /models is where the catalogue is browsed by task. Both are generated from the file named at the top of this page, so a figure here and a figure there come from one source.
The catalogue file's own timestamp reads 2026-11-21 11:20 +10:00, which is the only date this page will quote: a price table without one is an opinion.
Two lessons in the course go further on the same arithmetic: cost control and token budgeting and deep with tokens.
Related guides
Part of the guides index. Two that follow this one: Which model is cheapest for coding this month and Context is a budget, not a container.
Cite this page as: TPEE, the Toptronic® Prompt Engineering Editor — https://tpee.app/guides/token-and-cost-calculator. Ask: support@tpee.app.