Token Counter for GPT, Claude and Gemini
Counts the tokens in any text for the current GPT, Claude and Gemini model families and shows where each token boundary falls, so you can see why a prompt costs what it costs. OpenAI counts are exact because the real encoder runs in the page; other providers are labelled estimates because they publish no browser tokenizer.
How the estimate is calculated
For non-OpenAI models, the count is a transparent estimate: tokens = max(wordCount × 1.3, charCount ÷ 4), rounded up. The exact encoder is not published for any of those models, so the figure is a planning aid rather than a measurement. Verify with a small sample on the model's own tokenizer if the budget is tight.
Token boundaries
How to use the Token Counter
Paste your text in the box, pick a model, and the token count updates as you type. The big number is the headline; the small cells underneath give characters, words, sentences and UTF-8 bytes, which is what a price calculator needs. The verdict line on the right names the model context window and how much of it is left.
Switch the “Show token boundaries” checkbox to see where each token starts and ends. The view is capped at 2,000 tokens, because rendering 50,000 spans is what makes these tools hang.
Why are non-OpenAI counts labelled as estimates?
Anthropic, Google and Meta publish no browser tokenizer. The exact count is a measurement, the estimate is a planning aid, and we say so in the UI so nobody quotes the wrong number. If the budget is tight, the recommended check is to run a small sample on the model's own tokenizer and confirm the multiplier for your text.
Does it work for Devanagari, emoji and CJK?
Yes. The OpenAI encoders are byte-pair encoders that handle the full Unicode range. The estimate uses words and characters, both of which work for CJK and Devanagari (with the caveat that the multiplier is calibrated on English).
What does the verdict line say?
It names the model limit and how many tokens are spare. For a context window check that goes the other way (does a whole conversation fit?), use the Context Window Checker instead.