AI Dojo Open on the typewriterThe typewriter

Explainer

Context window

1 min read
Assumes: you know what a token is.
First published 19 October 2026. Last edited 21 November 2026.

Everything a model can take into account at once, measured in tokens.

When a chatbot writes a reply, the only information about your conversation it can use is what sits in its context window. That includes hidden instructions from the app, the conversation so far, whatever the app passes on from files you added and the reply it is writing. For a long file, that can be only part of it, such as the opening pages or the passages a search picks out (OpenAI's file-upload guide). Anything about your conversation that falls outside the window does not exist for the model at that moment. The window has a maximum size, and when a long chat reaches it, apps drop or summarize older parts. Everything else the model draws on comes from training and stays fixed; the window is short-term and changes with every message. A large window helps, though models do not use every part of a long context equally well.

Going deeper

Liu et al. (2023) found models used relevant information best near the start or end of a long input and worst in the middle (arxiv.org), and Anthropic's documentation calls the general decline in accuracy as context grows "context rot" (platform.claude.com).

Changes

  • 2026-11-21: The page no longer implies that an attached file always reaches the model whole. For a long file, some apps pass on only the start or the parts a search picks out.