Token Count Estimator
How many tokens a piece of text is — from words, characters or pages — and whether it fits a context window.
English prose runs about 0.
How the token count estimator works
English prose runs about 0.75 words per token, or roughly four characters per token. Those two ratios disagree slightly and both are approximations, which is why this shows the range rather than a single confident number.
Other content tokenises worse. Code, JSON, non-Latin scripts and text full of numbers all use more tokens per character, sometimes twice as many, because the tokeniser was fit to ordinary prose.
Formula: tokens ≈ words / 0.75 ≈ characters / 4
Worked examples
| Inputs | Estimated tokens | Note |
|---|---|---|
| 5,000 words of prose | 6,667 | about 6,700 tokens |
| The same in code | 9,500 | nearly half again as many |
| A book | 120,000 | still fits a 128k window |
FAQFrequently asked questions
How many tokens is a word?
About 1.33 for English prose — the familiar rule is 0.75 words per token. Code and structured data run much higher.
Why is this an estimate?
Because every model has its own tokeniser fitted to its own training data. Two models can differ by 20% on the same text.
How many tokens is a page?
A 500-word page is roughly 670 tokens of prose. A novel of 90,000 words is about 120,000.
Why does non-English text cost more?
Because tokenisers are trained predominantly on English. Scripts with fewer training examples get split into more, smaller tokens.
Should I count tokens exactly?
For billing, use your provider's tokeniser. For sizing a design, this range is enough to tell you whether something fits.
Where these figures come from
- Vaswani et al. (2017) — Attention Is All You Need — the transformer architecture the memory arithmetic follows
- Kaplan et al. (2020) — Scaling Laws for Neural Language Models — the compute relationship used for training estimates
- Hoffmann et al. (2022) — Training Compute-Optimal Large Language Models — the tokens-per-parameter guidance ("Chinchilla")
- IEEE 754 — Standard for Floating-Point Arithmetic — the numeric formats behind bytes per parameter
- AI Safety Institute — the UK government AI body
Last checked: September 2026. The relationships here are architectural, not vendor-specific: bytes per parameter follow the numeric format, KV-cache size follows the transformer definition, and token-per-word ratios come from published tokeniser behaviour.