Token Counter: Exact token counts for GPT models with OpenAI’s tokenizer. Input: Text you type or paste and values you enter. Output: Results shown on the page. Privacy: Runs in your browser: inputs and files stay on your device and are not uploaded.
How to count tokens
- Paste your prompt, document or chat history.
- The exact token count for OpenAI's tokenizers appears instantly, along with words and characters. Choose o200k for GPT-4o, GPT-4.1, the o-series and GPT-5, or cl100k for GPT-4 and GPT-3.5.
- Tick Show tokens to see how the text is split, with each token highlighted.
What tokens are and why they matter
Large language models do not read letters or words; they read tokens, chunks of text from a fixed vocabulary of around 100,000 to 200,000 pieces. A common English word is often one token, including its leading space, while rare words, names, numbers, emoji and code are split into several. As a rule of thumb, one token is about four characters or three-quarters of an English word, but other languages often need more tokens for the same meaning.
Token counts matter for three reasons. API pricing is per token, for both input and output. Every model has a context window, the maximum number of tokens it can consider at once, including your prompt, any documents, the chat history and the reply. And longer prompts are slower. Counting before you send helps you trim prompts, split documents into chunks that fit, and budget costs with our LLM Cost Calculator.
The OpenAI counts use the open-source gpt-tokenizer library, a faithful port of OpenAI's tiktoken, loaded once into your browser. Only OpenAI's tokenizers are counted: Anthropic, Google and others use different tokenizers, so their counts differ. Your text never leaves the page.
How many tokens is 1,000 words?
About 1,300 to 1,400 tokens for typical English prose with OpenAI's tokenizers. Code and other languages usually need more.
Does it count Claude or Gemini tokens?
No. They use their own tokenizers, so the same text gives a different count. Use Anthropic's or Google's token counting API for exact numbers.
Do spaces and line breaks count?
Yes. Spaces are usually merged into the following word's token, but extra spaces, indentation and blank lines add tokens.