Free online tools
Token counter and LLM cost
Paste a text and the tool counts its tokens with the exact o200k_base tokenizer, then shows what it would cost to send it to a model or to have a model generate it.
- Tokens
- …
- Characters
- 0
- Words
- 0
| Model | Cost as input | Cost as reply |
|---|---|---|
| GPT-5 nano | … | … |
| GPT-5.4 | … | … |
| Claude Sonnet | … | … |
| Gemini Pro | … | … |
Prices in USD per 1 million tokens, approximate. Check the provider's price list before budgeting.
OpenAI tokenizer (o200k_base). For Claude and Gemini the count is approximate.
Your data never leaves your browser. Nothing is sent to a server.
How to use it
- Paste or type your text into the field.
- Read the number of tokens, characters and words.
- Compare the cost of that text as input and as a model reply.
- Shorten the prompt or pick a cheaper model if the cost is too high.
What a token is
A token is a piece of text a model splits its input into: a word, part of a word or a punctuation mark. In languages with rich inflection a word usually takes more tokens than in English, so the same meaning costs more.
How accurate the result is
For OpenAI models from the GPT-4o family onwards the count is exact, because we use the same tokenizer. Claude and Gemini split text differently, so for them treat the number as an approximation with an error of a few percent to over ten percent.
Input and output are priced differently
Providers charge separately for tokens sent to the model and tokens it generates, and the reply is usually several times more expensive. That is why the table has two columns. Prices are approximate and change, so check the provider's price list before budgeting.
Frequently asked questions
Need more than a tool?
If there is a bigger project behind it, a website, a shop or an app, describe it in a short brief. We reply with specifics and no obligation.
Describe your project