Gemini Tokenizer
The Gemini Tokenizer counts the exact number of tokens your text uses for Google's Gemini models, using Google's official countTokens API. Paste your text, pick a model, and get an accurate count instead of an estimate.
Why not use a GPT tokenizer for Gemini?
Gemini uses its own tokenizer, different from OpenAI's and Anthropic's. Counting Gemini tokens with tiktoken (the GPT tokenizer) gives the wrong number, and Google does not ship a public client-side Gemini tokenizer. The only accurate count comes from Google's own countTokens endpoint — which is what this tool calls.
How to count Gemini tokens
- Paste or type your text.
- Choose the Gemini model you are targeting.
- Select Count tokens to get the exact count for that model.
Supported Gemini models
| Model | Notes |
|---|---|
| Gemini 2.5 Pro / 2.5 Flash | Latest generation |
| Gemini 2.0 Flash | Fast, cost-efficient |
| Gemini 1.5 Pro / 1.5 Flash | Long-context predecessors |
The model list is config-driven, so more Gemini models can be added without code changes.
Example
The quick brown fox jumps over the lazy dog. counts to roughly 10 tokens on Gemini. Non-English text and long documents use more tokens — use the live characters-per-token readout to gauge your own text.
Limitations
- A free sign-in is required; counting tokens costs no credits.
- No per-token colored breakdown: Google's tokenizer isn't public, so this tool returns the exact count only. For a visual token view, use the ChatGPT Tokenizer.
- Counts are model-specific — switch models to compare.


