Skip to content
TokenCostLLM cost calculator

TokenCost

How LLM token pricing works

A short guide to tokens, the dollars-per-million formula, and a 30-day sketch — then open the live calculator on the homepage.

Open live calculator

What a token is

A token is a chunk of text the model reads or writes — often about four characters or 0.75 English words, but code, JSON, and CJK break that rule. Input tokens are the prompt plus context (system text, retrieved documents, chat history, tool results). Output tokens are the completion. Providers bill those two streams at different rates. This guide does not convert words to tokens for you; prefer usage counters from API logs.

The $/M formula

Estimated USD per request is (input tokens / 1,000,000 × input price per million) + (output tokens / 1,000,000 × output price per million). That is the only v1 math TokenCost runs in the browser from a typed rate file. Example: 2,000 input and 500 output on a $2 / $12 model is $0.004 + $0.006 = $0.010 for that call.

Monthly = per-request × requests/day × 30

A working monthly sketch is per-request cost × requests per day × 30. It is not a calendar month (February and 31-day months differ slightly). Scale requests per day if you need a different window. The homepage calculator turns those three numbers into a sorted shortlist.

What list rates miss

Public list rates omit prompt-cache hits, batch or flex discounts, regional multipliers, thinking tokens billed as output, and non-text meters (images, audio, video, search grounding). Cached or overnight-batch traffic will come in under the list sketch. Multimodal apps should treat these numbers as the language slice only. Confirm on the vendor page before you lock budget.

Open the live calculator

The multi-provider table lives on the homepage so this URL can stay a guide. Open live calculator to paste tokens, filter, and share a link.

Frequently asked questions

What is a token in an LLM API?

A chunk of text the model reads (input) or writes (output). English often lands near 0.75 words per token, but you should use API usage counters, not a word-count guess.

What is the $/M formula?

Cost per request ≈ (input tokens / 1,000,000 × input $/M) + (output tokens / 1,000,000 × output $/M). That is the math the TokenCost homepage calculator runs.

How do I turn that into a monthly estimate?

Monthly sketch = per-request cost × requests per day × 30. It is not a calendar month. Open the live calculator on the homepage to run a shortlist.

What do public list rates miss?

Cache hits, batch/flex discounts, thinking tokens billed as output, regional multipliers, and non-text meters. Confirm on the provider’s pricing page before you lock budget.