How many tokens are in a 2,619-word article?
Depends who’s counting. We ran one of our posts through seven AI tokenizers and got answers from 3,632 to 3,893.
That spread is small. On a Hindi document, an older OpenAI tokenizer counted 5.6 times the English total. Our post’s raw HTML hit 47 times.
So what are tokens in AI, and why does identical text cost different amounts? We priced one real job on three APIs and found where the context window runs out.
What are tokens in AI?
Tokens are the chunks of text a language model reads and writes. One token can be a whole word, part of a word, a word with its leading space, or a punctuation mark.
Every model in our generative AI explainer works this way. It never sees letters, only a list of numbers, one per token, and it predicts the next one.
OpenAI’s o200k tokenizer cuts “Tokenization isn’t free.” into five pieces: Token, ization, isn’t, free and the full stop. Common words stay whole. Rare ones get chopped.
Why care? Because tokens are the billing unit. APIs charge per million tokens in and out, and every limit you’ll hit is counted in tokens, not words.
OpenAI and Google both quote the same rule of thumb: about 4 characters, or 0.75 English words, per token. Our test page landed right on it, at 4.04 characters and 0.72 words.
We counted one real page with seven tokenizers
The page was our MCP vs API comparison, stripped to clean Markdown: 14,667 characters and 2,619 words. We counted it locally with two OpenAI tokenizers and five open models that publish theirs.
| Tokenizer | Used by | Tokens | Chars per token |
|---|---|---|---|
| o200k_base | OpenAI GPT-4o to GPT-5 | 3,632 | 4.04 |
| cl100k_base | OpenAI GPT-4, GPT-3.5 | 3,638 | 4.03 |
| Llama 3.2 | Meta | 3,638 | 4.03 |
| Qwen3 | Alibaba | 3,736 | 3.93 |
| DeepSeek-V3 | DeepSeek | 3,742 | 3.92 |
| Mistral Nemo | Mistral | 3,798 | 3.86 |
| Gemma 3 | Google (Gemini 2.0 tokenizer) | 3,893 | 3.77 |
The gap is 7%. Watch Gemma 3: Google says it uses Gemini 2.0’s tokenizer, so it’s the closest public stand-in for Gemini.
Claude is missing. Anthropic doesn’t publish its tokenizer, and its free counting endpoint needs an API key we didn’t use here. Every Claude figure below is an estimate, flagged as one.
The counting itself takes a few lines:
import tiktoken
from tokenizers import Tokenizer
text = open("page.md").read() # the article as clean Markdown
o200k = tiktoken.get_encoding("o200k_base")
gemma = Tokenizer.from_file("gemma-3-tokenizer.json")
print(len(text), "characters,", len(text.split()), "words")
print("o200k_base:", len(o200k.encode(text)))
print("Gemma 3: ", len(gemma.encode(text, add_special_tokens=False).ids))
Then the surprise. The same article as raw HTML, menus and scripts included, came to 171,750 tokens on o200k: 47 times the clean version.
So convert pages before a model sees them. Our guide to scraping websites for LLMs tests the converters, and Firecrawl is the one we’d pay for at volume. Our Firecrawl pricing breakdown shows the cost per page.
Why does Hindi cost more tokens than English?
Tokenizers learn their vocabulary mostly from English, so other scripts get cut into smaller pieces. How small depends on the tokenizer.
We tested a document published in both languages: the Universal Declaration of Human Rights.
| Tokenizer | English | Hindi | Hindi vs English |
|---|---|---|---|
| OpenAI o200k | 2,017 | 3,365 | 1.67x |
| OpenAI cl100k | 2,016 | 11,229 | 5.57x |
| Llama 3.2 | 2,016 | 5,946 | 2.95x |
| Qwen3 | 2,037 | 10,611 | 5.21x |
| DeepSeek-V3 | 2,001 | 6,166 | 3.08x |
| Mistral Nemo | 2,058 | 3,942 | 1.92x |
| Gemma 3 | 2,071 | 2,864 | 1.38x |
The old cl100k tokenizer, used by GPT-4 and GPT-3.5, spends about one token per Hindi character. Even the newer o200k splits मनुष्यों (humans) into three tokens.
Gemma 3 was the most even, which matches Google’s claim that the Gemini tokenizer is better balanced for non-English text.

On a bill, a Hindi chatbot on an o200k model pays about 67% more than the same bot in English. Building for Hindi, Tamil or Bengali speakers? Count a sample in that language first, because English rules of thumb undercount.
What is a context window, and what fills it?
A context window is the most tokens a model can handle in one request. Your input, the answer and, on reasoning models, the model’s thinking all have to fit inside it.
Models remember nothing between requests. Chat apps resend the conversation each time, so every message makes the next request bigger.
A typical request carries far more than your question:
- System prompt: the instructions an app sends before you type.
- Tool definitions: in our MCP test, three popular servers added 12,139 tokens before the model read a word.
- Chat history: every earlier turn, sent again.
- Documents: the page or PDF you attached, or the chunks a RAG system pulled in.
- Room for the answer: output comes out of the same budget.
That’s why AI agents hit limits faster than chatbots. Each tool result joins the pile, and the next model call rereads all of it.
In our agent-versus-prompt test, the agent burned five to nine times as many tokens as a single prompt on the same six questions.

How big are context windows now?
The current top models from all three vendors take about a million tokens.
| Models | Context window | Max output |
|---|---|---|
| Claude Fable 5.2, Opus 5.5, Sonnet 5.5, Haiku 5.5 | 1M tokens | 128K tokens |
| Claude Sonnet 4.5, Haiku 4.5 | 200K tokens | 64K tokens |
| GPT-6.2 Astra, GPT-6.2 Sol, GPT-6 Luna | 1,050,000 tokens (922,000 input max) | 128,000 tokens |
| Gemini 4 Carbon, Argon, Neon, Hydrogen | 1,048,576 tokens, shared with output | 65,536 by default, up to 1M with long decode |
A million tokens holds about 275 copies of our test page as Markdown. As raw HTML, it holds five.
Anthropic says 1 million tokens is about 555,000 words on Claude’s current tokenizer, down from 750,000 on older models. Same window, fewer words.
What happens when you go over?
Each API fails differently.
- Claude: if your input alone is too long, you get a 400 error saying the prompt is too long. If the input fits but the answer runs out of room, generation stops with the stop reason model_context_window_exceeded.
- OpenAI: GPT-6.x models take at most 922,000 input tokens of their 1,050,000 window. Output that runs past the window may be cut off.
- Gemini 4: the API shrinks your output limit to whatever space is left. Send 1,040,000 tokens and you get a short answer, not an error.
Why output tokens cost five times more
On eight of the nine models we priced, an output token costs five times as much as an input token. Gemini 3.5 Flash-Lite is the outlier, at more than eight times.
In our summary job, the answer was about 5% of the tokens and 21% to 30% of the bill.
Reasoning adds a hidden layer: all three APIs bill thinking tokens as output. Our figures assume a 150-word answer with no thinking, so a reasoning model costs more than the table shows.
The fix is a cap. Ask for a length and set a maximum output.
What does one job cost on OpenAI, Claude and Gemini?
We checked every price on the vendors’ own pricing pages on 24 November 2026. All are standard rates per million tokens, in US dollars.
The job: summarise our test page in 150 words. Input is a 32-word instruction plus the page. Output is a 162-word summary we wrote as a stand-in, counted with each vendor’s tokenizer or its closest public match.
| Model | Per 1M tokens (in / out) | One summary | 1,000 summaries |
|---|---|---|---|
| GPT-6.2 Astra | $8 / $40 | $0.037 | $37.29 |
| GPT-6.2 Sol | $2 / $10 | $0.0093 | $9.32 |
| GPT-6 Luna | $0.10 / $0.50 | $0.0005 | $0.47 |
| Claude Opus 5.5* | $4 / $20 | $0.025 | $24.95 |
| Claude Sonnet 5.5* | $2 / $10 | $0.012 | $12.47 |
| Claude Haiku 5.5* | $0.10 / $0.50 | $0.0006 | $0.62 |
| Gemini 4 Neon | $3 / $15 | $0.015 | $14.91 |
| Gemini 4 Hydrogen | $1.50 / $7.50 | $0.0075 | $7.45 |
| Gemini 3.5 Flash-Lite | $0.30 / $2.50 | $0.0017 | $1.70 |
The cheap tier is absurdly cheap. GPT-6 Luna and Claude Haiku 5.5 summarise 1,000 articles for under a dollar. Start summaries and tagging there, and move up only when quality fails.
The same sticker price isn’t the same bill. GPT-6.2 Sol and Claude Sonnet 5.5 both list $2 in and $10 out. On our estimate, Sonnet’s bill runs about 34% higher, because Claude’s tokenizer turns the page into roughly 30% more tokens.
Batch is half price. All three vendors take 50% off jobs that can wait, so a nightly summary run shouldn’t pay full rate.
One date matters for Gemini. Gemini 4 Carbon and Argon cost $2 in and $10 out until 30 November 2026, then double to $4 and $20 on 1 December.
Claude API pricing in 2026: every current model
Claude Sonnet 5.5 costs $2 per million input tokens and $10 per million output tokens. Here’s the full current lineup.
| Model | Input | Output | Cache read |
|---|---|---|---|
| Claude Fable 5.2 | $8 | $40 | $0.20 |
| Claude Opus 5.5 | $4 | $20 | $0.20 |
| Claude Sonnet 5.5 | $2 | $10 | $0.10 |
| Claude Haiku 5.5 (prompt up to 100K) | $0.10 | $0.50 | $0.01 |
| Claude Haiku 5.5 (prompt over 100K) | $0.50 | $2.50 | $0.05 |
| Claude Opus 4.5 to 4.8, Opus 5 | $5 | $25 | $0.50 |
| Claude Sonnet 4.6 | $3 | $15 | $0.30 |
| Claude Haiku 4.5 | $1 | $5 | $0.10 |
Claude Mythos models cost the same as Fable but are limited to verified organisations.
Mind the Haiku 5.5 threshold. Once one prompt passes 100,000 tokens, that whole request costs five times more. Every other current Claude model bills its full 1 million window at the standard rate.
The upgrade maths has a catch. Anthropic says Claude Opus 4.7 and later produce about 30% more tokens for the same text than earlier models.
So Opus 5.5 at $4 looks 20% cheaper than Opus 4.6 at $5. Add the extra tokens and the same text costs about $5.20, so upgrade from 4.6 for quality, not savings. Coming from Opus 4.7 or 4.8, which already use the new tokenizer, the 20% saving is real.
Sonnet comes out ahead. Moving from Sonnet 4.6 at $3 to Sonnet 5.5 at $2 still saves about 13% after the tokenizer change, and cache reads fall from $0.30 to $0.10.
Three more items show up on real Claude invoices:
- Tools add tokens. Any request with tools carries a hidden 286-token system prompt on Sonnet 5.5, Opus 5.5 and Haiku 5.5.
- US-only processing costs 10% more. Setting inference_geo to us applies a 1.1x multiplier on Claude 4.6 and later.
- Batch halves everything. Sonnet 5.5 drops to $1 in and $5 out.
Our take: start API work on Sonnet 5.5. Haiku 5.5 handles high-volume extraction and tagging for pennies. Opus 5.5 earns its price on long, hard tasks where a wrong answer costs more than the tokens.
Prompt caching: the discount with a minimum size
Caching charges a fraction of the input price for text you resend, like a long system prompt or a document users keep asking about.
Our second job: 20 questions about the same page, each sending the full page plus a short question.
| Model | No caching | With caching | Saving |
|---|---|---|---|
| GPT-6.2 Sol | $0.186 | $0.057 | 70% |
| Claude Sonnet 5.5* | $0.249 | $0.081 | 68% |
| Gemini 4 Hydrogen | $0.149 | $0.149 | None: page under the 4,096-token minimum |
Caching cut the OpenAI and Claude bills by about 70%. Gemini’s didn’t move.
Why not? Gemini 4 models only cache prompts of 4,096 tokens or more, and our page came to 3,893. Claude’s newest models cache from 512 tokens and OpenAI’s from 1,024, so the same page qualified on both.
That’s the rule missing from every price list: a cache has a floor. Under it, you pay full price and no error tells you. On Claude, if both cache fields in the response read zero, nothing was cached.
Writing to the cache costs extra: 1.25 times the input price for five minutes on Claude, and for 30 minutes on OpenAI’s current models. It pays off only if you read it again before it expires.
How to cut your token bill
Most savings come from sending less, not from a cheaper model.
Six ways to spend fewer tokens
In the order we'd try them on a real project.
-
Step 1 of 6
Send clean text, not raw pages
Strip menus, scripts and footers before a page reaches the model. Our test page fell from 171,750 tokens to 3,632.
-
Step 2 of 6
Send the relevant part, not the whole library
Retrieval finds the few paragraphs that answer the question and sends only those, instead of the whole document.
-
Step 3 of 6
Turn off tools you don't use
Every connected tool’s description rides along on every message. Three MCP servers cost 12,139 tokens in our test.
-
Step 4 of 6
Put fixed text first so it caches
System prompt, tools and reference documents go at the top, the changing question at the bottom. Make sure the fixed part clears your model’s cache minimum.
-
Step 5 of 6
Cap the answer and batch what can wait
Ask for a length, set a maximum output, and send overnight jobs through the batch API at half price.
-
Step 6 of 6
Route each job to the cheapest model that passes
Let a cheap model tag and summarise, and send only the hard cases to a bigger one.
If those jobs run inside an automation, n8n lets you pick a different model for each step. Our Make vs n8n vs Zapier pricing comparison covers what the automation itself costs.
Frequently asked questions
Disclosure: the n8n and Firecrawl links on this page are affiliate links. If you sign up through one, we may earn a commission at no extra cost to you.
How many tokens is 1,000 words?
About 1,390 tokens on OpenAI’s o200k tokenizer, based on our 2,619-word test page. Google’s rule of 60 to 80 words per 100 tokens gives 1,250 to 1,670. Claude’s current tokenizer runs higher, at roughly 1,800 by Anthropic’s own words-per-token figure.
Do images and PDFs count as tokens?
Yes. Images and PDF pages are converted to tokens and billed like text, but a local tokenizer can’t count them. Use the vendor’s token-counting endpoint, which takes the same request you’d send and returns the input total, including images and files.
Do thinking tokens use up the context window?
Yes. On OpenAI, the context window covers input, output and reasoning tokens. Gemini 4 shares one 1,048,576-token budget across input, thinking and output. Thinking tokens are billed at the output rate on all three APIs, so a model that reasons longer costs more and leaves less room for the answer.
Is tokens per minute the same as the context window?
No. The context window caps one request. Tokens per minute is a rate limit on everything your account sends in a minute, set by your usage tier. GPT-6 Luna, for example, allows 2,000,000 tokens per minute on OpenAI’s entry tier, while one request still tops out at 1,050,000.
Does a bigger context window mean the AI remembers my old chats?
No. The window only covers one request. Chat apps resend recent history each turn, and memory features save notes separately. Once a conversation outgrows the window, the app drops or summarises older turns, which is why long chats lose details from the start.
Why is my API bill higher than my token estimate?
Local counts miss several things. The API adds formatting tokens for message roles, tools add a hidden system prompt of a few hundred tokens, chat apps resend the whole history, and reasoning tokens bill as output. Compare your estimate with the usage figures in each API response.
Is the Gemini API free to use?
Partly. Gemini 4 Hydrogen and the Flash models have a free tier, but Google may use free-tier content to improve its products. Gemini 4 Carbon, Argon and Neon aren’t on the free tier at all. On the paid tier, Google says your content isn’t used that way.
The bottom line
Tokens are what you pay for, and every vendor counts them differently. On clean English text, the counts land within 7% of each other. In Hindi, or on raw HTML, they don’t.
Before you pick an API, count a real sample of your text, check it against the context window you need, and price the output as carefully as the input. For most jobs, a cheap model with caching and batch beats a premium model at full price.
Weighing Claude API pricing against OpenAI? Compare the bill for your own text, not the price per million. Next step: run your longest prompt through a token counter today and multiply it by a month of traffic.



