Allow switching/adding working directories within a Codex CLI session
Resolved 💬 3 comments Opened Mar 9, 2026 by jadchene Closed Apr 2, 2026
What variant of Codex are you using?
CLI
What feature would you like to see?
Description
Currently in Codex CLI the working directory is fixed after starting a session. If I want to switch to another project directory, I have to exit Codex and start it again, which is inconvenient and breaks the workflow.
It would be very helpful to support commands that allow adding or switching working directories within the current session, similar to:
- Gemini CLI:
/directory add - Claude Code:
/add-dir
Suggested commands (example)
/directory add <path>
/directory switch <path>
/directory list
/directory remove <path>
or a simpler version:
/add-dir <path>
/switch-dir <path>
Why this helps
- Avoid restarting Codex just to change directories
- Better workflow when working across multiple repos or folders
- Useful for monorepos or when temporarily referencing another project
Currently, having to exit and restart Codex just to change the working
directory is quite cumbersome.
Additional information
_No response_
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗