What Is a Token? Tokens and Context Windows Explained

In short: a token is the small chunk of text an AI model actually reads: often a whole common word, sometimes part of a longer one. Google's Gemini documentation puts it at about 4 characters, or 60 to 80 English words per 100 tokens. The context window is the most tokens a model can handle in one request, counting everything: your messages, attached files, the conversation so far and the reply. API prices are charged per million tokens, with input and output priced separately.
What is a token in AI, in simple words?
A token is a piece of text (a word, part of a word, or a punctuation mark) that the model treats as one unit. Before a model reads anything, a tokenizer splits the text into pieces from a fixed vocabulary. Common words are usually one token; rarer words are split into several; spaces and punctuation are part of tokens too.
For example, a tokenizer might split "unbelievably" into "un", "believ" and "ably", while "cat" stays a single token. The model never sees letters. It sees a list of token numbers.
Different model families use different tokenizers, so the same sentence can be a different number of tokens on different models. Tokenizers also change between versions of the same model: the same text can cost more or fewer tokens after an update, even when the price per token stays the same.
How many words is a token?
Roughly three-quarters of an English word, but it varies. Google's Gemini token documentation says that for Gemini models, a token is about 4 characters, and 100 tokens is about 60 to 80 English words. Other vendors publish similar estimates for their own tokenizers.
| Text | Approximate tokens (at Gemini's rate) |
|---|---|
| A 10-word sentence | about 13 to 17 |
| A 500-word email | about 625 to 830 |
| A 100,000-word novel | about 125,000 to 167,000 |
Text in many other languages, and computer code, often takes more tokens for the same meaning than English prose.
Are images, audio and video counted in tokens too?
Yes. Models that accept other media convert it into tokens as well. Google's documentation gives the rates for Gemini:
| Input | Token count |
|---|---|
| Image up to 384 × 384 pixels | 258 tokens |
| Larger image | Split into 768 × 768 tiles, 258 tokens each |
| Video (static processing) | 263 tokens per second |
| Audio | 32 tokens per second |
At those rates a one-minute audio clip is about 1,920 tokens and a one-minute video about 15,780. Other vendors use their own methods and document their formulas. Most APIs also offer a way to count tokens before sending a request. In the Gemini API this is a count_tokens method.
What is a context window?
The context window is the maximum number of tokens a model can work with in a single request, its working memory. Everything counts against it:
- the system prompt (standing instructions from the app or developer);
- the whole conversation so far;
- attached documents, images and audio;
- tool definitions, if the model can use tools;
- the reply it is writing.
When a conversation outgrows the window, something has to be dropped or summarised, which is why a very long chat can "forget" its beginning.
Two limits are usually published separately:
- Context window: the total the model can take in.
- Maximum output: how many tokens it can write in one reply, usually much lower.
How big are context windows today?
Each model's maker publishes its context window; the figures below are read live from our model pages, one current model per company.
| Model | Context window |
|---|---|
| Claude Opus 5.5 | 1M |
| GPT-6.1 Sol | 1.05M |
| Gemini 4 Argon | 1.05M |
| Grok 4.7 | 500K |
| DeepSeek V4.1 Flash | 1M |
For scale: GPT-3, released in 2020, had a context window of 2,048 tokens. See few-shot prompting for what that limit meant in practice.
Does a bigger context window mean better answers?
Not automatically. A larger window lets a model take in more at once, but it does not guarantee the model uses all of it equally well. Long-context benchmarks measure how well models find and use information spread across a long input; results are on the benchmarks page. Attention, the mechanism inside transformers, also costs more as inputs grow; see Attention Is All You Need explained.
How does per-token pricing work?
API prices are quoted per million tokens, with input and output priced separately. The cost of one request is:
(input tokens ÷ 1,000,000 × input price) + (output tokens ÷ 1,000,000 × output price)
A worked example with round, hypothetical prices of $2 per million input tokens and $10 per million output tokens: a request with 20,000 input tokens and 1,000 output tokens costs 0.02 × $2 + 0.001 × $10 = $0.04 + $0.01 = $0.05.
Two things follow from the formula:
- Long inputs repeated on every call add up. A large document or a long conversation history is sent again with each message, which is why vendors offer cheaper rates for cached input.
- Thinking costs output tokens. Reasoning models write thinking tokens before their answer, and vendors typically bill those as output.
Real prices for each model, input and output side by side, are on its page in the AI models directory and on the comparison pages. Chat apps such as ChatGPT or Claude on a monthly plan do not charge per token; their limits are set by the plan instead.
Words to know
- Token: a chunk of text, image or audio that a model reads as one unit.
- Tokenizer: the tool that splits text into tokens.
- Context window: the most tokens a model can handle in one request.
- Maximum output: the most tokens a model can write in one reply.
- Input / output tokens: what you send, and what the model writes back.
- Cached input: repeated input billed at a lower rate.
- Thinking tokens: reasoning a model writes before its answer, usually billed as output.
- Per million tokens: the unit API prices are quoted in.
Related guides
Frequently asked questions
What is a token in AI?+
A token is a small chunk of text, such as a common word, part of a longer word or a punctuation mark, that an AI model reads as one unit. Images, audio and video are also converted into tokens. Context windows, output limits and API prices are all measured in tokens.
How many words are in 1,000 tokens?+
For Gemini models, Google says 100 tokens is about 60 to 80 English words, so 1,000 tokens is about 600 to 800 words. The exact number depends on the model's tokenizer and the language.
What is a context window?+
A context window is the maximum number of tokens an AI model can work with in one request, including the instructions, the conversation so far, any attached files and the reply. Text beyond the window has to be dropped or summarised.
What happens when a conversation exceeds the context window?+
The oldest parts have to be removed or summarised to make room, so the model can no longer see them. That is why a very long conversation can lose track of details from its beginning.
How much does a million tokens cost?+
It depends on the model, and input and output are priced separately. Each model's current price per million input and output tokens is listed on its page in the AIblogly models directory, taken from the vendor's own pricing page.
Do images use tokens?+
Yes. For Gemini, Google's documentation says an image up to 384 pixels on each side counts as 258 tokens, and larger images are split into 768 × 768 tiles of 258 tokens each. Other vendors use their own formulas.
Enjoyed this? Get more in your inbox.
Up to ten of the week's AI news stories, by email once a week.