Paste text to count exact tokens across major LLM tokenizers. See API costs per request and compare how different models tokenize the same input.
A token is a chunk of text that an LLM processes. It can be as short as one character or as long as one word. English text averages about 4 characters per token, but this varies by language, code, and formatting.
Each model family uses its own tokenizer with a different vocabulary. GPT-4o uses the o200k encoding, Claude uses its own tokenizer, and open models like Llama and Qwen use SentencePiece-based tokenizers. The same text can produce 5-10% more or fewer tokens depending on the model.
GPT-4o token counts are exact (using the actual o200k tokenizer). Other models use ratio-based estimates calibrated to their known tokenization characteristics. For most practical purposes — cost estimation, context window planning — these are within a few percent.
Context windows range from 8K tokens (older models) to 2M tokens (Gemini). Most modern models support 128K+. Remember that context includes both your input and the model's output, so a 128K window means your input + output must stay under that limit.
Stop counting tokens by hand. CopperRiver handles model context automatically →