Tokens, plainly
Every model price is quoted per million tokens, so knowing how your text turns into tokens is the whole game. Here is what matters, without the hype.
What a token is
A model never sees letters or words. A tokenizer first cuts your text into pieces from a fixed vocabulary and turns each piece into a number. Common words are usually one piece, often with the space in front of them. Rare words, names and numbers break into several. Emoji and many non-Latin characters can take more than one token each, because the vocabulary is built from bytes.
That is why the editor above underlines each token in place. Look at a long URL or a block of JSON and you can see the cost pile up.
Why counts differ by model
Each lab trains its own vocabulary. OpenAI publishes theirs, so TokenCraft runs it exactly and marks those models Exact. Anthropic, Google, Meta, Mistral, DeepSeek and others use tokenizers that are not all public, so their counts here are estimates made with o200k_base and marked ≈ Estimate.
Treat estimates as a planning figure. Some newer tokenizers produce noticeably more tokens than o200k_base for the same text, so leave headroom near a context limit and check your provider's usage report for the billed number.
cl100k_base vs o200k_base
cl100k_base has about 100,000 entries and arrived with GPT-4; the text-embedding-3 models still use it. o200k_base doubled the vocabulary with GPT-4o and is used by newer GPT models. A bigger vocabulary means longer pieces, so the same text usually needs fewer tokens, and the difference is largest outside English. Here are both, counted on your device:
| Same text in | cl100k_base | o200k_base | Change |
|---|---|---|---|
| English | … | … | … |
| Code | … | … | … |
| Hindi | … | … | … |
Four ways to cut the bill
- Cache the stable part. Put instructions and reference material first and keep them identical between calls. Providers that offer prompt caching bill repeated prefixes at a much lower rate; the answer panel shows that rate when the model has one.
- Ask for shorter replies. Output usually costs several times more per token than input. Set the reply size in the answer panel and watch which side of the bill moves.
- Strip formatting. Indentation, comments and table padding are tokens too. The minifier removes them and shows the real saving.
- Pick the model per job. The rate board ranks every model for your exact prompt. A cheaper model that fits often does routine work just as well.
How TokenCraft prices a call
Cost per call is input tokens times the input rate, plus the expected reply times the output rate. Rates are list prices in US dollars from OpenRouter's public catalog. They do not include batch discounts, regional pricing or taxes. When a model charges more above a certain prompt length, the answer panel warns you once your prompt crosses it.