Skip to content

Codex Commands and Shortcuts

Command reference75 commands, 45 with a worked example Facts checked against OpenAI's own pages on November 18, 2026

This page lists the commands of Codex, OpenAI's artificial intelligence (AI) agent for software and technical work, and then keyboard shortcuts and symbols, for Codex and for ChatGPT. In Codex you type a command starting with a slash, such as /plan, in the same box as your requests; a few, such as codex doctor, are typed in the terminal instead. Many commands work both in the Codex command-line interface (CLI) and in the Codex view of the ChatGPT desktop app; where a command works in only one place, or differs between them, its description says so. Every command a student, faculty member, or staff member is likely to use has a worked example below, grouped by what it helps with: a small, realistic situation, what you type, and what you then see, drawn from OpenAI's documentation. Commands that only a software developer would need are listed under More Commands, Mostly for Developers, without examples.

Plans and models are on the ChatGPT (OpenAI) page, with how Codex asks before acting. A listing here is not an endorsement, and for work at the American University of Antigua, the AI Responsible Use Policy applies.

Starting and Ending a Session

codex Starts Codex in the terminal, in the folder you are in; the first run asks you to sign in.

A faculty member has installed the Codex CLI and wants help tidying a copy of a folder of microbiology lecture notes.

Codex

codex

  • The first time, a choice of sign-in methods that includes Sign in with ChatGPT
  • The Codex composer, ready for a first request such as: Tell me about this project

OpenAI suggests a Git checkpoint before and after a task, so changes can be undone; working on a copy of the notes keeps the originals untouched.

Codex works on the folder you start it in, so where you launch it decides what it can see. An illustration drawn from OpenAI's documentation, not a screenshot.

/init Drafts an AGENTS.md file, the standing instructions Codex reads before any work in that folder.

A block director keeps a folder of cardiovascular study guides and wants every session to follow the same house rules: US English, objectives that start with a measurable verb, Word formatting left alone.

Codex

/init

  • Codex writes an AGENTS.md scaffold in the current folder

Review the draft and add your own rules; Codex reads the file at the start of each session.

Rules written once in AGENTS.md save repeating them in every request. An illustration drawn from OpenAI's documentation, not a screenshot.

/status Shows the session's model, approval policy, writable folders, and context use (in the desktop app, the chat ID, context use, and rate limits).

Before asking Codex to rename files in a copied anatomy lab folder, a faculty member checks which folders it can write to.

Codex

/status

  • A summary of the active model, the approval policy, the folders Codex can write to, and current token usage

Run it again after /model or /permissions to confirm the change took effect.

It confirms Codex is working where you expect before anything changes. An illustration drawn from OpenAI's documentation, not a screenshot.

/app Moves the current terminal session into the ChatGPT desktop app on Windows or macOS (CLI).

A course coordinator started reorganizing a reading list in the terminal and would rather review the results in the desktop app.

Codex

/app

  • The desktop app opens the same saved chat, ready to continue

If the app is not installed or running, Codex shows an error asking you to install or launch it; codex app, typed in the terminal, opens the app or its installer.

You keep the same conversation while moving to the view that suits the task. An illustration drawn from OpenAI's documentation, not a screenshot.

/logout Signs out of Codex and clears the saved sign-in on this computer (CLI).

A student used Codex on a shared computer in a library study room and is about to leave.

Codex

/logout

  • Codex clears the local credentials for this user

From the terminal, codex logout does the same.

The next person at the computer cannot use your account or your plan's allowance. An illustration drawn from OpenAI's documentation, not a screenshot.

/quit Leaves Codex (also /exit, or Ctrl+C; CLI).

A faculty member has finished drafting tutorial questions with Codex and wants to close the terminal.

Codex

/quit

  • Codex exits immediately

OpenAI's reference advises saving or committing important work first.

The session is saved, so /resume can reopen it later. An illustration drawn from OpenAI's documentation, not a screenshot.

Staying in Control

/permissions Sets what Codex may do without asking first, such as switching between Auto and Read Only (CLI; the desktop app and editors use the control below the composer).

A course director opens Codex in a folder of exam-item drafts and wants it to read and report, changing nothing yet.

Codex

/permissions

  • A picker of approval presets, such as Auto and Read Only, plus any custom permission profiles
  • Codex announces the updated policy; later actions follow it until you change it

In the desktop app and editors, the same choice is the permissions control below the composer, with Ask for approval, Approve for me, and Full access.

Read Only lets an agent survey a folder before you trust it with edits. An illustration drawn from OpenAI's documentation, not a screenshot.

/plan Switches the chat into plan mode, so Codex proposes a plan before doing anything; you can add your first request on the same line.

A pathology course coordinator wants 40 renal case files sorted into weekly folders, but wants to see the plan first.

Codex

/plan Propose how to sort the renal case files into weekly folders without changing any file's contents

  • Codex enters plan mode and treats the text as the first planning request

/plan is unavailable while Codex is already working. In the desktop app, /plan turns plan mode on or off.

You see and correct the plan before any file moves. An illustration drawn from OpenAI's documentation, not a screenshot.

/approve Retries, once, an action that automatic review recently denied.

With automatic review on, a faculty member asked Codex to download a public dataset of vaccination schedules, and the reviewer blocked the download.

Codex

/approve

  • Codex shows the denied action and asks you to confirm the retry
  • Codex retries that action once, under the current session policy

Automatic review is the Approve for me mode (Auto-review in the CLI), in which a reviewer checks requests in your place within the same boundary.

You stay the final judge when the automatic reviewer is overcautious. An illustration drawn from OpenAI's documentation, not a screenshot.

/setup-default-sandbox On Windows, sets up the elevated sandbox when Codex is using the degraded one it falls back to (CLI).

On a faculty member's Windows laptop, Codex reports that it is using a degraded sandbox and offers the elevated setup.

Codex

/setup-default-sandbox

  • An administrator setup flow for the elevated Windows sandbox
  • Codex configures it and selects the matching automatic approval preset

The command appears only on Windows, when Codex is using the degraded restricted-token sandbox. OpenAI says the elevated sandbox needs administrator-approved setup, so on a university-managed laptop IT may need to approve it. On Windows 11 devices that support Microsoft's built-in process isolation (MXC), Codex can use that instead, without administrator setup.

The sandbox is what keeps Codex's commands inside the folder you chose. An illustration drawn from OpenAI's documentation, not a screenshot.

/delete Permanently deletes the current session's transcript, and any sessions spawned from it (CLI); Codex then returns to its list of chats, or exits if it is not using its shared background server.

A faculty member ran a one-off session on a borrowed skills-lab computer and does not want its transcript left there.

Codex

/delete

  • Codex asks you to confirm deleting the current session
  • The transcript is deleted; Codex returns to its list of chats, or closes

/archive hides a session and keeps its transcript instead. From the terminal, codex delete removes a saved session by name or ID.

It removes a transcript from the computer for good, when archiving is not enough. An illustration drawn from OpenAI's documentation, not a screenshot.

/worktree Runs the chat in a new Git worktree, keeping its changes apart from your current checkout (desktop app, editors, and CLI).

A curriculum office keeps its clerkship guide in a Git-tracked folder and wants Codex's restructuring kept apart from the version colleagues use until it has been reviewed.

Codex

/worktree

  • A choice: start a new chat in a new worktree, or continue this conversation in one
  • Codex creates a managed Git worktree and continues the chat there

It needs a local Git repository and cannot start while a task is running; Browse worktrees lists the existing ones and the chats they belong to.

The folder your colleagues use stays as it was while Codex works in the separate copy. An illustration drawn from OpenAI's documentation, not a screenshot.

Checking the Work

/diff Shows the folder's uncommitted Git changes, including new files Git is not yet tracking (CLI).

A course coordinator keeps the module handbook in a Git-tracked folder, as OpenAI suggests, and checks exactly what Codex changed before sharing it.

Codex

/diff

  • Staged changes, unstaged changes, and new untracked files, which you scroll through in the terminal

In the desktop app, the review pane (Ctrl+Shift+G on Windows) shows the folder's Git changes, opening on the unstaged ones.

You review every change yourself before anyone else sees it. An illustration drawn from OpenAI's documentation, not a screenshot.

/review Asks Codex to review changes in a Git folder and report problems without changing any file (in the desktop app and editors, uncommitted changes or a base branch).

A course coordinator keeps lecture handouts in a Git repository and has just had Codex revise 30 of them; they want a second look before committing.

Codex

/review

  • A menu of review presets
  • Review against a base branch
  • Review uncommitted changes
  • Review a commit
  • Custom review instructions
  • Codex reads the selected changes and reports prioritized findings in the transcript, without changing the files

Review uncommitted changes covers staged, unstaged, and new files. Custom review instructions focuses the review on criteria you give, such as the department's item-writing rules; read each change with /diff as well.

A separate review pass catches unintended edits before they are kept. An illustration drawn from OpenAI's documentation, not a screenshot.

/copy Copies a response, a code block, or a quote to the clipboard, chosen from a menu (CLI; Ctrl+O copies the latest finished response directly).

Codex has summarized its changes to the year-two course materials folder, and the faculty member wants to paste the summary into an email to the curriculum committee.

Codex

/copy

  • A choice of the whole response, a code block, or a quote from the latest completed response; the one you pick is copied to the clipboard

Ctrl+O copies the whole latest completed response without the menu.

No need to select long terminal output by hand. An illustration drawn from OpenAI's documentation, not a screenshot.

Managing Context

/compact Summarizes the chat so far to free space in a long session.

After two hours restructuring a clinical skills handbook, a faculty member wants to keep going in the same chat.

Codex

/compact

  • Codex offers to summarize the chat so far, and you confirm
  • Earlier turns are replaced with a concise summary that keeps the critical details
A long session keeps going without starting over. An illustration drawn from OpenAI's documentation, not a screenshot.

/new Starts a fresh chat in the same session and folder, optionally named.

Having finished editing anatomy quiz items, a student wants a clean start on pharmacology flashcards in the same folder.

Codex

/new pharmacology flashcards

  • A fresh chat starts in the same session, named by the text you typed

Unlike /clear, /new leaves the terminal view as it is.

Unrelated tasks do not share context, which keeps answers focused. An illustration drawn from OpenAI's documentation, not a screenshot.

/clear Clears the terminal and starts a fresh chat (CLI).

A teaching assistant's terminal is full of output from a long file-renaming job, and the next task is unrelated.

Codex

/clear

  • The terminal clears, the visible transcript resets, and a fresh chat starts in the same session

Ctrl+L only clears the view and keeps the current chat. Codex disables both while a task is in progress.

A clean screen and a clean context for the next job. An illustration drawn from OpenAI's documentation, not a screenshot.

/side Opens a temporary side chat for a quick question without disturbing the main chat (also /btw in the CLI).

While Codex rewrites a module's learning objectives, a faculty member wants a quick check on one of them.

Codex

/side Does "understand the renin-angiotensin system" use a measurable verb?

  • A side chat opens, with a transcript separate from the main chat
  • The main chat's status stays visible, so you can see whether it is still running
Quick questions stay out of the main task's context. An illustration drawn from OpenAI's documentation, not a screenshot.

/fork Copies the current chat into a new one, optionally in a new Git worktree, so you can try another approach and keep the original.

Codex has proposed a plan for a case library organized by organ system, and the instructor wants to explore a plan organized by presenting complaint without losing the first.

Codex

/fork

  • Codex copies the chat into a new chat with a fresh ID, leaving the original transcript untouched

To fork an earlier saved session instead, run codex fork in the terminal.

Two approaches can be compared without losing either. An illustration drawn from OpenAI's documentation, not a screenshot.

/memories Sets whether this chat can use Codex's saved memories, and whether it can add to them.

A faculty member has Codex memories turned on and is about to try an unusual layout for a single handout that should not shape later sessions.

Codex

/memories

  • Choices for whether this chat can use existing memories, and whether it can feed future ones

Codex memories are off until you turn them on (in the desktop app, Settings, Personalization). The choice applies to this chat and leaves your overall setting alone.

You decide which work shapes later sessions; OpenAI advises keeping rules that must always apply in AGENTS.md. An illustration drawn from OpenAI's documentation, not a screenshot.

Finding and Organizing Chats

/resume Reopens a saved chat from your session list (CLI).

Yesterday a faculty member started reorganizing a folder of teaching cases; today they want to continue.

Codex

/resume

  • A picker of saved sessions
  • Codex reloads the chosen chat's transcript, with its history intact

From the terminal, codex resume --last reopens the most recent chat in the current folder.

You pick up where you left off instead of explaining it all again. An illustration drawn from OpenAI's documentation, not a screenshot.

/rename Renames the current chat.

A course director has several Codex chats with similar names and wants this one easy to find next week.

Codex

/rename Year 2 renal block question review

  • Codex updates the saved chat name without changing the transcript
A clear name makes the chat easy to find later. An illustration drawn from OpenAI's documentation, not a screenshot.

/pin Pins or unpins the current chat, where available (desktop app).

In the desktop app, a clerkship coordinator returns to the same rotation-schedule chat every week.

Codex

/pin

  • The chat is pinned, or unpinned if it already was

Pinning changes only where the chat appears in the sidebar, not what Codex can reach. Ctrl+Alt+P does the same on Windows.

A chat you use every week stays easy to reach. An illustration drawn from OpenAI's documentation, not a screenshot.

/project Chooses the project that new chats start in (desktop app and editors).

A faculty member keeps a separate project for each course and is about to start work on the neuroscience block.

Codex

/project

  • A picker of projects; new chats start in the one you choose

Ctrl+Alt+Shift+O opens the same project picker in the desktop app on Windows.

Each new chat starts with the right course folder and its context. An illustration drawn from OpenAI's documentation, not a screenshot.

/chat Starts the next new chat without a project (desktop app).

In the middle of course work, a faculty member has a quick, unrelated question that should not sit inside the course project.

Codex

/chat

  • The next new chat is set to start without a project
Unrelated questions stay out of a course project's history. An illustration drawn from OpenAI's documentation, not a screenshot.

/archive Archives the current chat and keeps its transcript; in the CLI, Codex then returns to its list of chats, or exits if it is not using its shared background server.

At the end of the semester, a course director wants last term's Codex chats out of the session list without losing them.

Codex

/archive

  • In the CLI, Codex asks you to confirm archiving the session
  • The session leaves the active list; its transcript stays on the computer

To bring it back in the CLI, run codex unarchive with the session's name or ID (codex archive works from the terminal too); in the desktop app, restore it from Settings, Archived chats.

The list stays short, and nothing is lost. An illustration drawn from OpenAI's documentation, not a screenshot.

Model, Effort, and Usage

/model Chooses the model for the current chat (in the CLI, its reasoning effort too).

A student wants a quick, low-cost model to reformat a reference list for a pharmacology assignment.

Codex

/model

  • A picker listing only the models available to your account, such as gpt-6-luna or gpt-6.1-sol
  • Codex confirms the new model in the transcript

In the CLI, More reasoning… in the picker shows a model's Max or Ultra options. Run /status to confirm the change.

Matching the model to the task saves allowance; OpenAI suggests Luna for clear, repeatable tasks. An illustration drawn from OpenAI's documentation, not a screenshot.

/reasoning Chooses how hard the model reasons in the current chat (desktop app and editors).

In the desktop app, a curriculum lead asks Codex to reconcile two versions of the year-one curriculum map and wants more careful reasoning than usual.

Codex

/reasoning

  • A choice of reasoning efforts for this chat, from Light to Extra High, with Max or Ultra where your model and settings allow

Beneath the composer, the Power setting offers presets of model and effort; move toward Smarter or Faster, or open Advanced to choose a model, effort, or speed. Ultra splits a task across helpers working in parallel; GPT-6 Luna goes up to Max, not Ultra. If Ultra is missing from the slider, turn it on under Settings, then Configuration.

OpenAI advises starting at the default and raising effort only for work that needs more planning or checking. An illustration drawn from OpenAI's documentation, not a screenshot.

/fast Turns the current model's Fast speed on or off, when the model offers one.

A staff member needs Codex to reformat a long event schedule before a meeting starts and wants quicker replies.

Codex

/fast

  • Codex turns the Fast tier on and saves the choice; /fast again turns it off

Fast draws on your allowance faster than Standard speed (2.5 times, by OpenAI's help article on Pro plans). If the model has no Fast tier, /fast does not appear.

Useful when waiting matters more than allowance. An illustration drawn from OpenAI's documentation, not a screenshot.

/usage Shows your account's token use (daily, weekly, or overall) or redeems an earned reset; in the desktop app, it opens usage and billing settings.

A student on Plus wants to know how much of this week's allowance is left before starting a big reorganization of study notes.

Codex

/usage weekly

  • Your account's token activity for the week

Plain /usage opens a menu to show activity or redeem an available earned reset.

Checking first avoids running out partway through a large task. An illustration drawn from OpenAI's documentation, not a screenshot.

/statusline Chooses and orders the items in the terminal's footer, such as model, context, limits, and Git branch (CLI).

A researcher running long Codex sessions wants the model and the remaining usage limits in view at the bottom of the terminal.

Codex

/statusline

  • A list of footer items to pick and reorder: model, context, limits, Git branch, tokens, and session
  • The chosen items appear in the footer

The choice is saved in Codex's settings file (config.toml), so later sessions keep it.

You see a limit approaching instead of meeting it partway through a task. An illustration drawn from OpenAI's documentation, not a screenshot.

codex update Checks for a newer Codex CLI and installs it, when your installed release supports updating itself (typed in the terminal).

GPT-6.2 Astra is missing from a faculty member's model picker, and OpenAI's help says to update Codex CLI to the latest version for the GPT-6.2 models.

Codex

codex update

  • Codex checks for an update and applies it

Running the install command you first used again (from OpenAI's Codex CLI page, or npm) also updates Codex.

New models and fixes often need the latest release. An illustration drawn from OpenAI's documentation, not a screenshot.

Files, Skills, and Connections

/mention Attaches a file or folder to the chat so follow-up requests refer to it directly (CLI; typing @ does the same).

A course director wants Codex to check one syllabus against the block calendar.

Codex

/mention syllabus/MED201-syllabus.docx

  • A popup of matching paths, from which you select the file
  • Codex adds the file to the chat, so follow-up turns refer to it directly
Pointing at the exact file saves Codex guessing which document you mean. An illustration drawn from OpenAI's documentation, not a screenshot.

/import Brings a Claude Code or Cursor setup, project files, and recent chats into Codex (CLI).

A faculty member has used Claude Code for a semester, with a file of course rules, and is trying Codex on the same folder.

Codex

/import

  • An import picker
  • Claude Code
  • Cursor
  • You select the setup, project files, or recent chats to bring over, and Codex imports them into its own configuration and files

It looks back at up to 50 chats from the last 30 days, and is unavailable while a task is running.

Rules you already wrote carry over instead of being rewritten. An illustration drawn from OpenAI's documentation, not a screenshot.

/skills Lists skills and applies one to your next request (CLI; in the desktop app, skills appear in the slash list and on the Skills page).

A department has written a skill that formats new exam items in its house style (a hypothetical skill, for illustration).

Codex

/skills

  • A list of skills to choose from
  • Codex inserts the chosen skill's context, so the next request follows its instructions

Typing $ and the skill's name before a request does the same. OpenAI bundles a few skills, such as skill-creator for writing your own.

A skill applies a repeatable process the same way every time. An illustration drawn from OpenAI's documentation, not a screenshot.

/apps Browses connected apps and inserts one into your request as a $ mention (CLI).

A course coordinator wants Codex to work from the current timetable in a connected Google Drive before updating a schedule.

Codex

/apps

  • A list of apps
  • Codex inserts the chosen app into the composer as $ and its name, ready for your request
Naming the app tells Codex exactly where to look. An illustration drawn from OpenAI's documentation, not a screenshot.

/plugins Browses installed and available plugins (CLI).

Before starting a course-materials task, a faculty member wants to see which plugins are installed and what each one can do.

Codex

/plugins

  • The plugin browser, with installed plugins, plugins your configuration lets you discover, and each one's state

Press Space on an installed plugin to turn it on or off.

You see what Codex can reach before relying on it. An illustration drawn from OpenAI's documentation, not a screenshot.

/mcp Lists the outside tools (Model Context Protocol, or MCP, servers) Codex can call in this session; in the desktop app and editors, it opens MCP status.

An instructor's IT team has connected a documentation server, and the instructor wants to confirm Codex can use it.

Codex

/mcp

  • The configured MCP servers and tools Codex can call in this session

/mcp verbose adds detailed diagnostics for each server.

Before relying on a connection, confirm it is there. An illustration drawn from OpenAI's documentation, not a screenshot.

Long Jobs and Troubleshooting

/goal Sets a goal Codex keeps working toward across turns; you can view, edit, pause, resume, or clear it.

A faculty member wants all twelve weekly study guides moved onto the new departmental template, with a list of any guide that has no learning objectives.

Codex

/goal Convert all 12 weekly study guides to the new template and list any guide with no learning objectives

  • Codex keeps the goal attached to the chat while the work continues

In the desktop app, goal progress appears above the composer, with buttons to pause, resume, edit, or clear it. A goal can be up to 4,000 characters; for longer instructions, point it at a file.

A goal keeps a long, many-file job on track across turns, and you still review the result. An illustration drawn from OpenAI's documentation, not a screenshot.

/subagents Switches between Codex's helper (subagent) threads so you can inspect or continue one (CLI). The similar /agents opens the agent command center, a list of all chats on Codex's shared background server.

A faculty member asked Codex to split a check of 200 practice questions across helpers, one per organ system, and wants to see how the cardiology helper is doing.

Codex

/subagents

  • A picker of agent threads
  • Codex switches to the chosen thread, showing that helper's work

Helpers use more of your allowance than a single agent, since each does its own work.

You can check a helper's work before its summary reaches the main chat. An illustration drawn from OpenAI's documentation, not a screenshot.

/ps Shows the commands Codex is running in the background, with their latest output (CLI).

Codex started a long conversion of lecture slides to PDF in the background, and the faculty member wants to know how far it has got.

Codex

/ps

  • Each background terminal's command, with up to three recent lines of its output

The list may be empty, depending on how Codex runs commands on your computer.

You can check progress without interrupting the main chat. An illustration drawn from OpenAI's documentation, not a screenshot.

/stop Stops every background command started in this session (also /clean; CLI).

The slide conversion is no longer needed, because a colleague has already sent the PDFs.

Codex

/stop

  • Codex may ask you to confirm, then stops all background terminals for this session
It cancels unneeded work without ending the session. An illustration drawn from OpenAI's documentation, not a screenshot.

/feedback Sends feedback, and optionally logs, to the Codex team at OpenAI (in the desktop app and editors, through a feedback dialog).

Codex keeps failing at the same step on a faculty member's laptop, and they want to report it.

Codex

/feedback

  • Prompts to describe the problem and to choose whether to include logs or diagnostics
  • Codex collects what you chose and submits it
The report reaches the team with the details they need to investigate. An illustration drawn from OpenAI's documentation, not a screenshot.

codex doctor Writes a diagnostic report on the Codex installation, settings, sign-in, and connections (typed in the terminal).

After a Windows update, Codex will not start properly on a faculty laptop.

Codex

codex doctor

  • A local report checking installation, configuration, sign-in, runtime, Git, the terminal, and other parts

OpenAI's help suggests it on Windows for startup, connection, and performance problems.

The first step before asking IT for help or filing a support request. An illustration drawn from OpenAI's documentation, not a screenshot.

More Commands, Mostly for Developers

/ide Adds open files, the current selection, and other editor context to the next request (CLI).

/ide-context Turns shared editor context on or off (desktop app and editors).

/local Runs the chat in the selected local project, rather than in the cloud (desktop app and editors).

/cloud Runs the chat in Codex Cloud, when cloud execution is available (desktop app and editors).

/cloud-environment Chooses the Codex Cloud environment for the chat (desktop app and editors).

/hooks Shows lifecycle hooks, and trusts, turns off, or turns back on the ones you manage (CLI).

/debug-config Prints the configuration layers and policy requirements, to explain why a setting differs from your configuration file (CLI).

/experimental Turns experimental features on or off, such as Network proxy or Prevent sleep while running (CLI).

/keymap Remaps the terminal interface's keyboard shortcuts and saves them (CLI).

/vim Turns Vim-style editing in the composer on or off (CLI).

/raw Turns raw scrollback on or off, for plainer selecting and copying of long output; Alt+R does the same (CLI).

/theme Chooses a syntax-highlighting theme for code and diffs in the terminal (CLI).

/title Chooses the items shown in the terminal window or tab title (CLI).

/pets Chooses or hides a terminal pet (also /pet; in the desktop app, /pet wakes or tucks away the desktop pet).

codex login Signs in from the terminal with a ChatGPT account, a device code, an API (application programming interface) key, or an access token; Codex also asks you to sign in on first run.

codex exec Runs a task without interaction, for scripts and automated pipelines (short form codex e).

codex review Runs a code review without interaction, against uncommitted changes, a base branch, a commit, or your own instructions.

codex cloud Browses or starts Codex Cloud tasks from the terminal (codex cloud exec submits one, codex cloud list lists recent ones; also codex cloud-tasks); experimental.

codex apply Applies the latest changes from a Codex Cloud task to your local working copy (short form codex a).

codex mcp Lists, adds, removes, and signs in to MCP servers in Codex's configuration file.

codex plugin Installs, lists, and removes plugins; codex plugin marketplace manages the sources they come from.

codex sandbox Runs any command inside the same sandbox Codex uses, on macOS, Linux, or Windows.

codex execpolicy Checks command-rule files and shows whether a command would be allowed, prompted, or blocked (experimental).

codex features Lists feature flags and turns them on or off in Codex's configuration file.

codex completion Generates tab-completion scripts for Bash, the Z shell, Fish, or PowerShell.

codex app-server Starts Codex's app server, for local development and debugging (experimental).

codex remote-control Runs or manages remote control for the local app server, or creates a short-lived pairing code (experimental).

codex debug Debugging tools that send a test message through the app server, print the model catalog Codex sees, or show the exact input the model receives (experimental).

chatgpt.newChat In VS Code and similar editors, starts a new Codex chat (Ctrl+N on Windows); chatgpt.openSidebar, chatgpt.newCodexPanel, and chatgpt.openCommandMenu open the sidebar, a new panel, or the command menu.

chatgpt.addToThread In VS Code and similar editors, adds the selected text to the current Codex chat; chatgpt.addFileToThread adds the whole file.

Shortcuts and Symbols

Keys What They Do
Enter While Codex is working in the CLI, sends new instructions into the current turn.
Tab While Codex is working in the CLI, queues a message, slash command, or shell command for the next turn.
Esc Esc On an empty prompt in the CLI, edits your previous message and forks the chat from that point.
Ctrl+R Searches your earlier prompts in the CLI.
Ctrl+O Copies the latest finished response in the CLI, without the /copy menu.
Ctrl+G Opens your text editor for writing a long prompt in the CLI.
Ctrl+L Clears the terminal view in the CLI but keeps the current chat.
Alt+1, Alt+2, Alt+3 In the desktop app on Windows, switches to Chat, Work, or Codex (Control+1 to 3 on a Mac).
Enter or Esc In the desktop app, approves or declines an open approval request.
Ctrl+Shift+N In the desktop app, starts a temporary chat (Command+Shift+N on a Mac).
Ctrl+Alt+N In the desktop app, opens a quick chat for a short question (Command+Option+N on a Mac).
Ctrl+Shift+M In the desktop app, opens the model picker (Control+Shift+M on a Mac).
Ctrl+Shift+G In the desktop app, opens Codex's review tab to inspect changes (Control+Shift+G on a Mac).
Ctrl+K In the desktop app, opens the command menu (Command+K on a Mac).
Ctrl+/ In the desktop app, lists the keyboard shortcuts (Command+/ on a Mac); change them under Settings, Keyboard Shortcuts.
Type What It Does
@ In the Codex CLI, searches for a file in the folder and adds its path to your request.
! At the start of a line in the Codex CLI, runs a shell command yourself, under the current approval and sandbox settings.
$ In Codex, names a skill to use, such as $skill-creator; /apps inserts apps the same way.
@ In ChatGPT Chat and Work, points to a plugin or skill, such as @Google Drive or @skill-creator.
/Deepresearch Typed in a ChatGPT message, starts a deep research task.