Quick reference
OpenAI Codex cheat sheet
Commands, files, workflows, integrations, and safety concepts in one printable reference.
Slash commands
/status- Show the chat ID, context usage, and rate limits.
/model- Choose the model for the current task.
/plan- Toggle plan mode for multi-step planning.
/compact- Compact the current task context.
/init- Generate an AGENTS.md scaffold.
/mcp- Open MCP server status.
/review- Start code review mode.
/reasoning- Choose the current reasoning effort.
/fork- Copy a local task into a new task or worktree.
/goal- Create a persistent goal after shaping it with /plan.
Files and locations
AGENTS.md- Repository instructions discovered by directory scope.
~/.codex/config.toml- User Codex configuration.
.agents/skills/<name>/SKILL.md- Repository skill definition.
$HOME/.agents/skills- User skill library.
agents/openai.yaml- Optional skill UI, policy, and dependency metadata.
CLI and workflows
codex- Start an interactive CLI session.
codex exec- Run Codex non-interactively.
$skill-creator- Create or update an agent skill.
$skill-installer- Install a curated or repository skill.
Ctrl/Cmd + K- Open this site’s global search.
Safety
Sandbox- Constrains filesystem and network behavior.
Approval- Reviews actions outside the active policy.
Worktree- Isolates Git working state.
Action-time confirmation- Required for external side effects and sensitive transmission.