LIVE|CLI v0.144.0·model GPT-5.6 Sol·verified 2026-07-09
Codex Insider
The unofficial wire for OpenAI Codex.
community-trackedCLIIDEpublished Jul 15, 2026 · facts verified Jul 9, 2026
codex — session
$ codex

Codex ran out of room in the model's context window. Start a new thread or clear earlier history before retrying.

exit code 1
The fix do this first

Your running session filled the context window. Recover it with `/compact` to summarize the transcript and free tokens, or `/new` (fresh task, same CLI session) or `/clear` to start clean. If it fires seconds into a new session, check your config; bad `model_context_window` or `model_auto_compact_token_limit` overrides on a built-in model break auto-compaction. This is the mid-session message, not the single-input limit.

Affected versions: reported CLI v0.80.0 through v0.133.0 and VS Code extension 0.4.49; no fixed-in version

Codex prints this the moment a running session’s history no longer fits the model’s context window. The trigger is accumulation: turns, tool output, and file reads pile up over a long run until they stop fitting, and Codex hard-stops instead of continuing. The generic “one input is too big for a single turn” case lives on a separate page, input exceeds context window. This page covers the runtime string you hit after a long session.

Symptoms

  • The exact string shows up mid-session, often hours in. One reporter ran /goal for several hours on CLI v0.133.0 with gpt-5.5 before it started firing repeatedly (#24247).
  • Retrying the same prompt in the same thread throws it again, because the old history is still loaded.
  • Some people hit it almost immediately on a fresh session (one question in on CLI v0.80.0, #9046), which points at config rather than accumulation.
  • Older IDE builds print slightly different wording, “Start a new conversation…” on VS Code extension 0.4.49 (#7808), versus “Start a new thread…” in the current CLI.

Cause

The running thread’s tokens went past the model’s context window. Codex used to auto-compact (summarize older turns) before hitting the wall; a change reported around June 18 2026 made it hard-stop with this message instead (community thread). Auto-compaction can also just fail to fire during long autonomous runs like /goal (#24247). In one forum case the real cause was broken config: model_context_window and model_auto_compact_token_limit overrides set on a built-in model, where those overrides don’t apply (they only work with custom providers), so compaction never kicked in (auto-compaction thread).

Fix

  1. Run /compact. It summarizes the visible conversation to free tokens and lets you keep the task’s context (docs). Best first move when you don’t want to lose your place.
  2. Run /new to start a fresh task inside the same CLI session, dropping the old history (docs).
  3. Run /clear to wipe the terminal and start a clean task (docs).
  4. Load less next time. Fewer and smaller file reads, and break a multi-hour /goal into staged runs so history has less to accumulate.
  5. If it fires seconds into a new session, audit your config and remove model_context_window / model_auto_compact_token_limit overrides unless you’re actually on a custom provider (auto-compaction thread).

Affected versions

Reported on Codex CLI from v0.80.0 (#9046) through v0.133.0 (#24247), and the VS Code extension 0.4.49 (#7808). No release marks it fixed; the hard-stop behavior showed up around mid-June 2026, so it’s not tied to one version.

Facts on this page verified July 15, 2026.

Sources
  1. openai/codex #24247 — error during /goal on CLI v0.133.0, gpt-5.5
  2. openai/codex #9046 — fires on first question, CLI v0.80.0
  3. openai/codex #7808 — older 'new conversation' wording, VS Code extension 0.4.49
  4. OpenAI Community — behavior changed ~June 18 2026 to hard-stop
  5. OpenAI Community — auto-compaction not triggering (bad config overrides)
  6. OpenAI Codex docs — developer commands (/new, /compact, /clear)