Codex CLI Change Model: Keep the Work Context Intact

Change models inside Codex CLI or select one before starting. Save the requirements, unfinished work and verification results so the next response starts from the right facts.

Updated 6 min read

To change the model in Codex CLI, enter /model in the open session, select an available model, and use /status to verify it. To select one when starting Codex, use codex --model MODEL_ID with an available model identifier. Save a short record of the current task before switching so you can check that the next response follows the same requirements.

Tools like fenbs keep requirements and Where we left off outside the AI app, so the work record remains available when you change models or assistants. That record gives you something concrete to compare against the next session’s understanding.

How do you switch models in an open session?

  1. Let the current turn finish, then note what changed and what remains unfinished.
  2. Enter /model in the Codex composer and choose from the models shown. Select a supported reasoning effort if offered; this controls how much reasoning the model applies.
  3. Look for the selection confirmation, then enter /status to check the active model.
  4. Ask for a short restatement of the goal, constraints and next step before allowing further changes.

OpenAI documents the picker and verification commands in its developer commands reference (opens in a new tab). Use the displayed selection as your evidence; a reply saying “I am now using a different model” is not a substitute for the session control.

Choose one change to evaluate. If you also rewrite the instructions and change the task, you cannot tell which change helped. Start with a bounded request, such as explaining the remaining test failure, before returning to a larger implementation.

How do you pick a model before starting Codex?

The startup flag selects a model for that invocation. Replace MODEL_ID below with an identifier available to your account; the placeholder itself is not a model name. The short form is -m. The same reference documents model selection for a non-interactive run, which runs a supplied task without opening the interactive interface.

Shell: choose an available model for a run
codex --model MODEL_ID
codex exec --model MODEL_ID "Read the project instructions and summarize the remaining work. Do not edit files."

Keep the repository folder and task scope explicit when launching a new session. A new terminal in another folder can create a misleading comparison because it starts from different files. The Codex CLI commands guide covers the surrounding commands without making them part of the model-switching procedure.

How do you make the choice your default?

For a lasting default, set the model entry in your Codex configuration. OpenAI’s configuration basics (opens in a new tab) describes the user file at ~/.codex/config.toml and project settings at .codex/config.toml. Use a supported identifier in place of the example placeholder.

Configuration: replace the placeholder before saving
model = "MODEL_ID"

A startup flag takes priority over configuration defaults, and a trusted project’s configuration can override your user default. Check the effective choice after starting in the intended project. Avoid replacing the whole configuration just to change one value; keep other settings and connections intact.

Decide whether you want a personal default or a shared project choice before editing a file that teammates use. The Windows setup guide covers platform setup if locating or starting your installation is the underlying problem.

What should you save before changing models?

Save the information that determines the next action: the goal, the approved constraints, the files changed, the checks performed and the first unfinished step. Keep a proposal separate from a choice someone approved. A model change should not quietly turn a suggested redesign into permission to rebuild the feature.

  • Goal: let users correct a shipping address before submitting an order.
  • Constraint: preserve the existing validation and ask a person before changing which information is collected.
  • Current state: the edit form exists, but the save behavior still needs review.
  • Evidence: describe the exact check that ran and its result, including any failure.
  • Next step: inspect the save behavior before editing another part of the checkout.

This is a hypothetical handoff, not a report of a completed test. Replace it with your own evidence. Include a file path or task reference that the next assistant can inspect, and say when an expected result remains unverified. In fenbs, those requirements and progress belong in the project’s work record, as shown in how it works.

How do you verify that the next response understands the job?

Check understanding against the saved record before judging writing style or speed. Ask the assistant to name the current goal, an important restriction and the next unfinished check. Require it to distinguish information it read from information it still needs to confirm.

A first request after switching
Read the project instructions and saved progress. State the goal, the constraints, what was checked, and the next unfinished step. Point out missing evidence. Do not edit files yet.

For the shipping-address example, a useful answer recognizes that the form exists and the save behavior remains uncertain. An answer proposing a different checkout is a reason to restate the scope. Correct a missing fact in the record so another session can benefit from the same clarification.

Then give the selected model one small task with a clear expected result. Review its actual output and run the appropriate check before expanding the work. The broader Codex CLI best practices explain how to make that review part of everyday work.

Why is the model missing or the result unexpected?

OpenAI’s model documentation (opens in a new tab) explains that availability depends on the rollout, sign-in method and client; workspace settings can also matter. Use the choices available to your session rather than assuming a model name from an older example will work. Our Codex models guide handles the separate question of which model to choose.

Checks that keep selection problems separate from context problems
What you seeWhat to check next
The model you want is absentCheck the official availability guidance and your workspace’s allowed choices.
A launch uses an unexpected modelInspect the launch flag and applicable configuration defaults.
The model changes but the answer misses a requirementCompare the response with the saved constraints and ask it to inspect the missing source.
The answer is fluent but the task still failsReview the changed files and test result against the same acceptance condition.

How to do this with fenbs

  1. Create a free account, then add the project whose work you want to preserve. fenbs is free for one person, no credit card.
  2. Add the current task and its plan. Record the requirements a person approved in Decisions and rules, keeping unresolved choices open.
  3. Connect Codex CLI using its integration guide. The connection uses MCP, a standard way for an AI app to use an outside tool, with a browser sign-in.
  4. Ask the assistant to save task progress and Where we left off before switching. After selecting the model, ask it to read the project context, then verify its account of the remaining work.

fenbs does not select a Codex model or import your chat history. If you only need to change a terminal setting for one short question, the Codex controls are enough. The shared record becomes useful when requirements and unfinished work need to survive repeated sessions or a move to another supported assistant.

How fenbs helps

Give the next model a clear starting point

Keep this project’s requirements, task plan and unfinished checks in fenbs before changing models. Ask the connected assistant to read Rules and Where we left off before continuing, then save the result for the next session.

Create a free account

Free for one person · No credit card · Works with Claude, ChatGPT, Cursor and more

How can you tell whether the switch helped?

Compare the same kind of work against the same requirements. Did the selected model identify the missing evidence, stay within scope and produce a result you could verify? A longer answer is not evidence of better work, and a faster answer is useful only if it still meets the task’s conditions.

Save one concise observation with the task, such as “recognized the untested save path; verification remains next.” Keep model choice and work state separate so you can change one without losing the other. The switching models hub covers other transitions where the same habit applies.

Questions people ask.

Does typing a model name into a prompt change the selected model?

Use the model picker or startup flag, then verify the selection in session status. A conversational claim about model identity is not the same as changing the session setting.

Will switching models prove that my changes are correct?

No. Review the output and run the checks appropriate to the task. The selected model is a setting; test evidence establishes whether the work meets your requirements.

Should I use the same reasoning effort for every model?

Start with a supported default and evaluate a familiar task. OpenAI notes that reasoning efforts do not map exactly between model generations, so matching a label does not guarantee the same behavior.

Can fenbs restore a missing model to my account?

No. Model availability belongs to the AI provider and your workspace. fenbs keeps the project’s work available to supported connected assistants while you choose how to continue.

Start with one thing.

Free for one person · No credit card · Works with Claude, ChatGPT, Cursor and more

There is nothing to set up first. Write one line and you’ve started.