AI token counter

Paste text into this AI token counter to see characters, words and tokens side by side, with exact counts for OpenAI’s GPT-5 models, labelled estimates for Claude, Gemini, Mistral and Llama, and the cost of each request.

Free, no sign-up. Your text is counted in your browser, with no AI calls.

Your text stays in your browser and is never uploaded.

Used only for the cost per request. Set the length of answer you expect; the answer is billed at the output price.

Your counts

Paste or type text to count it.

Characters
0
Words
0
GPT-5 tokens, exact
0
Characters per token
0

A token is the unit of text a language model reads and bills for: “Hello world, this is a test.” is 8 tokens on OpenAI’s GPT-5 models. OpenAI publishes that o200k encoding, so its counts here are exact. Claude, Gemini, Mistral and Llama counts are labelled estimates from each maker’s published rule, or a range where none exists.

How to use this tool

Exact OpenAI counts
OpenAI publishes o200k, the encoding its GPT-5 models use, and the open source gpt-tokenizer package implements it. gpt-oss uses a variant with the same token table. GPT-6 models get the same count marked not confirmed, because OpenAI has not published their encoding.
Estimates for other makers
Claude, Gemini and Mistral rows apply the rule of thumb each maker publishes, with a link to it. Anthropic gives about 3.5 characters per token and about 30 percent more tokens on Claude 4.7 and later. Google and Mistral give about 4. Where a maker publishes no rule, as with Meta’s Llama, the row shows a range.
Cost per request
Your tokens times the input price, plus the answer length you set times the output price, from the AIGROW model list and its check date. Long prompt rates, caching and batch discounts change the bill, and each model page lists them.
Token highlighting
The first 3,000 GPT-5 tokens are shaded in turn, so you can see where each one starts and ends. A space usually belongs to the word after it. Switch on token IDs to see the numbers the model receives.
Your text stays here
The tokenizer loads into your browser the first time you type and counts there. Nothing you paste is sent to a server or stored.

OpenAI tiktoken: the published encodings

Questions before you start

For GPT-5 models and gpt-oss, yes: the page runs the o200k encoding OpenAI publishes. GPT-6 shows the same number marked not confirmed. An API request also adds a few tokens of message formatting, and a chat app adds its own instructions, so the billed total can be higher than the count of your text.

Anthropic and Google count tokens through their own APIs, which need an account and a key. Their documentation gives a rule of thumb for English text, which the page applies and labels. Code, numbers and other languages can split very differently, so read those rows as a guide.

OpenAI puts 100 tokens at about 75 English words, so 1,000 tokens is about 750 words. Google gives 60 to 80 words per 100 tokens for Gemini. Paste your own text for its real ratio: other languages and code usually take more tokens per word.

Meta publishes no characters per token rule for Llama. The row shows the span between the published rules, from 4 characters per token to the Claude 4.7 rule, and cost and fit use the high end.

No. The count runs in your browser and the text is not sent, logged or stored. Only the tokenizer itself is downloaded, once, when you first type.

See how AI assistants describe your business

Run the free visibility scan to check which sources assistants use. If you need regular monitoring, compare the plans before choosing one.