Slash Commands
Use Codex slash commands as an operating surface for sessions, review, models, and status.
Key takeaways
- Slash commands are the control panel of an interactive Codex session, so teams should standardize the ones expected during planning, review, and handoff.
- Group commands by purpose: Status, Review, Planning, Context, and Lifecycle (stop, resume, fork, compact, archive, hand off, or start a new thread).
- Run review commands before requesting human review on risky changes, and keep slash-command output tied to actual verification rather than treating commands as magic words.
- Track the current official inventory:
/app,/copy,/rename,/pets(/pet), and Windows-only/setup-default-sandboxare documented commands;/subagentsand/btware aliases. - Codex 0.148.0 adds
/exportfor the complete TUI conversation. In 0.150.0,/copyopens a picker for the whole response, code blocks, or blockquotes. - Codex 0.149.0 adds
/cd,/pwd, and/cwd; 0.150.0 adds automatic task titles and editable/renamesuggestions. - On 0.146.0,
/new [name]and/clear [name]name fresh threads immediately, while/sidecan switch among open side conversations without closing them. - Follow a repeatable routine: inspect status, attach relevant files, request a plan, review the diff, then run verification and summarize evidence.
Slash commands are the control panel of an interactive Codex session. Teams should standardize the commands they expect developers to use during planning, review, and handoff.
Command Categories
| Category | Purpose |
|---|---|
| Status | Inspect current session, model, permissions, or workspace |
| Review | Ask Codex to examine diffs, risks, and tests |
| Planning | Switch into planning, goal, or structured task mode |
| Context | Attach files, pages, images, or repository references |
| Lifecycle | Stop, resume, fork, compact, archive, delete, hand off, or start a new thread |
Team Practices
- Use review commands before requesting human review on risky changes.
- Record useful command sequences in repository docs.
- Keep slash-command output tied to actual verification.
- Avoid using commands as magic words; define what decision each one supports.
- Treat
/archiveand/deleteas different retention decisions: archive keeps a recoverable transcript, while delete permanently removes the transcript and spawned descendants. - Run
/usagebefore long/goalor multi-agent sessions, and review/importresults with/diffand/debug-config. - Treat
/appas an officially documented handoff command, originally release-tracked from 0.138.0. - Treat
/importas a migration review: 0.145.0 expands it across Cursor and Claude Code settings, MCP servers, plugins, sessions, commands, and project memories. - Review
/exportoutput for secrets and customer data before storing or sharing a full transcript.
Example Routine
- Inspect status and permissions.
- Attach or mention the files that matter.
- Ask for a plan or scoped implementation.
- Review the diff.
- Run verification and summarize evidence.
August 28 Command Inventory Re-check
| Command | Current behavior | Team note |
|---|---|---|
/export | Exports the complete TUI conversation as Markdown | Choose clipboard or file; review sensitive content |
/copy | Opens a picker for the whole response, code blocks, or blockquotes | Check clipboard content before external sharing |
/rename [name] | Renames the task; without a name, offers an editable suggested title | Use a short issue, branch, or purpose prefix |
/cd, /pwd, /cwd | 0.149.0 release-note group for working-directory management; individual reference entries are pending | Inspect the installed slash picker, then record cwd in handoffs and resumed tasks |
/pets [name|off] (/pet) | Chooses or hides an ambient terminal pet | Treat it as display-only personalization |
/setup-default-sandbox | Sets up the elevated Windows sandbox | Appears only in degraded restricted-token mode |
/agent (/subagents) | Opens the agent-thread picker | Review diffs and tests before integration |
/side (/btw) | Starts an ephemeral side chat | Use /fork for longer alternate work |