Context Window Calculator
See how much of a model's context window your content uses, and how much room is left.
Context budget
Context window usage
6.0%used
Context window
400,000 tokens
Used (content + reserved)
24,000 tokens
Remaining budget
376,000 tokens
Additional messages that fit
752
How this is calculated
used = existing tokens + reserved output tokens. remaining budget = context window − used. Context window sizes are each provider's published maximum for that model.
Pricing is verified against provider pricing pages as of 2026-09-01. AI and cloud pricing changes frequently — confirm the current rate on the provider's own pricing page before budgeting.
Frequently asked questions
What happens when I exceed the context window?
The request fails outright, or (depending on the API) the oldest content is silently dropped — neither is good. Trim history, summarize, or use a model with a larger context window before you hit the limit.
Why reserve tokens for the response?
The model's output also counts against the context window on some APIs, and even where it doesn't, you need room for `max_tokens` — leaving no budget for a response causes a truncated or failed generation.
Does a bigger context window mean better quality?
Not necessarily — a larger window lets you fit more content, but models can still lose track of details in very long contexts ('lost in the middle'). Bigger isn't automatically better for accuracy.
How do I stay under budget in a long conversation?
Summarize or drop older turns, use server-side compaction where the provider offers it, or retrieve only relevant context (RAG) instead of resending the full history every turn.