Skip to content
KazamTools

LLM Context Window Checker

Paste text or drop files to see which models can take it in one go, with space left for the reply.

Files are processed in your browser and never uploaded.How it works

The reply shares the window with your prompt. 8,000 tokens ≈ 6,000 words.

0 characters · 0 words

OpenAI o200k_base: 0 tokens

Counted on your device. Your text is not uploaded.

Providers
Context window fit per model
ModelYour textWindowUsedResult
Claude Fable 5.1Anthropic≈01,000,000
0%
—
Claude Opus 5.5Anthropic≈01,000,000
0%
—
Claude Sonnet 5.5Anthropic≈01,000,000
0%
—
Claude Haiku 5.5Anthropic≈01,000,000
0%
—
GPT-6 AstraOpenAI0922,0001,050,000 with output
0%
—
GPT-6.1 SolOpenAI0922,0001,050,000 with output
0%
—
GPT-6 LunaOpenAI0922,0001,050,000 with output
0%
—
GPT-5.6 TerraOpenAI0922,0001,050,000 with output
0%
—
GPT-5.5OpenAI01,050,000
0%
—
GPT-5.4 miniOpenAI0272,000400,000 with output
0%
—
GPT-5.4 nanoOpenAI0272,000400,000 with output
0%
—
Gemini 4 ArgonGoogle (Gemini API)≈01,048,576
0%
—
Gemini 3.8 FlashGoogle (Gemini API)≈01,048,5761,114,112 with output
0%
—
Gemini 3.1 Pro (preview)Google (Gemini API)≈01,048,5761,114,112 with output
0%
—
Gemini 3.5 Flash-LiteGoogle (Gemini API)≈01,048,5761,114,112 with output
0%
—
Gemini 3.1 Flash-LiteGoogle (Gemini API)≈01,048,5761,114,112 with output
0%
—
Mistral Large 4Mistral AI≈01,000,000
0%
—
Mistral Large 3Mistral AI≈0256,000
0%
—
Mistral Medium 3.5Mistral AI≈0256,000
0%
—
Mistral Small 4Mistral AI≈0256,000
0%
—
Codestral 25.08Mistral AI≈0128,000
0%
—
Ministral 3 8BMistral AI≈0256,000
0%
—
DeepSeek V4.1 FlashDeepSeek≈01,000,000
0%
—
DeepSeek V4 ProDeepSeek≈01,000,000
0%
—
Grok 4.7xAI≈0500,000
0%
—
Grok 4.3xAI≈01,000,000
0%
—
Grok 4.20 (non-reasoning)xAI≈01,000,000
0%
—
Grok Build 0.1 (coding)xAI≈0256,000
0%
—

Limits from official model pages, checked 2026-10-22. n/p = not published. * = not confirmed on an official page. Token numbers marked ≈ are estimates; “Tight” means the estimate fits but its upper range does not.

How to use the Context Window Checker

  1. 1Paste your prompt, or switch to Upload files and add .txt, .md, .json or .pdf files.
  2. 2Set how many tokens to keep free for the model’s answer.
  3. 3Read the table: each model shows its window, how much your text uses, and whether it fits.
  4. 4If a model says Too big, split the text into the suggested number of parts or pick a model with a larger window.

What the checker does

A model’s context window is the most text it can handle in one request, measured in tokens. Paste your text or add files, and the checker counts the tokens for each model’s tokenizer. It then compares that number with the model’s published limits and tells you whether it fits, how much of the window it uses, and how many parts you would need if it does not.

On most models your prompt and the model’s answer share the window. So the checker keeps a number of tokens free for the reply (8,000 by default) and tests your text against what is left:

room for your text = min(maximum input, total window − tokens reserved for the answer)

Some providers publish two numbers. OpenAI’s GPT-6 models accept up to 922,000 input tokens inside a 1,050,000-token total. Most Gemini models list a 1,048,576-token input limit and a separate 65,536-token output limit. Gemini 4 Argon, however, shares one 1,048,576-token window between input and output. The checker uses whichever rules the provider states.

Exact counts, estimates and the “Tight” result

For OpenAI models the token count is exact: the page runs the real o200k_base tokenizer in your browser. Anthropic, Google, Mistral, xAI and DeepSeek do not offer browser tokenizers, so their counts are estimates with a likely range. The LLM token counter explains how each estimate is made.

Result Meaning
Fits Even the high end of the estimate fits, with the answer reserved
Tight The estimate fits, but the high end of its range does not. Check with the provider’s own token counter before relying on it
Too big The estimate alone is over the limit. The checker shows how many parts you would need
No limit published The provider does not publish this model’s window

Worked examples

A 300-page book. A typical novel of about 100,000 words is roughly 130,000 tokens in o200k_base. With 8,000 tokens reserved, it fits every model with a window of 256,000 tokens or more. GPT-4o mini (128,000 tokens) has 120,000 tokens of room, so the book needs 2 parts there.

A big codebase dump. Say you paste 3.2 MB of source code. Code runs about 3.5 characters per token in o200k_base, so that is roughly 900,000 tokens. It fits GPT-6.1 Sol’s 922,000-token input limit, but only just. Claude’s current tokenizer produces more tokens for the same text (about 30% more, by our estimate), so the same dump is probably too big for Claude’s 1M window even though the window looks larger. Grok 4.7’s 500,000-token window would need 2–3 parts.

A long chat history. Every turn of a conversation is sent again with each new message. Fifty turns averaging 600 tokens add up to 30,000 tokens before the newest question, which fits everywhere. But if your app also attaches a 150,000-token document to every turn, smaller models drop out quickly.

Tips when text does not fit

  1. Strip the noise. Web pages and PDFs carry menus, footers, page numbers and repeated headers. Converting them to clean Markdown with document to Markdown often cuts 20–50% of the tokens.
  2. Send only what the task needs. For a question about chapter 3, send chapter 3.
  3. Split and summarise. Process each part separately and combine the summaries in a final request (often called map-reduce).
  4. Check the price before you go big. A full 1M-token prompt costs real money on every request. The AI API cost calculator shows the bill, including long-context surcharges.
  5. Leave a margin. System prompts, tool definitions and images also use tokens. Keep 5–10% spare.

Limits and accuracy

Window sizes come from each provider’s official model pages, on the date shown under the table. Providers change limits with new model versions, and some charge more for very long prompts. A filled window can also hurt quality: models tend to pay less attention to the middle of very long inputs. When the result is close, confirm it with the provider’s own counting endpoint: Anthropic’s count_tokens and Gemini’s countTokens are both free to call.

Your text and files are read in your browser and never uploaded. PDF text is extracted with PDF.js on your device. Scanned PDFs have no text layer, so run them through image to text first.

Frequently asked questions

What is a context window?

It is the maximum number of tokens a model can handle in one request. On most models the prompt and the answer share it, so a 1,000,000-token window with a 10,000-token answer leaves 990,000 tokens for your text.

Are the token counts exact?

OpenAI models get exact counts from the real o200k_base tokenizer. Other providers do not publish browser tokenizers, so their counts are estimates with a likely range. When only the top of that range would overflow, the model is marked “Tight”.

Which models have the largest context window?

In our table, dated as checked, Claude, Gemini, GPT-5.5 and GPT-6, Grok 4.3, Mistral Large 4 and DeepSeek V4 accept about 1 million tokens. Older and smaller models range from 128,000 to 500,000 tokens.

Can it read PDFs?

Yes. Text is extracted from the PDF in your browser. Scanned PDFs contain pictures instead of text and need OCR first. A model may count a PDF differently if you send the file itself, because it may also look at the page images.

Are my files uploaded?

No. Files are read on your device. Only the public OpenAI tokenizer vocabulary is downloaded from the jsDelivr CDN, once.

What should I do if my document does not fit?

Remove what the model does not need (navigation text, repeated headers, boilerplate), convert it to clean Markdown, split it into parts and summarise each, or use a model with a bigger window.

Was this tool helpful?