Learning Terms
Workflows
Evidence

What Are AI Tokens and Context Windows, and How Do They Affect Cost?

Tokens are the units AI models process and, for usage-based tools, the units you pay for. The context window caps how much the model can consider at once. Longer inputs, longer outputs, and bigger models all cost more, so match the model and the amount of text to the task.

If you only use a chat app with a flat monthly fee, you may never think about tokens. But as soon as AI becomes part of a workflow, such as summarizing every incoming email or drafting a report every night, tokens start to matter. They decide how much the model can handle at once and, for most business tools that connect to AI directly, what you pay.

The good news is that the idea is simple, and a few design choices keep the cost predictable.

What a token is

A token is a small piece of text, often part of a word. Anthropic's pricing documentation gives a rough estimate that one token is "approximately 4 characters or 0.75 words in English." Google gives a similar rule of thumb for its Gemini models: about four characters per token, with 100 tokens equal to about 60 to 80 English words.

The exact count depends on the language, the content, and the model. Anthropic notes, for example, that its newer models use a tokenizer that produces roughly 30% more tokens for the same text, so the same document can count differently on different models.

What a context window is

The context window is the model's working memory for a single request. Anthropic describes it as all the text a model can reference when generating a response, including the response itself. Google describes it as the combined limit of input and output tokens.

Everything counts: your instructions, the conversation so far, any documents you attach, and the answer the model writes. Bigger is not automatically better. Anthropic's documentation warns that as the token count grows, accuracy and recall can degrade, which makes choosing what to include as important as how much fits.

How usage-based pricing works

When a business tool connects to an AI model through an API, the provider usually charges per token. Anthropic, for example, lists its prices per million tokens and prices input and output separately. As of the date this page was checked, its Claude Haiku 4.5 model was listed at $1 per million input tokens and $5 per million output tokens, while larger models cost more. Google notes that the cost of a call to its Gemini API is determined in part by the number of input and output tokens.

Two patterns are common: longer requests and longer answers cost more, and more capable models cost more per token. Providers also offer discounts for some patterns. Anthropic's pricing page, for example, lists a 50% discount for requests that can be processed in batches rather than immediately.

Why this matters for a workflow

A single request usually costs very little. The cost comes from volume and from waste. A workflow that sends a 40-page document to the model every time someone asks a small question, or that uses the most expensive model for simple sorting, can cost many times what it needs to.

Before scaling any AI workflow, run it on a realistic sample, look at the token usage the provider reports, and multiply by your expected monthly volume. That gives you a cost estimate grounded in your own data instead of a guess.

Simple ways to keep costs predictable

  • Use the smallest model that does the job well, and test before assuming you need the largest one.
  • Send only the relevant part of a document, not the whole file, when possible.
  • Ask for the length of answer you actually need.
  • Batch work that does not need an instant answer.
  • Set a monthly budget or usage alert in the provider's dashboard.
  • Review usage monthly, the same way you would review any other utility bill.

If you only use a chat app with a flat monthly fee, you may never think about tokens. But as soon as AI becomes part of a workflow, such as summarizing every incoming email or drafting a report every night, tokens start to matter. They decide how much the model can handle at once and, for most business tools that connect to AI directly, what you pay.

The good news is that the idea is simple, and a few design choices keep the cost predictable.

What a token is

A token is a small piece of text, often part of a word. Anthropic's pricing documentation gives a rough estimate that one token is "approximately 4 characters or 0.75 words in English." Google gives a similar rule of thumb for its Gemini models: about four characters per token, with 100 tokens equal to about 60 to 80 English words.

The exact count depends on the language, the content, and the model. Anthropic notes, for example, that its newer models use a tokenizer that produces roughly 30% more tokens for the same text, so the same document can count differently on different models.

What a context window is

The context window is the model's working memory for a single request. Anthropic describes it as all the text a model can reference when generating a response, including the response itself. Google describes it as the combined limit of input and output tokens.

Everything counts: your instructions, the conversation so far, any documents you attach, and the answer the model writes. Bigger is not automatically better. Anthropic's documentation warns that as the token count grows, accuracy and recall can degrade, which makes choosing what to include as important as how much fits.

How usage-based pricing works

When a business tool connects to an AI model through an API, the provider usually charges per token. Anthropic, for example, lists its prices per million tokens and prices input and output separately. As of the date this page was checked, its Claude Haiku 4.5 model was listed at $1 per million input tokens and $5 per million output tokens, while larger models cost more. Google notes that the cost of a call to its Gemini API is determined in part by the number of input and output tokens.

Two patterns are common: longer requests and longer answers cost more, and more capable models cost more per token. Providers also offer discounts for some patterns. Anthropic's pricing page, for example, lists a 50% discount for requests that can be processed in batches rather than immediately.

Why this matters for a workflow

A single request usually costs very little. The cost comes from volume and from waste. A workflow that sends a 40-page document to the model every time someone asks a small question, or that uses the most expensive model for simple sorting, can cost many times what it needs to.

Before scaling any AI workflow, run it on a realistic sample, look at the token usage the provider reports, and multiply by your expected monthly volume. That gives you a cost estimate grounded in your own data instead of a guess.

Simple ways to keep costs predictable

  • Use the smallest model that does the job well, and test before assuming you need the largest one.
  • Send only the relevant part of a document, not the whole file, when possible.
  • Ask for the length of answer you actually need.
  • Batch work that does not need an instant answer.
  • Set a monthly budget or usage alert in the provider's dashboard.
  • Review usage monthly, the same way you would review any other utility bill.

Questions people also ask

How many words is a token?

Roughly three quarters of a word in English, or about four characters. Anthropic and Google both give similar rules of thumb, but the exact count depends on the model and the text.

Does a bigger context window mean better answers?

Not automatically. A bigger window lets the model consider more text at once, but Anthropic notes that accuracy and recall can degrade as the token count grows. Including only relevant material often works better.

Why do output tokens cost more than input tokens?

Providers set their own prices, and many charge more for generated output than for input. Check your provider's current pricing page, since prices and models change often.

Do chat subscriptions charge by the token?

Many consumer and team chat plans charge a flat fee with usage limits instead. Per-token billing is most common when software connects to a model directly through an API.

How can I estimate what an AI workflow will cost?

Run it on a realistic sample, note the input and output tokens the provider reports, and multiply by your expected monthly volume at the current listed prices. Revisit the estimate when you change models or volumes.

Limits of this guidance

AI prices, models, and tokenizers change frequently. The example price on this page is a snapshot from the access date, not a quote. Always check the provider's current pricing page and your own usage reports before making budget decisions.

Christopher Gallego

Sources

  • Anthropic, Pricing (Claude documentation) (accessed 2026-09-24). Supports pricing per million tokens with separate input and output rates, the Claude Haiku 4.5 prices of $1 per million input and $5 per million output tokens as of the access date, the 50% batch discount, the note that newer models' tokenizer produces roughly 30% more tokens, and the rule of thumb of about 4 characters or 0.75 words per token.
  • Anthropic, Context windows (Claude documentation) (accessed 2026-09-24). Supports the definition of the context window as all text the model can reference including its response, and the note that accuracy and recall degrade as token count grows.
  • Google AI for Developers, Understand and count tokens (Gemini API documentation) (accessed 2026-09-24). Supports the rule of thumb of about 4 characters per token and 100 tokens to about 60 to 80 English words, that cost is determined in part by input and output tokens, and that the context window is the combined limit of input and output tokens.

Related Learning Terms