Free tool · runs in your browser

LLM context length calculator

Context length is one of the first numbers on any model card. Enter a context size and your typical message lengths to see what it means in practice: turns of conversation, words of history and pages of text.

0back-and-forth turns remembered
0words of history
0book pages (~300 words)
0tokens free for history
Budget breakdown

■ system prompt   ■ reply reserve   ■ chat history

Words are converted at ~1.33 tokens per word (typical English). Once history exceeds the free budget, the oldest messages fall out of memory.

Context on model cards vs in practice

Model cards list a maximum context, but local runners often default to a smaller window to save memory. Ollama, LM Studio and llama.cpp all let you raise it, at the cost of more VRAM for the KV cache.

Choosing a context size locally

  • 8K: short chats, minimal memory use.
  • 16K-32K: most chat and role-play.
  • 64K-128K: long documents and campaigns, much more VRAM.

Common questions

Does a larger context use more VRAM?

Yes. The KV cache grows with context length. Use the LLM VRAM calculator to include it in your estimate.

Why does my model forget even with a large context?

Your runner may be using a smaller default context, or the model may recall details in the middle of long prompts less reliably.

Is this calculator exact?

It uses an average of about 1.33 tokens per English word. Different tokenizers vary slightly.

Now pick a model.

Use the directory to find a model that matches your numbers.