Context Window Calculator
See how much of a model's context window your text uses.
Processed locally in your browser. Nothing you paste is sent anywhere.
- Turns a raw token count into the number that matters: how much room is left.
- Preset context sizes for common models so you don't have to look them up.
- Runs in your browser — nothing is uploaded.
Why this is private
- Processed locally in your browser. Nothing you paste is sent anywhere.
- Open your browser's DevTools → Network tab while using this tool — you won't see a request carrying your input, because it never leaves your device.
- Nothing you enter is uploaded to a server or shared with us — the processing happens entirely on your device.
Overview
Shows what percentage of a chosen model's context window your text uses, and how many tokens remain.
How to use it
- 1Paste your text.
- 2Choose a model.
- 3View tokens used, remaining and as a percentage of the context window.
Frequently asked questions
What people use it for
Check a long document will fitPaste a transcript or codebase excerpt and see whether it leaves room for the response.
Plan a retrieval budgetWork out how many retrieved chunks you can include alongside the prompt and answer.
Decide whether to switch modelsSee if the content only fits a larger-context model.
Leave headroom for the replyKeep input well below 100% so the model has tokens to answer with.
Related tools
All ai & llm toolsToken CounterExact token counts for OpenAI models, plus calibrated per-model estimates for Claude, Llama, Gemini and Mistral.Prompt ChunkerSplit long text into token-bounded chunks, with optional overlap between them.AI API Cost CalculatorEstimate monthly LLM API costs from token volume.JSONL ValidatorValidate a JSONL (JSON Lines) file line by line.
Ready to use Context Window Calculator?
Context Window Calculator