Key takeaways

  • The Codex context window is the number of tokens the active model can hold in one chat, and its size depends on the model.
  • Type /status in the Codex CLI to see remaining context capacity; /compact and /new free it up.
  • Usage limits are a separate plan allowance, which you can watch on the usage dashboard or in a desktop tracker such as UsageAtlas.

The Codex context window is how many tokens the active model can hold in one chat: your instructions, the files it has read, tool output and the conversation so far. It is not the same thing as your Codex usage limit, and mixing the two up is the most common reason people chase the wrong problem.

You can check how full the context is from inside Codex. The size itself depends on the model, which OpenAI changes often, so this piece does not quote a number.

Context window and usage limit are different clocks

A chat can run out of context while your plan still has plenty left, and the reverse happens too.

Context window Usage limit
What it measures Tokens the model can see in this chat How much of your plan is left
Set by The model Your ChatGPT plan
When it resets When you start a new chat or compact On a timer
Where to check /status and the footer in the Codex terminal Usage dashboard on chatgpt.com, /status
What happens when it fills Codex compacts the history Codex stops until reset or credits

How to check the Codex context window

In the Codex CLI, type /status. OpenAI's docs say it shows the active model, approval policy, writable roots and remaining context capacity, along with token usage. The footer of the terminal UI also shows how much context is left as a percentage while you work, and /statusline lets you choose which fields appear there.

If you run Codex through a config file, model_context_window in config.toml sets the context window tokens available to the active model. Most people leave it alone.

What happens when the context fills

Codex does not simply stop. Once the chat passes a token threshold, it compacts the history automatically, summarizing older turns so the work can continue. The threshold uses model defaults unless you set model_auto_compact_token_limit.

You can also do it yourself. /compact summarizes the visible chat to free tokens, and OpenAI suggests it after long runs. /new starts a fresh chat in the same CLI session, which empties the context completely. A summary keeps the key points but drops detail, so for a new task a fresh chat is usually the cleaner choice.

Why a full context costs more than space

Every turn sends the chat back to the model. A context that is close to full means each new message carries a large history with it, and that history counts as tokens against your usage. OpenAI's own tips for making a usage allowance last longer point the same way: smaller prompts, fewer source files, a shorter AGENTS.md and fewer MCP servers. Each one also leaves more room in the context window.

Watching the other clock

The context window is per chat and lives inside Codex. Your usage over days and weeks is a separate question. UsageAtlas, a free and open-source desktop tracker, covers that side: Codex session and weekly windows, reset times, and token history by day and model from your local Codex activity. It does not show the context window size, and it says so plainly, so keep /status for that.

If you only work in short chats and never hit a limit, /status is all you need. A tracker earns its place when you want to know why a week ran out early and which model or project used the tokens.

The short version

Context is working memory for one chat. The usage limit is your plan's allowance over time. Check context with /status, manage it with /compact and /new, and keep an eye on the allowance with the usage dashboard or a desktop tracker such as UsageAtlas for Codex.

Frequently asked questions

How do I check the Codex context window?

Type /status in the Codex CLI. It shows remaining context capacity and token usage. The terminal footer also shows the percentage of context left.

What happens when the Codex context window is full?

Codex compacts the chat history automatically once it passes a threshold. You can also run /compact yourself or start a fresh chat with /new.

Is the context window the same as the Codex usage limit?

No. The context window is per chat and set by the model. The usage limit is your plan allowance and resets on a timer.

Sources

  1. Codex slash commandsOpenAI
  2. Codex config referenceOpenAI
  3. Codex pricing and usage tipsOpenAI
  4. How to check the Codex context windowUsageAtlas