Codex for beginners: reopen the right chat with codex resume
You closed the terminal partway through a task and want to continue the conversation with Codex. With codex resume, you choose a saved chat instead of starting a new one. Use it when you want to return to an earlier discussion about the same project.
This micro-guide covers Codex CLI, the terminal version. You need Codex installed and signed in, plus a saved interactive chat. If you need to get started, follow OpenAI's Codex CLI instructions.
Resume the right Codex session in three steps
- Open a terminal in your project folder. Choose the project the conversation belongs to, rather than whichever folder your terminal opens in.
- Run
codex resume. The command opens a picker for saved chats. Choose the conversation you want to continue. - Check the conversation and working directory. Read the recent turns before giving the next task. If your directory differs from the saved session's, Codex may ask which directory to use. Settings can affect that choice.
The expected outcome is that you continue the selected chat with its earlier conversation as context. You have not started a completely new discussion.
Source: OpenAI's codex resume command reference.
Open the most recent chat without the picker
Run codex resume --last to skip the picker and open the most recent chat in the current directory. That directory restriction applies when you do not also use --all. Start with the ordinary picker if several conversations could be relevant.
Resuming a chat does not restore files
codex resume is not a file rollback command. Your project files may have changed since the conversation was saved. Check their current contents before building on an old discussion.
A useful first task is: "Read the project's current files and summarize what remains of the task we discussed. Do not change anything yet."
This explanation was verified against current official documentation. The images and video are illustrations, not a recording of a resumed session.
The Forge newsletter
Get new articles in your inbox
Pick the topics you care about. No noise, at most one email a week.
We follow GDPR. Unsubscribe anytime.