What is a context window?

A context window is the working memory of a large language model: the maximum amount of text it can consider at one time, measured in tokens. Everything competes for that space at once, including the tool's hidden instructions, the conversation so far, pasted files and errors, and the code the model is reading.

The window is a hard boundary, not a preference. Whatever falls outside it does not exist for the model, no matter how important it was earlier in the session.

What happens when the context window fills up?

Long sessions degrade in a recognizable way: the model forgets early decisions, contradicts its own earlier code, or reintroduces a bug it already fixed. Tools handle overflow by dropping or summarizing older content, so instructions given an hour ago may survive only as a lossy summary, if at all. Practitioners call the gradual quality slide context rot.

The symptom worth recognizing is drift: when a session that started sharp begins producing careless output, the context is usually crowded, not the model suddenly worse.

How do builders work within the limit?

The reliable habits are structural. Starting a fresh session per distinct task keeps the window relevant. Restating the goal and key constraints at the top of a new session, or keeping them in a project file the tool re-reads, gives every session the same source of truth. Pasting only the relevant error rather than entire logs preserves space for what matters.

When a conversation has drifted, a short recap prompt beats pushing on: summarizing what's decided and what's next effectively resets the working memory around the right things.