SpyBara
Go Premium

Documentation 2026-08-02 21:00 UTC to 2026-08-03 23:00 UTC

11 files changed +34,919 −1,903. View all changes and history on the product overview
2026
Tue 4 07:01 Mon 3 23:00 Sun 2 21:00

cli/reference.md +190 −871

Details

1# Developer commands1# Commands

2 2 

3> For the complete documentation index, see [llms.txt](https://learn.chatgpt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to the page URL.3> For the complete documentation index, see [llms.txt](https://learn.chatgpt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to the page URL.

4 4 

5## How to read this reference5Use these commands and keyboard shortcuts to navigate the app.

6 6 

7This page catalogs every documented Codex CLI command and flag. Use the interactive tables to search by key or description. Each section indicates whether the option is stable or experimental and calls out risky combinations.7## Keyboard shortcuts

8 8 

9The CLI inherits most defaults from `~/.codex/config.toml`. Any9| | Action | Shortcut |

10 `-c key=value` overrides you pass at the command line take10| ----------- | ------------------- | ---------------------------------------------------------------------------------------------------------------------- |

11 precedence for that invocation. See [Config11| **General** | | |

12 basics](https://learn.chatgpt.com/docs/config-file/config-basic#configuration-precedence) for more12| | Command menu | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>P</kbd> or <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>K</kbd> |

13 information.13| | Settings | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>,</kbd> |

14 14| | Keyboard shortcuts | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>/</kbd> |

15## Global flags15| | Open folder | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>O</kbd> |

16 16| | Navigate back | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>[</kbd> |

17<ConfigTable client:load options={globalFlagOptions} />17| | Navigate forward | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>]</kbd> |

18 18| | Increase font size | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>+</kbd> |

19These options apply to the base `codex` command. Most propagate to commands;19| | Decrease font size | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>-</kbd> |

20see the notes above or the relevant command help for exceptions. For propagated20| | Toggle sidebar | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>B</kbd> |

21flags, follow the relevant command help. For example, `codex exec --oss ...`21| | Open review tab | <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>G</kbd> |

22applies `--oss` to `exec`.22| | Toggle review panel | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>B</kbd> |

23 23| | Toggle bottom panel | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>J</kbd> |

24## Command overview24| | Toggle terminal | <kbd>Ctrl</kbd> + <kbd>`</kbd> |

25 25| | Clear the terminal | <kbd>Ctrl</kbd> + <kbd>L</kbd> |

26The Maturity column uses feature maturity labels such as Experimental, Beta,26| **Chat** | Quick chat | <kbd>Cmd</kbd> + <kbd>Option</kbd> + <kbd>N</kbd> (macOS) or <kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>N</kbd> (Windows) |

27 and Stable. See [Feature Maturity](https://learn.chatgpt.com/docs/feature-maturity) for how to27| | New chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>N</kbd> or <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>O</kbd> |

28 interpret these labels.28| | Search chats | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>G</kbd> |

29 29| | Find in chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>F</kbd> |

30<ConfigTable30| | Previous chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>[</kbd> |

31 client:load31| | Next chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>]</kbd> |

32 options={commandOverview}32| **Input** | Dictation | <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>D</kbd> |

33 secondColumnTitle="Maturity"33 

34 secondColumnVariant="maturity"34To find, customize, or reset shortcuts, open **Settings > Keyboard Shortcuts**.

35/>35You can search by command name or switch the search field into keystroke mode

36 36and press the shortcut you want to find.

37## Command details37 

38 38<a id="search-past-tasks-and-find-in-a-task"></a>

39### `codex` (interactive)39 

40 40## Search past chats and find in a chat

41Running `codex` with no subcommand launches the interactive terminal UI (TUI). The agent accepts the global flags above plus image attachments. Web search defaults to cached mode; use `--search` to switch to live browsing. For low-friction local work, use `--sandbox workspace-write --ask-for-approval on-request`.41 

42 42Use chat search (<kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>G</kbd>) to reopen a past

43Use `--remote ws://host:port` or `--remote wss://host:port` to connect the TUI to an app server started with `codex app-server --listen ws://IP:PORT`. For a local Unix socket, use `--remote unix://` for the default socket or `--remote unix://PATH` for an explicit path. Add `--remote-auth-token-env <ENV_VAR>` when the server requires a bearer token for WebSocket authentication.43chat. When expanded matching is available, it can also match chat content and

44 44Git branch names, so you can search for a phrase from the chat or a

45### `codex app-server`45branch such as `fix/login-redirect`.

46 46 

47Launch the Codex app server locally. This is primarily for development and debugging and may change without notice.47Use **Find in chat** (<kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>F</kbd>) after opening

48 48a chat to find text within it. It doesn't search across other chats.

49<ConfigTable client:load options={appServerOptions} />49 

50 50For actions that start with `/`, see [Slash commands](https://learn.chatgpt.com/docs/reference/slash-commands).

51`codex app-server --listen stdio://` keeps the default JSONL-over-stdio behavior, and `codex app-server --stdio` is an alias for that transport. `--listen ws://IP:PORT` enables WebSocket transport for app-server clients. The server accepts `ws://` listen URLs; use TLS termination or a secure proxy when clients connect with `wss://`. Use `--listen unix://` to accept WebSocket handshakes on Codex's default Unix socket, or `--listen unix:///absolute/path.sock` to choose a socket path. If you generate schemas for client bindings, add `--experimental` to include gated fields and methods.51 

52 52## Deep links

53Add `--code-mode-host wss://code-mode.example.com/host` to connect app-server to53 

54a remote Code Mode host instead of starting a local host. This outbound54The ChatGPT desktop app keeps the `codex://` URL scheme for compatibility, so

55connection is separate from `--listen` and shared by every thread in the55links can open specific parts of the app directly. Encode query string values

56app-server process. Use `ws://` only for a localhost or SSH-forwarded host.56before adding them to a URL.

57 57 

58### `codex remote-control`58### Supported links

59 59 

60Run `codex remote-control` to start remote control in the foreground. Use60Use these canonical forms when you create links. The sections below list the full reference by link type.

61`codex remote-control start` to start the local app-server daemon with remote61 

62control enabled, and `codex remote-control stop` to stop it. Managed62| Deep link | Opens |

63remote-control clients and SSH remote workflows use these commands; they aren't63| --------------------------------------------------------------------------- | ------------------------------------------------------- |

64a replacement for `codex app-server --listen` when you're building a local64| `codex://threads/new` | A new local chat. |

65protocol client.65| `codex://new?<query>` | A new local chat with at least one query parameter. |

66 66| `codex://threads/<thread-id>` | A local chat. `<thread-id>` is its technical thread ID. |

67After the daemon is running, use `codex remote-control pair` to create and67| `codex://settings` | Settings. |

68print a short-lived manual pairing code. Add `--json` to any remote-control68| `codex://settings/connections/<connection-type>` | Computer, device, or SSH connection settings. |

69command for machine-readable output. For `pair`, the JSON response includes69| `codex://settings/connections/ssh/add?name=<ssh-config-host>` | Adds a host from your SSH config to Codex. |

70`pairingCode`, `manualPairingCode`, `environmentId`, and `expiresAt`.70| `codex://skills` | Skills. |

71 71| `codex://automations` | Scheduled with the create flow open. |

72### `codex app`72| `codex://plugins/install/<plugin-name>?marketplace=<marketplace-name>` | The install flow for a plugin from a known marketplace. |

73 73| `codex://plugins/<plugin-id>` | A plugin detail page. |

74Launch the ChatGPT desktop app from the terminal on macOS or Windows. On macOS,74| `codex://plugins/<plugin-name>?marketplacePath=<absolute-marketplace-path>` | A local plugin detail page from a local marketplace. |

75Codex can open a specific workspace path; on Windows, Codex prints the path to75| `codex://pets/install?name=<pet-name>&imageUrl=<https-image-url>` | The pet install flow. |

76open.76 

77 77<a id="tasks"></a>

78<ConfigTable client:load options={appOptions} />78 

79 79### Chats

80`codex app` opens an installed ChatGPT desktop app, or starts the installer when80 

81the app is missing. On macOS, Codex opens the provided workspace path; on81Use these links when you need to open an existing local chat or start a new one.

82Windows, it prints the path to open after installation.82 

83 83| Deep link | Opens |

84### `codex debug app-server send-message-v2`84| ----------------------------- | ------------------------------------------------------------------------------------------------------------ |

85 85| `codex://threads/<thread-id>` | A local chat. `<thread-id>` is its technical thread ID. |

86Send one message through app-server's V2 thread/turn flow using the built-in app-server test client.86| `codex://threads/new` | A new local chat. |

87 87| `codex://threads/new?<query>` | A new local chat with optional query parameters. |

88<ConfigTable client:load options={debugAppServerSendMessageV2Options} />88| `codex://new?<query>` | A new local chat. Include at least one of `prompt`, `path`, or `originUrl`; otherwise the link does nothing. |

89 89 

90This debug flow initializes with `experimentalApi: true`, starts a thread, sends a turn, and streams server notifications. Use it to reproduce and inspect app-server protocol behavior locally.90For `codex://threads/new` or `codex://new`, add any of these query parameters as needed; you can combine them in the same URL.

91 91 

92### `codex debug models`92| Query parameter | Required | What it does |

93 93| ---------------------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------- |

94Print the raw model catalog Codex sees as JSON.94| `prompt=<text>` | No | Sets the initial composer text. |

95 95| `path=<absolute-path>` | No | Opens the new chat in a local workspace. `path` must be an absolute path to a local directory. When valid, Codex uses that directory as the active workspace. |

96<ConfigTable client:load options={debugModelsOptions} />96| `originUrl=<git-remote-url>` | No | Matches one of your current workspace roots by Git remote URL. If `path` is also present, Codex resolves `path` first. |

97 97 

98Use `--bundled` when you want to inspect only the catalog bundled with the current binary, without refreshing from the remote models endpoint.98Example: [Show me some fun stats about how I've been using Codex](codex://threads/new?prompt=Show%20me%20some%20fun%20stats%20about%20how%20I%27ve%20been%20using%20Codex)

99 99 

100### `codex debug prompt-input`100<a id="start-a-task-with-a-plugin"></a>

101 101 

102Render the exact model-visible prompt input list as JSON. Use this when102#### Start a chat with a plugin

103debugging instruction discovery, session context, or prompt construction.103 

104 104To help users start a plugin-backed chat, include a plugin mention in the

105<ConfigTable client:load options={debugPromptInputOptions} />105prompt before you encode it:

106 106 

107### `codex apply`107```text

108 108[@Example](plugin://example@openai-curated) Summarize this document: https://example.com/document/123

109Apply the most recent diff from a Codex cloud chat to your local repository. You must authenticate and have access to the chat.

110 

111<ConfigTable client:load options={applyOptions} />

112 

113Codex prints the patched files and exits non-zero if `git apply` fails (for example, due to conflicts).

114 

115### `codex review`

116 

117Run a code review non-interactively. Choose exactly one review target, or pass

118custom review instructions as a prompt.

119 

120<ConfigTable client:load options={reviewOptions} />

121 

122`--uncommitted`, `--base`, `--commit`, and a custom `PROMPT` conflict with one

123another. Use `--title` only with `--commit`.

124 

125### `codex archive` and `codex unarchive`

126 

127Archive or restore a saved interactive session by session ID or session name.

128Use these commands when you want to clean up the session picker without deleting

129the transcript. Session IDs take precedence over session names.

130 

131```bash

132codex archive <SESSION>

133codex unarchive <SESSION>

134```109```

135 110 

136<ConfigTable client:load options={archiveOptions} />111Encode the complete prompt as a URI component—for example, with

112`encodeURIComponent` in JavaScript—and pass it to the `prompt` parameter:

137 113 

138### `codex delete`114```text

139 115codex://new?prompt=%5B%40Example%5D(plugin%3A%2F%2Fexample%40openai-curated)%20Summarize%20this%20document%3A%20https%3A%2F%2Fexample.com%2Fdocument%2F123

140Permanently delete a saved interactive session by session ID or session name.

141Use this only when you want to remove the transcript instead of hiding it from

142active session lists.

143 

144```bash

145codex delete <SESSION>

146codex delete <SESSION_UUID> --force

147```116```

148 117 

149<ConfigTable client:load options={deleteOptions} />118The link opens a new chat with the decoded prompt in the composer. It doesn't

150 119send the prompt automatically. After the user sends it, Codex can use an

151Use `--force` only with a session UUID. Named sessions still require120installed plugin in that chat. If the plugin isn't installed but is available

152confirmation so Codex doesn't delete a repeated or ambiguous name without a prompt.121to the user, Codex asks the user to install it and connect any required connectors.

153 122After setup, the user can select **Continue** to resume the same chat. Workspace

154### `codex cloud`123settings can limit which plugins a user can install. For plugin installation

155 124and permission details, see [Plugins](https://learn.chatgpt.com/docs/plugins).

156Interact with Codex cloud chats from the terminal. The default command opens an interactive picker; `codex cloud exec` submits a task directly, and `codex cloud list` returns recent chats for scripting or quick inspection.

157 

158<ConfigTable client:load options={cloudExecOptions} />

159 

160Authentication follows the same credentials as the main CLI. Codex exits non-zero if the task submission fails.

161 

162#### `codex cloud list`

163 

164List recent cloud chats with optional filtering and pagination.

165 

166<ConfigTable client:load options={cloudListOptions} />

167 

168Plain-text output prints a task URL followed by status details. Use `--json` for automation. The JSON payload contains a `tasks` array plus an optional `cursor` value. Each task includes `id`, `url`, `title`, `status`, `updated_at`, `environment_id`, `environment_label`, `summary`, `is_review`, and `attempt_total`.

169 

170### `codex completion`

171 

172Generate shell completion scripts and redirect the output to the appropriate location, for example `codex completion zsh > "${fpath[1]}/_codex"`.

173 

174<ConfigTable client:load options={completionOptions} />

175 

176### `codex doctor`

177 

178Generate a local diagnostic report before filing a support issue or

179while investigating a broken Codex installation. The report checks installation,

180configuration, authentication, runtime, Git, terminal, app-server, and thread

181inventory health.

182 

183<ConfigTable client:load options={doctorOptions} />

184 

185### `codex features`

186 

187Manage feature flags stored in `$CODEX_HOME/config.toml`. The `enable` and

188`disable` commands persist changes so they apply to future sessions. The

189`features` subcommand doesn't accept `--profile`.

190 

191<ConfigTable client:load options={featuresOptions} />

192 

193### `codex exec`

194 

195Use `codex exec` (or the short form `codex e`) for scripted or CI-style runs that should finish without human interaction.

196 

197<ConfigTable client:load options={execOptions} />

198 

199Codex writes formatted output by default. Add `--json` to receive newline-delimited JSON events (one per state change). The optional `resume` subcommand lets you continue non-interactive tasks. Use `--last` to pick the most recent session from the current working directory, or add `--all` to search across all sessions:

200 

201<ConfigTable client:load options={execResumeOptions} />

202 

203### `codex execpolicy`

204 

205Check `execpolicy` rule files before you save them. `codex execpolicy check` accepts one or more `--rules` flags (for example, files under `~/.codex/rules`) and emits JSON showing the strictest decision and any matching rules. Add `--pretty` to format the output. The `execpolicy` command is currently in preview.

206 

207<ConfigTable client:load options={execpolicyOptions} />

208 

209### `codex login`

210 

211Authenticate the CLI with a ChatGPT account, API key, or access token. With no flags, Codex opens a browser for the ChatGPT OAuth flow.

212 

213<ConfigTable client:load options={loginOptions} />

214 

215`codex login status` exits with `0` when credentials are present, which is helpful in automation scripts.

216 

217### `codex logout`

218 

219Remove saved credentials for both API key and ChatGPT authentication. This command has no flags.

220 

221### `codex mcp`

222 

223Manage Model Context Protocol server entries stored in `~/.codex/config.toml`.

224 

225<ConfigTable client:load options={mcpCommands} />

226 

227The `add` subcommand supports both stdio and streamable HTTP transports:

228 

229<ConfigTable client:load options={mcpAddOptions} />

230 

231OAuth actions (`login`, `logout`) only work with streamable HTTP servers (and only when the server supports OAuth).

232 

233### `codex plugin`

234 

235Install, list, and remove plugins from configured marketplaces.

236 

237<ConfigTable client:load options={pluginCommands} />

238 

239`codex plugin add --json` prints `pluginId`, `name`, `marketplaceName`,

240`version`, `installedPath`, and `authPolicy`. `codex plugin list --json` prints

241`installed` and `available` arrays. Entries include `pluginId`, `name`,

242`marketplaceName`, `version`, `installed`, `enabled`, `source`, `installPolicy`,

243`authPolicy`, and, when available, `marketplaceSource` with the configured

244marketplace source type and value. `codex plugin remove --json` prints

245`pluginId`, `name`, and `marketplaceName`.

246 

247### `codex plugin marketplace`

248 

249Manage plugin marketplace sources that Codex can browse and install from.

250 

251<ConfigTable client:load options={marketplaceCommands} />

252 

253`codex plugin marketplace add` accepts GitHub shorthand such as `owner/repo` or

254`owner/repo@ref`, HTTP or HTTPS Git URLs, SSH Git URLs, and local marketplace

255root directories. Use `--ref` to pin a Git ref, and repeat `--sparse PATH` to

256use a sparse checkout for Git-backed marketplace repositories.

257 

258`codex plugin marketplace list` prints in-scope marketplace names and roots,

259including implicitly discovered default marketplaces and configured marketplace

260snapshots.

261 

262Add `--json` to marketplace add, list, upgrade, or remove commands for

263automation-friendly output. Marketplace add JSON includes `marketplaceName`,

264`installedRoot`, and `alreadyAdded`; list JSON includes a `marketplaces` array

265with `name`, `root`, and optional `marketplaceSource`; upgrade JSON includes

266`selectedMarketplaces`, `upgradedRoots`, and `errors`; remove JSON includes

267`marketplaceName` and `installedRoot`.

268 

269### `codex mcp-server`

270 

271Run Codex as an MCP server over stdio so that other tools can connect. This command inherits global configuration overrides and exits when the downstream client closes the connection.

272 

273### `codex resume`

274 

275Continue an interactive session by ID or resume the most recent chat. `codex resume` scopes `--last` to the current working directory unless you pass `--all`. It accepts the same global flags as `codex`, including model and sandbox overrides.

276 

277If the current working directory differs from the session's saved directory,

278Codex asks which directory to use. Set

279[`tui.resume_cwd`](https://learn.chatgpt.com/docs/config-file/config-reference) to `"current"` or

280`"session"` to reuse that choice without a prompt. An explicit `--cd` (`-C`)

281override takes precedence over `tui.resume_cwd`.

282 

283<ConfigTable client:load options={resumeOptions} />

284 

285### `codex fork`

286 

287Fork a previous interactive session into a new chat. By default, `codex fork` opens the session picker; add `--last` to fork your most recent session instead.

288 

289When the current and saved session directories differ, `codex fork` uses the

290same working-directory prompt and `tui.resume_cwd` setting as `codex resume`.

291 

292<ConfigTable client:load options={forkOptions} />

293 

294### `codex sandbox`

295 

296Use the sandbox helper to run a command under the same policies Codex uses internally.

297 

298#### macOS seatbelt

299 

300<ConfigTable client:load options={sandboxMacOptions} />

301 

302#### Linux Landlock

303 

304<ConfigTable client:load options={sandboxLinuxOptions} />

305 

306#### Windows

307 

308<ConfigTable client:load options={sandboxWindowsOptions} />

309 

310### `codex update`

311 

312Check for and apply a Codex CLI update when the installed release supports self-update. Debug builds print a message telling you to install a release build instead.

313 

314## Flag combinations and safety tips

315 

316- Use `--sandbox workspace-write` for unattended local work that can stay inside the workspace, and avoid `--dangerously-bypass-approvals-and-sandbox` unless you are inside a dedicated sandbox VM.

317- When you need to grant Codex write access to more directories, prefer `--add-dir` rather than forcing `--sandbox danger-full-access`.

318- Pair `--json` with `--output-last-message` in CI to capture machine-readable progress and a final natural-language summary.

319 

320## Interactive shortcuts

321 

322- Type `@` to search for a file in the workspace and add its path to the prompt.

323- Press <kbd>Up</kbd> or <kbd>Down</kbd> to restore draft history.

324- Press <kbd>Ctrl</kbd>+<kbd>R</kbd> to search prompt history, then press <kbd>Enter</kbd> to use a match or <kbd>Esc</kbd> to cancel.

325- Press <kbd>Ctrl</kbd>+<kbd>O</kbd> or run `/copy` to copy the latest completed Codex output.

326- Prefix a line with `!` to run a local shell command under the current approval and sandbox settings.

327- Press <kbd>Tab</kbd> while Codex is working to queue a follow-up prompt, slash command, or shell command for the next turn.

328- Press <kbd>Enter</kbd> while Codex is working to inject new instructions into the current turn.

329- Press <kbd>Esc</kbd> twice with an empty composer to edit the previous user message and fork the chat from that point.

330- Press <kbd>Ctrl</kbd>+<kbd>C</kbd> or run `/exit` to close the session.

331 

332## Related resources

333 

334- [Codex CLI overview](https://learn.chatgpt.com/docs/codex/cli): installation, upgrades, and quick tips.

335- [Config basics](https://learn.chatgpt.com/docs/config-file/config-basic): persist defaults like the model and provider.

336- [Advanced Config](https://learn.chatgpt.com/docs/config-file/config-advanced): profiles, providers, sandbox tuning, and integrations.

337- [AGENTS.md](https://learn.chatgpt.com/docs/agent-configuration/agents-md): conceptual overview of Codex agent capabilities and best practices.

338 

339Slash commands give you fast, keyboard-first control over Codex. Type `/` in

340the composer to open the slash popup, choose a command, and Codex will perform

341actions such as switching models, adjusting permissions, or summarizing long

342chats without leaving the terminal.

343 

344This guide shows you how to:

345 

346- Find the right built-in slash command for a task

347- Steer an active session with commands like `/model`, `/fast`,

348 `/personality`, `/permissions`, `/approve`, `/raw`, `/agent`, and `/status`

349 

350## Built-in slash commands

351 

352Codex ships with the following commands. Open the slash popup and start typing

353the command name to filter the list.

354 

355When a chat is already running, you can type a slash command and press `Tab` to

356queue it for the next turn. Codex parses queued slash commands when they run, so

357command menus and errors appear after the current turn finishes. Slash

358completion still works before you queue the command.

359 

360| Command | Purpose | When to use it |

361| ------------------------------------------------------------------------------------------- | --------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- |

362| [`/permissions`](#update-permissions-with-permissions) | Set what Codex can do without asking first. | Relax or tighten approval requirements mid-session, such as switching between Auto and Read Only. |

363| [`/ide`](#include-ide-context-with-ide) | Include open files, current selection, and other IDE context. | Pull editor context into the next prompt without re-explaining what's open in your IDE. |

364| [`/keymap`](#remap-tui-shortcuts-with-keymap) | Remap TUI keyboard shortcuts. | Inspect and persist custom shortcut bindings in `config.toml`. |

365| [`/vim`](#toggle-vim-mode-with-vim) | Toggle Vim mode for the composer. | Switch between Vim normal/insert behavior and the default composer editing mode. |

366| [`/setup-default-sandbox`](#set-up-the-elevated-windows-sandbox-with-setup-default-sandbox) | Set up the elevated agent sandbox (Windows only). | Replace the degraded Windows sandbox after Codex offers the elevated setup. |

367| [`/sandbox-add-read-dir`](#grant-sandbox-read-access-with-sandbox-add-read-dir) | Grant sandbox read access to an extra directory (Windows only). | Unblock commands that need to read an absolute directory path outside the current readable roots. |

368| [`/agent`, `/subagents`](#switch-agent-threads-with-agent) | Switch the active agent thread. | Inspect or continue work in a spawned subagent thread. |

369| [`/apps`](#browse-apps-with-apps) | Browse apps (connectors) and insert them into your prompt. | Attach an app as `$app-slug` before asking Codex to use it. |

370| [`/plugins`](#browse-plugins-with-plugins) | Browse installed and discoverable plugins. | Inspect plugin tools, install suggested plugins, or manage plugin availability. |

371| [`/hooks`](#view-and-manage-lifecycle-hooks-with-hooks) | View and manage lifecycle hooks. | Inspect configured hooks, trust new or changed hooks, or disable non-managed hooks before they run. |

372| [`/clear`](#clear-the-terminal-and-start-a-new-chat-with-clear) | Clear the terminal and start a fresh chat. | Reset the visible UI and chat context together when you want a fresh start. |

373| [`/rename`](#rename-the-current-chat-with-rename) | Rename the current chat. | Give a saved session a recognizable name without leaving the TUI. |

374| [`/archive`](#archive-the-current-session-with-archive) | Archive the current session and exit Codex. | Remove the current session from active session lists without deleting its transcript. |

375| [`/delete`](#delete-the-current-session-with-delete) | Permanently delete the current session and exit Codex. | Remove the transcript and descendant sessions when archiving isn't enough. |

376| [`/compact`](#keep-transcripts-lean-with-compact) | Summarize the visible chat to free tokens. | Use after long runs so Codex retains key points without blowing the context window. |

377| [`/copy`](#copy-the-latest-response-with-copy) | Copy the latest completed Codex output. | Grab the latest finished response or plan text without manually selecting it. You can also press `Ctrl+O`. |

378| [`/diff`](#review-changes-with-diff) | Show the Git diff, including files Git isn't tracking yet. | Review Codex's edits before you commit or run tests. |

379| [`/exit`](#exit-the-cli-with-quit-or-exit) | Exit the CLI (same as `/quit`). | Alternative spelling; both commands exit the session. |

380| [`/experimental`](#toggle-experimental-features-with-experimental) | Toggle experimental features. | Enable options such as Network proxy or Prevent sleep while running. |

381| [`/approve`](#approve-an-auto-review-denial-with-approve) | Approve one retry of a recent auto review denial. | Retry a command or action that the auto reviewer denied. |

382| [`/memories`](#configure-memories-with-memories) | Configure memory use and generation. | Turn memory injection or memory generation on or off without leaving the TUI. |

383| [`/skills`](#use-skills-with-skills) | Browse and use skills. | Improve task-specific behavior by selecting a relevant local skill. |

384| [`/import`](#import-claude-code-or-cursor-configuration-with-import) | Import Claude Code or Cursor setup, projects, and recent chats. | Migrate supported external-agent artifacts into Codex configuration and local files. |

385| [`/feedback`](#send-feedback-with-feedback) | Send logs to the Codex maintainers. | Report issues or share diagnostics with support. |

386| [`/init`](#generate-agentsmd-with-init) | Generate an `AGENTS.md` scaffold in the current directory. | Capture persistent instructions for the repository or subdirectory you're working in. |

387| [`/logout`](#sign-out-with-logout) | Sign out of Codex. | Clear local credentials when using a shared machine. |

388| [`/mcp`](#list-mcp-tools-with-mcp) | List configured Model Context Protocol (MCP) tools. | Check which external tools Codex can call during the session; add `verbose` for server details. |

389| [`/mention`](#highlight-files-with-mention) | Attach a file to the chat. | Point Codex at specific files or folders you want it to inspect next. |

390| [`/model`](#set-the-active-model-with-model) | Choose the active model (and reasoning effort, when available). | Switch between models such as `gpt-5.6-luna` and `gpt-5.6-terra` before running a task. |

391| [`/fast`](#toggle-fast-mode-with-fast) | Toggle a Fast service tier when the model catalog exposes one. | Turn the current model's Fast tier on or off and persist the selection. |

392| [`/plan`](#switch-to-plan-mode-with-plan) | Switch to plan mode and optionally send a prompt. | Ask Codex to propose an execution plan before implementation work starts. |

393| [`/goal`](#set-or-view-a-task-goal-with-goal) | Set, edit, pause, resume, view, or clear a task goal. | Give Codex a persistent target to track while a larger task runs. |

394| [`/personality`](#set-a-communication-style-with-personality) | Choose a communication style for responses. | Make Codex more concise, more explanatory, or more collaborative without changing your instructions. |

395| [`/ps`](#check-background-terminals-with-ps) | Show background terminals and their recent output. | Check long-running commands without leaving the main transcript. |

396| [`/stop`](#stop-background-terminals-with-stop) | Stop all background terminals. | Cancel background terminal work started by the current session. |

397| [`/fork`](#fork-the-current-chat-with-fork) | Fork the current chat into a new chat. | Branch the active session to explore a new approach without losing the current transcript. |

398| [`/app`](#continue-in-the-desktop-app-with-app) | Continue the current session in the ChatGPT desktop app. | Move from the TUI to the desktop app on macOS or Windows. |

399| [`/side`, `/btw`](#start-a-side-chat-with-side) | Start an ephemeral side chat. | Ask a focused follow-up without disrupting the main chat's transcript. |

400| [`/raw`](#toggle-raw-scrollback-with-raw) | Toggle raw scrollback mode. | Make terminal selection and copying less formatted while reviewing long output. |

401| [`/resume`](#resume-a-saved-chat-with-resume) | Resume a saved chat from your session list. | Continue work from a previous CLI session without starting over. |

402| [`/new`](#start-a-new-chat-with-new) | Start a new chat inside the same CLI session. | Reset the chat context without leaving the CLI when you want a fresh prompt in the same repo. |

403| [`/quit`](#exit-the-cli-with-quit-or-exit) | Exit the CLI. | Leave the session immediately. |

404| [`/review`](#ask-for-a-working-tree-review-with-review) | Ask Codex to review your working tree. | Run after Codex completes work or when you want a second set of eyes on local changes. |

405| [`/status`](#inspect-the-session-with-status) | Display session configuration and token usage. | Confirm the active model, approval policy, writable roots, and remaining context capacity. |

406| [`/usage`](#view-account-usage-with-usage) | View account token usage or use a rate-limit reset. | Inspect daily, weekly, or cumulative ChatGPT token activity from inside the TUI. |

407| [`/debug-config`](#inspect-config-layers-with-debug-config) | Print config layer and requirements diagnostics. | Debug precedence and policy requirements, including experimental network constraints. |

408| [`/statusline`](#configure-footer-items-with-statusline) | Configure TUI status-line fields interactively. | Pick and reorder footer items (model/context/limits/git/tokens/session) and persist in config.toml. |

409| [`/title`](#configure-terminal-title-items-with-title) | Configure terminal window or tab title fields interactively. | Pick and reorder title items such as project, status, thread, branch, model, and task progress. |

410| [`/theme`](#choose-a-syntax-theme-with-theme) | Choose a syntax-highlighting theme. | Preview and persist a terminal syntax-highlighting theme. |

411| [`/pets`, `/pet`](#choose-a-terminal-pet-with-pets) | Choose or hide a terminal pet. | Personalize the TUI with a built-in or custom ambient pet. |

412 

413`/quit` and `/exit` both exit the CLI. Use them only after you have saved or

414committed any important work.

415 

416Use `/permissions` to adjust what Codex can do without asking first. Use

417`/approve` only when you need to retry a recent action that automatic review

418denied.

419 

420## Control your session with slash commands

421 

422The following workflows keep your session on track without restarting Codex.

423 

424### Set the active model with `/model`

425 

4261. Start Codex and open the composer.

4272. Type `/model` and press Enter.

4283. Choose a model such as `gpt-5.6-luna` or `gpt-5.6-terra` from the popup.

429 

430Expected: Codex confirms the new model in the transcript. Run `/status` to verify the change.

431 

432### Toggle Fast mode with `/fast`

433 

4341. Type `/fast` to turn the current model's Fast service tier on.

4352. Type `/fast` again to turn it off.

436 

437Expected: Codex toggles the tier and saves the selection. In the TUI footer,

438you can also show a Fast mode status-line item with `/statusline`.

439 

440Fast tier commands are catalog-driven. If the current model doesn't advertise a

441Fast tier, Codex won't show `/fast`.

442 

443### Set a communication style with `/personality`

444 

445Use `/personality` to change how Codex communicates without rewriting your prompt.

446 

4471. In an active chat, type `/personality` and press Enter.

4482. Choose a style from the popup.

449 

450Expected: Codex confirms the new style in the transcript and uses it for later

451responses in the chat.

452 

453Codex supports `friendly`, `pragmatic`, and `none` personalities. Use `none`

454to disable personality instructions.

455 

456If the active model doesn't support personality-specific instructions, Codex hides this command.

457 

458### Switch to plan mode with `/plan`

459 

4601. Type `/plan` and press Enter to switch the active chat into plan

461 mode.

4622. Optional: provide inline prompt text (for example, `/plan Propose a

463migration plan for this service`).

4643. You can paste content or attach images while using inline `/plan` arguments.

465 

466Expected: Codex enters plan mode and uses your optional inline prompt as the first planning request.

467 

468While Codex is already working, `/plan` is temporarily unavailable.

469 

470### Set or view a task goal with `/goal`

471 

4721. Type `/goal <objective>` to set the goal, for example `/goal Finish the migration and keep tests green`.

4732. Type `/goal` to view the current goal.

4743. Use `/goal edit` to revise the objective. Use `/goal pause`, `/goal resume`, or `/goal clear` to pause, resume, or remove it.

475 

476Expected: Codex keeps the goal attached to the active chat while work continues.

477 

478Goal objectives must be non-empty and at most 4,000 characters. For longer

479instructions, put the details in a file and point the goal at that file.

480 

481### Toggle experimental features with `/experimental`

482 

4831. Type `/experimental` and press Enter.

4842. Toggle the features you want (for example, Network proxy or Prevent sleep while running), then restart Codex if the prompt asks you to.

485 

486Expected: Codex saves your feature choices to config and applies them on restart.

487 

488### Approve an auto review denial with `/approve`

489 

490Use `/approve` when the automatic reviewer denied a recent action and you want

491Codex to retry it once.

492 

4931. Type `/approve`.

4942. Confirm the retry when Codex shows the relevant denied action.

495 

496Expected: Codex retries that denied action once under the current session

497policy.

498 

499### Configure memories with `/memories`

500 

5011. Type `/memories`.

5022. Choose whether Codex should use existing memories, generate new memories, or

503 keep memory behavior disabled.

504 

505Expected: Codex updates the relevant memory settings for future sessions.

506 

507### Use skills with `/skills`

508 

5091. Type `/skills`.

5102. Pick the skill you want Codex to apply.

511 

512Expected: Codex inserts the selected skill context so the next request follows

513that skill's instructions.

514 

515<a id="import-claude-code-configuration-with-import"></a>

516 

517### Import Claude Code or Cursor configuration with `/import`

518 

5191. Type `/import`.

5202. Choose **Claude Code** or **Cursor**.

5213. Select the setup, project files, or recent chats you want to migrate.

522 

523Expected: Codex opens the external-agent import picker and imports the selected

524supported artifacts into Codex configuration and local files. Session discovery

525includes up to 50 chats from the last 30 days.

526 

527Run `/import` from a local TUI session. It's unavailable while a task is running,

528in remote sessions, and while connected to the local app-server daemon.

529 

530For the desktop app workflow and supported artifact types, see [Import from

531another agent](https://learn.chatgpt.com/docs/import).

532 

533<a id="clear-the-terminal-and-start-a-new-chat-with-clear"></a>

534<a id="clear-the-terminal-and-start-a-new-task-with-clear"></a>

535 

536### Clear the terminal and start a new chat with `/clear`

537 

5381. Type `/clear` and press Enter.

539 

540Expected: Codex clears the terminal, resets the visible transcript, and starts

541a fresh chat in the same CLI session.

542 

543To name the new chat as you create it, run `/clear release prep`.

544 

545Unlike <kbd>Ctrl</kbd>+<kbd>L</kbd>, `/clear` starts a new chat.

546 

547<kbd>Ctrl</kbd>+<kbd>L</kbd> only clears the terminal view and keeps the current

548chat. Codex disables both actions while a task is in progress.

549 

550### Archive the current session with `/archive`

551 

5521. Type `/archive` and press Enter.

5532. Confirm that you want to archive the current session and exit Codex.

554 

555Expected: Codex archives the current session and closes the interactive TUI.

556Codex keeps the session transcript stored locally; restore it later with

557`codex unarchive <SESSION>`.

558 

559`/archive` is unavailable while a task is running.

560 

561### Delete the current session with `/delete`

562 

5631. Type `/delete` and press Enter.

5642. Confirm that you want to delete the current session and exit Codex.

565 

566Expected: Codex deletes the current session transcript and closes the

567interactive TUI. Deletion is permanent and also removes spawned descendant

568sessions.

569 

570`/delete` is unavailable while a chat is running or in a side chat.

571 

572### Update permissions with `/permissions`

573 

5741. Type `/permissions` and press Enter.

5752. Select the approval preset that matches your comfort level, for example

576 `Auto` for hands-off runs or `Read Only` to review edits. When named

577 permission profiles are active, the picker also shows configured custom

578 profiles and their descriptions.

579 

580Expected: Codex announces the updated policy. Future actions respect the

581updated approval mode until you change it again.

582 

583### Include IDE context with `/ide`

584 

5851. Type `/ide`.

5862. Add optional inline text if you want to explain what Codex should do with the

587 current IDE selection or open files.

588 

589Expected: Codex includes available IDE context in the next prompt.

590 

591### Toggle Vim mode with `/vim`

592 

5931. Type `/vim`.

5942. Continue editing in the composer.

595 

596Expected: Codex toggles composer Vim mode for the current session. To make Vim

597mode the default for new sessions, set `tui.vim_mode_default = true` in

598`config.toml`.

599 

600### Set up the elevated Windows sandbox with `/setup-default-sandbox`

601 

602This command appears only on Windows when Codex is using the degraded

603restricted-token sandbox.

604 

6051. Type `/setup-default-sandbox`.

6062. Follow the administrator setup flow.

607 

608Expected: Codex configures the elevated Windows sandbox and selects the

609corresponding automatic approval preset.

610 

611### Copy the latest response with `/copy`

612 

6131. Type `/copy` and press Enter.

614 

615Expected: Codex copies the latest completed Codex output to your clipboard.

616 

617If a turn is still running, `/copy` uses the latest completed output instead of

618the in-progress response. The command is unavailable before the first completed

619Codex output and immediately after a rollback.

620 

621You can also press <kbd>Ctrl</kbd>+<kbd>O</kbd> from the main TUI to copy the

622latest completed response without opening the slash command menu.

623 

624### Toggle raw scrollback with `/raw`

625 

6261. Type `/raw`, `/raw on`, or `/raw off`.

627 

628Expected: Codex toggles raw scrollback mode, which makes terminal selection and

629copying more direct. You can also use the default <kbd>Alt</kbd>+<kbd>R</kbd>

630binding or persist the default with `tui.raw_output_mode = true`.

631 

632### Grant sandbox read access with `/sandbox-add-read-dir`

633 

634This command is available only when running the CLI natively on Windows.

635 

6361. Type `/sandbox-add-read-dir C:\absolute\directory\path` and press Enter.

6372. Confirm the path is an existing absolute directory.

638 

639Expected: Codex refreshes the Windows sandbox policy and grants read access to

640that directory for later commands that run in the sandbox.

641 

642### Inspect the session with `/status`

643 

6441. In any chat, type `/status`.

6452. Review the output for the active model, approval policy, writable roots, and

646 current token usage. When the TUI connects remotely, the output also

647 shows the remote address and the server version.

648 

649Expected: Codex prints a summary confirming that it's operating where you

650expect.

651 

652### View account usage with `/usage`

653 

6541. Type `/usage` to open the usage menu.

6552. Choose whether to show token activity or redeem an available earned reset.

6563. To open token activity directly, type `/usage daily`, `/usage weekly`, or `/usage cumulative`.

657 

658Expected: Codex opens usage actions or shows account token activity for the

659selected view. If the session doesn't have Codex service account auth, Codex

660shows a sign-in requirement.

661 

662### Inspect config layers with `/debug-config`

663 

6641. Type `/debug-config`.

6652. Review the output for config layer order (lowest precedence first), on/off

666 state, and policy sources.

667 

668Expected: Codex prints layer diagnostics plus policy details such as

669`allowed_approval_policies`, `allowed_sandbox_modes`, `mcp_servers`, `rules`,

670`enforce_residency`, and `experimental_network` when configured.

671 

672Use this output to debug why an effective setting differs from `config.toml`.

673 

674### Configure footer items with `/statusline`

675 

6761. Type `/statusline`.

6772. Use the picker to toggle and reorder items, then confirm.

678 

679Expected: The footer status line updates immediately and persists to

680`tui.status_line` in `config.toml`.

681 

682Available status-line items include model, model+reasoning, context stats, rate

683limits, git branch, token counters, session id, current directory/project root,

684and Codex version.

685 

686### Configure terminal title items with `/title`

687 

6881. Type `/title`.

6892. Use the picker to toggle and reorder items, then confirm.

690 

691Expected: The terminal window or tab title updates immediately and persists to

692`tui.terminal_title` in `config.toml`.

693 

694Available title items include app name, project, spinner, status, thread, git

695branch, model, and task progress.

696 

697### Choose a syntax theme with `/theme`

698 

6991. Type `/theme`.

7002. Preview a theme from the picker, then confirm.

701 

702Expected: Codex updates syntax highlighting and persists the choice to

703`tui.theme` in `config.toml`.

704 

705### Choose a terminal pet with `/pets`

706 

7071. Type `/pets` (or `/pet`) to open the pet picker.

7082. Choose a built-in or custom pet, or turn pets off.

709 

710Expected: Codex displays the selected ambient pet in supported terminals and

711persists the selection. You can also type `/pets off` to hide it.

712 

713### Remap TUI shortcuts with `/keymap`

714 

715Use `/keymap` to inspect, update, and persist keyboard shortcut bindings for the TUI.

716 

7171. Type `/keymap`.

7182. Pick the shortcut context and action you want to change.

7193. Enter the new binding or remove the existing one.

720 

721Expected: Codex updates the active keymap and writes the custom binding to `tui.keymap` in `config.toml`.

722 

723Key bindings use names such as `ctrl-a`, `shift-enter`, and `page-down`. Context-specific bindings override `tui.keymap.global`; an empty binding list unbinds the action.

724 

725### Check background terminals with `/ps`

726 

7271. Type `/ps`.

7282. Review the list of background terminals and their status.

729 

730Expected: Codex shows each background terminal's command plus up to three

731recent, non-empty output lines so you can gauge progress at a glance.

732 

733Background terminals appear when `unified_exec` is in use; otherwise, the list may be empty.

734 

735### Stop background terminals with `/stop`

736 

7371. Type `/stop`.

7382. Confirm if Codex asks before stopping the listed terminals.

739 

740Expected: Codex stops all background terminals for the current session. `/clean`

741is still available as an alias for `/stop`.

742 

743### Keep transcripts lean with `/compact`

744 

7451. After a long exchange, type `/compact`.

7462. Confirm when Codex offers to summarize the chat so far.

747 

748Expected: Codex replaces earlier turns with a concise summary, freeing context

749while keeping critical details.

750 

751### Review changes with `/diff`

752 

7531. Type `/diff` to inspect the Git diff.

7542. Scroll through the output inside the CLI to review edits and added files.

755 

756Expected: Codex shows changes you've staged, changes you haven't staged yet,

757and files Git hasn't started tracking, so you can decide what to keep.

758 

759### Highlight files with `/mention`

760 

7611. Type `/mention` followed by a path, for example `/mention src/lib/api.ts`.

7622. Select the matching result from the popup.

763 

764Expected: Codex adds the file to the chat, ensuring follow-up turns reference it directly.

765 

766<a id="start-a-new-conversation-with-new"></a>

767 

768### Start a new chat with `/new`

769 

7701. Type `/new` and press Enter.

771 

772Expected: Codex starts a fresh chat in the same CLI session, so you

773can switch chats without leaving your terminal.

774 

775To name the new chat as you create it, run `/new bug bash`.

776 

777Unlike `/clear`, `/new` doesn't clear the current terminal view first.

778 

779<a id="rename-the-current-chat-with-rename"></a>

780<a id="rename-the-current-task-with-rename"></a>

781 

782### Rename the current chat with `/rename`

783 

7841. Type `/rename <name>`, or type `/rename` to open the naming prompt.

7852. Enter a short name that will help you find the chat later.

786 

787Expected: Codex updates the saved chat name without changing its transcript.

788 

789<a id="resume-a-saved-conversation-with-resume"></a>

790 

791### Resume a saved chat with `/resume`

792 

7931. Type `/resume` and press Enter.

7942. Choose the session you want from the saved-session picker.

795 

796Expected: Codex reloads the selected chat's transcript so you can pick

797up where you left off, keeping the original history intact.

798 

799<a id="fork-the-current-conversation-with-fork"></a>

800 

801### Fork the current chat with `/fork`

802 

8031. Type `/fork` and press Enter.

804 

805Expected: Codex clones the current chat into a new chat with a fresh

806ID, leaving the original transcript untouched so you can explore an alternative

807approach in parallel.

808 

809If you need to fork a saved session instead of the current one, run

810`codex fork` in your terminal to open the session picker.

811 

812### Continue in the desktop app with `/app`

813 

814On macOS and Windows, type `/app` to open the current session in the ChatGPT

815desktop app. If the app isn't installed or running, Codex shows an error asking

816you to install or launch it.

817 

818Expected: The desktop app opens the same saved chat so you can continue there.

819 

820<a id="start-a-side-conversation-with-side"></a>

821 

822### Start a side chat with `/side`

823 125 

824Use `/side` to start an ephemeral fork from the current chat without switching away from the main chat.126### Settings

825 127 

8261. Type `/side` to open a side chat.128Use these links when you need to open Settings or a specific settings page.

8272. Optionally add inline text, for example `/side Check whether this plan has an obvious risk`.

8283. Return to the parent chat after the focused detour finishes.

829 129 

830Expected: Codex opens a side chat whose transcript is separate from130| Deep link | Opens |

831the parent chat. While you are in side mode, the TUI continues to show the131| ------------------------------------------------------------- | -------------------------------------------------------------------------------------------- |

832parent chat's status so you can see whether the main chat is still running.132| `codex://settings` | Settings. |

133| `codex://settings/browser-use` | Browser settings. |

134| `codex://settings/computer-use/google-chrome` | Google Chrome settings for computer use. |

135| `codex://settings/connections` | Remote connections settings. |

136| `codex://settings/connections/computer` | Settings for controlling this Mac or PC from another device. |

137| `codex://settings/connections/devices` | Settings for controlling other devices. |

138| `codex://settings/connections/ssh` | SSH connection settings. |

139| `codex://settings/connections/ssh/add?name=<ssh-config-host>` | Adds the named host alias as a Codex-managed connection, then opens SSH connection settings. |

833 140 

834`/side` is unavailable inside another side chat and during review mode.141The `name` value must match a host alias in `~/.ssh/config`. The link disables

142automatic connection for the added host. If Codex can't find the named host, it

143opens SSH connection settings and shows an error.

835 144 

836### Generate `AGENTS.md` with `/init`145Unsupported `codex://settings/...` paths open the main Settings page.

837 146 

8381. Run `/init` in the directory where you want Codex to look for persistent instructions.147### Skills

8392. Review the generated `AGENTS.md`, then edit it to match your repository conventions.

840 148 

841Expected: Codex creates an `AGENTS.md` scaffold you can refine and commit for149Use these links when you need to open Skills.

842future sessions.

843 150 

844### Ask for a working tree review with `/review`151| Deep link | Opens |

152| ---------------- | ------- |

153| `codex://skills` | Skills. |

845 154 

8461. Type `/review`.155### Scheduled

8472. Follow up with `/diff` if you want to inspect the exact file changes.

848 156 

849Expected: Codex summarizes issues it finds in your working tree, focusing on157Use these links when you need to open **Scheduled**.

850behavior changes and missing tests. It uses the current session model unless

851you set `review_model` in `config.toml`.

852 158 

853### List MCP tools with `/mcp`159| Deep link | Opens |

160| --------------------- | ------------------------------------ |

161| `codex://automations` | Scheduled with the create flow open. |

854 162 

8551. Type `/mcp`.163### Plugins

8562. Review the list to confirm which MCP servers and tools are available.

857 164 

858Expected: You see the configured Model Context Protocol (MCP) tools Codex can call in this session.165Plugin links use different forms depending on whether you are installing from a marketplace, opening a plugin, or working from a local `marketplace.json`. For plugin basics, see [Plugins](https://learn.chatgpt.com/docs/plugins). For local or repo marketplace setup, see [Build plugins](https://developers.openai.com/plugins/build/plugins#build-your-own-curated-plugin-list).

859 166 

860Use `/mcp verbose` to include detailed server diagnostics. If you pass anything other than `verbose`, Codex shows the command usage.167#### Plugin install

861 168 

862### Browse apps with `/apps`169Use this form to open the install flow for a plugin from a marketplace that Codex already knows about.

863 170 

8641. Type `/apps`.171| Deep link | Opens |

8652. Pick an app from the list.172| ---------------------------------------------------------------------- | ----------------------------------------------- |

173| `codex://plugins/install/<plugin-name>?marketplace=<marketplace-name>` | The plugin detail or install flow for a plugin. |

866 174 

867Expected: Codex inserts the app mention into the composer as `$app-slug`, so175| Query parameter | Required | What it does |

868you can immediately ask Codex to use it.176| -------------------------------- | -------- | ------------------------------------------------------------------------------- |

177| `marketplace=<marketplace-name>` | Yes | Identifies the marketplace. For an OpenAI-curated plugin, use `openai-curated`. |

869 178 

870### Browse plugins with `/plugins`179The install link accepts only the `marketplace` query parameter. If Codex can't find the requested marketplace or plugin, it opens the Plugins page instead.

871 180 

8721. Type `/plugins`.181#### Plugin detail

8732. Choose a marketplace tab, then pick a plugin to inspect its capabilities or available actions.

874 182 

875Expected: Codex opens the plugin browser so you can review installed plugins,183| Deep link | Opens |

876discoverable plugins that your configuration allows, and installed plugin state.184| ----------------------------- | --------------------- |

877Press <kbd>Space</kbd> on an installed plugin to toggle its enabled state.185| `codex://plugins/<plugin-id>` | A plugin detail page. |

878 186 

879### View and manage lifecycle hooks with `/hooks`187`<plugin-id>` must identify the plugin. For an OpenAI-curated plugin, use the form `<plugin-name>@openai-curated`.

880 188 

8811. Type `/hooks`.189Codex-generated plugin links can also include these query parameters. Omit both when you write a link manually.

8822. Choose a hook event to inspect the matching handlers.

8833. Trust, disable, or re-enable non-managed hooks as needed.

884 190 

885Expected: Codex opens the hook browser so you can review configured lifecycle191| Query parameter | Required | What it does |

886hooks. Managed hooks appear as managed and can't be disabled from the user hook192| ------------------ | -------- | ----------------------------------------------------------------------------------------------------------------------------------------------- |

887browser.193| `hostId=<host-id>` | No | Identifies the Codex host that owns the plugin context, such as `local` or one of your configured remote connections. Codex provides these IDs. |

194| `source=manage` | No | Preserves the app's plugin-management entry point. It's not admin-only. |

888 195 

889### Switch agent threads with `/agent`196Example: [Open the OpenAI Developers plugin](codex://plugins/openai-developers@openai-curated)

890 197 

8911. Type `/agent` or `/subagents` and press Enter.198#### Local plugin

8922. Select the thread you want from the picker.

893 199 

894Expected: Codex switches the active thread so you can inspect or continue that200For local or repo marketplace setup, see [Build plugins](https://developers.openai.com/plugins/build/plugins#build-your-own-curated-plugin-list).

895agent's work.

896 201 

897### Send feedback with `/feedback`202| Deep link | Opens |

203| --------------------------------------------------------------------------- | ---------------------------------------------------- |

204| `codex://plugins/<plugin-name>?marketplacePath=<absolute-marketplace-path>` | A local plugin detail page from a local marketplace. |

898 205 

8991. Type `/feedback` and press Enter.206| Query parameter | Required | What it does |

9002. Follow the prompts to include logs or diagnostics.207| --------------------------------------------- | -------- | ---------------------------------------------------------------------------------------------------------- |

208| `marketplacePath=<absolute-marketplace-path>` | Yes | Absolute path to the local `marketplace.json`, for example `/Users/alex/.agents/plugins/marketplace.json`. |

209| `mode=share` | No | Opens the share flow for that local plugin. |

901 210 

902Expected: Codex collects the requested diagnostics and submits them to the211### Pets

903maintainers.

904 212 

905### Sign out with `/logout`213Use these links to open the pet install flow when that feature is enabled.

906 214 

9071. Type `/logout` and press Enter.215| Deep link | Opens |

216| ----------------------------------------------------------------- | --------------------- |

217| `codex://pets/install?name=<pet-name>&imageUrl=<https-image-url>` | The pet install flow. |

908 218 

909Expected: Codex clears local credentials for the current user session.219| Query parameter | Required | What it does |

220| ------------------------------ | -------- | ------------------------------------------------------------------------------------------- |

221| `name=<pet-name>` | Yes | Sets the pet name. The value must contain at least one non-whitespace character. |

222| `imageUrl=<https-image-url>` | Yes | Provides an absolute HTTPS URL for the pet image or sprite sheet. |

223| `description=<text>` | No | Adds a description to the install flow. |

224| `spriteVersionNumber=<1-or-2>` | No | Selects the sprite-sheet format. The default is `1`; the only other supported value is `2`. |

910 225 

911### Exit the CLI with `/quit` or `/exit`226The install link accepts only these query parameters. Invalid names, non-HTTPS

227image URLs, unsupported sprite versions, or extra path segments cause the link

228to do nothing.

912 229 

9131. Type `/quit` (or `/exit`) and press Enter.230## See also

914 231 

915Expected: Codex exits immediately. Save or commit any important work first.232- [Features](https://learn.chatgpt.com/docs/features)

233- [Settings](https://learn.chatgpt.com/docs/reference/settings)

234- [Slash commands](https://learn.chatgpt.com/docs/reference/slash-commands)

cli/slash-commands.md +190 −871

Details

1# Developer commands1# Commands

2 2 

3> For the complete documentation index, see [llms.txt](https://learn.chatgpt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to the page URL.3> For the complete documentation index, see [llms.txt](https://learn.chatgpt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to the page URL.

4 4 

5## How to read this reference5Use these commands and keyboard shortcuts to navigate the app.

6 6 

7This page catalogs every documented Codex CLI command and flag. Use the interactive tables to search by key or description. Each section indicates whether the option is stable or experimental and calls out risky combinations.7## Keyboard shortcuts

8 8 

9The CLI inherits most defaults from `~/.codex/config.toml`. Any9| | Action | Shortcut |

10 `-c key=value` overrides you pass at the command line take10| ----------- | ------------------- | ---------------------------------------------------------------------------------------------------------------------- |

11 precedence for that invocation. See [Config11| **General** | | |

12 basics](https://learn.chatgpt.com/docs/config-file/config-basic#configuration-precedence) for more12| | Command menu | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>P</kbd> or <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>K</kbd> |

13 information.13| | Settings | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>,</kbd> |

14 14| | Keyboard shortcuts | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>/</kbd> |

15## Global flags15| | Open folder | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>O</kbd> |

16 16| | Navigate back | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>[</kbd> |

17<ConfigTable client:load options={globalFlagOptions} />17| | Navigate forward | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>]</kbd> |

18 18| | Increase font size | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>+</kbd> |

19These options apply to the base `codex` command. Most propagate to commands;19| | Decrease font size | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>-</kbd> |

20see the notes above or the relevant command help for exceptions. For propagated20| | Toggle sidebar | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>B</kbd> |

21flags, follow the relevant command help. For example, `codex exec --oss ...`21| | Open review tab | <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>G</kbd> |

22applies `--oss` to `exec`.22| | Toggle review panel | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>B</kbd> |

23 23| | Toggle bottom panel | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>J</kbd> |

24## Command overview24| | Toggle terminal | <kbd>Ctrl</kbd> + <kbd>`</kbd> |

25 25| | Clear the terminal | <kbd>Ctrl</kbd> + <kbd>L</kbd> |

26The Maturity column uses feature maturity labels such as Experimental, Beta,26| **Chat** | Quick chat | <kbd>Cmd</kbd> + <kbd>Option</kbd> + <kbd>N</kbd> (macOS) or <kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>N</kbd> (Windows) |

27 and Stable. See [Feature Maturity](https://learn.chatgpt.com/docs/feature-maturity) for how to27| | New chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>N</kbd> or <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>O</kbd> |

28 interpret these labels.28| | Search chats | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>G</kbd> |

29 29| | Find in chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>F</kbd> |

30<ConfigTable30| | Previous chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>[</kbd> |

31 client:load31| | Next chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>]</kbd> |

32 options={commandOverview}32| **Input** | Dictation | <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>D</kbd> |

33 secondColumnTitle="Maturity"33 

34 secondColumnVariant="maturity"34To find, customize, or reset shortcuts, open **Settings > Keyboard Shortcuts**.

35/>35You can search by command name or switch the search field into keystroke mode

36 36and press the shortcut you want to find.

37## Command details37 

38 38<a id="search-past-tasks-and-find-in-a-task"></a>

39### `codex` (interactive)39 

40 40## Search past chats and find in a chat

41Running `codex` with no subcommand launches the interactive terminal UI (TUI). The agent accepts the global flags above plus image attachments. Web search defaults to cached mode; use `--search` to switch to live browsing. For low-friction local work, use `--sandbox workspace-write --ask-for-approval on-request`.41 

42 42Use chat search (<kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>G</kbd>) to reopen a past

43Use `--remote ws://host:port` or `--remote wss://host:port` to connect the TUI to an app server started with `codex app-server --listen ws://IP:PORT`. For a local Unix socket, use `--remote unix://` for the default socket or `--remote unix://PATH` for an explicit path. Add `--remote-auth-token-env <ENV_VAR>` when the server requires a bearer token for WebSocket authentication.43chat. When expanded matching is available, it can also match chat content and

44 44Git branch names, so you can search for a phrase from the chat or a

45### `codex app-server`45branch such as `fix/login-redirect`.

46 46 

47Launch the Codex app server locally. This is primarily for development and debugging and may change without notice.47Use **Find in chat** (<kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>F</kbd>) after opening

48 48a chat to find text within it. It doesn't search across other chats.

49<ConfigTable client:load options={appServerOptions} />49 

50 50For actions that start with `/`, see [Slash commands](https://learn.chatgpt.com/docs/reference/slash-commands).

51`codex app-server --listen stdio://` keeps the default JSONL-over-stdio behavior, and `codex app-server --stdio` is an alias for that transport. `--listen ws://IP:PORT` enables WebSocket transport for app-server clients. The server accepts `ws://` listen URLs; use TLS termination or a secure proxy when clients connect with `wss://`. Use `--listen unix://` to accept WebSocket handshakes on Codex's default Unix socket, or `--listen unix:///absolute/path.sock` to choose a socket path. If you generate schemas for client bindings, add `--experimental` to include gated fields and methods.51 

52 52## Deep links

53Add `--code-mode-host wss://code-mode.example.com/host` to connect app-server to53 

54a remote Code Mode host instead of starting a local host. This outbound54The ChatGPT desktop app keeps the `codex://` URL scheme for compatibility, so

55connection is separate from `--listen` and shared by every thread in the55links can open specific parts of the app directly. Encode query string values

56app-server process. Use `ws://` only for a localhost or SSH-forwarded host.56before adding them to a URL.

57 57 

58### `codex remote-control`58### Supported links

59 59 

60Run `codex remote-control` to start remote control in the foreground. Use60Use these canonical forms when you create links. The sections below list the full reference by link type.

61`codex remote-control start` to start the local app-server daemon with remote61 

62control enabled, and `codex remote-control stop` to stop it. Managed62| Deep link | Opens |

63remote-control clients and SSH remote workflows use these commands; they aren't63| --------------------------------------------------------------------------- | ------------------------------------------------------- |

64a replacement for `codex app-server --listen` when you're building a local64| `codex://threads/new` | A new local chat. |

65protocol client.65| `codex://new?<query>` | A new local chat with at least one query parameter. |

66 66| `codex://threads/<thread-id>` | A local chat. `<thread-id>` is its technical thread ID. |

67After the daemon is running, use `codex remote-control pair` to create and67| `codex://settings` | Settings. |

68print a short-lived manual pairing code. Add `--json` to any remote-control68| `codex://settings/connections/<connection-type>` | Computer, device, or SSH connection settings. |

69command for machine-readable output. For `pair`, the JSON response includes69| `codex://settings/connections/ssh/add?name=<ssh-config-host>` | Adds a host from your SSH config to Codex. |

70`pairingCode`, `manualPairingCode`, `environmentId`, and `expiresAt`.70| `codex://skills` | Skills. |

71 71| `codex://automations` | Scheduled with the create flow open. |

72### `codex app`72| `codex://plugins/install/<plugin-name>?marketplace=<marketplace-name>` | The install flow for a plugin from a known marketplace. |

73 73| `codex://plugins/<plugin-id>` | A plugin detail page. |

74Launch the ChatGPT desktop app from the terminal on macOS or Windows. On macOS,74| `codex://plugins/<plugin-name>?marketplacePath=<absolute-marketplace-path>` | A local plugin detail page from a local marketplace. |

75Codex can open a specific workspace path; on Windows, Codex prints the path to75| `codex://pets/install?name=<pet-name>&imageUrl=<https-image-url>` | The pet install flow. |

76open.76 

77 77<a id="tasks"></a>

78<ConfigTable client:load options={appOptions} />78 

79 79### Chats

80`codex app` opens an installed ChatGPT desktop app, or starts the installer when80 

81the app is missing. On macOS, Codex opens the provided workspace path; on81Use these links when you need to open an existing local chat or start a new one.

82Windows, it prints the path to open after installation.82 

83 83| Deep link | Opens |

84### `codex debug app-server send-message-v2`84| ----------------------------- | ------------------------------------------------------------------------------------------------------------ |

85 85| `codex://threads/<thread-id>` | A local chat. `<thread-id>` is its technical thread ID. |

86Send one message through app-server's V2 thread/turn flow using the built-in app-server test client.86| `codex://threads/new` | A new local chat. |

87 87| `codex://threads/new?<query>` | A new local chat with optional query parameters. |

88<ConfigTable client:load options={debugAppServerSendMessageV2Options} />88| `codex://new?<query>` | A new local chat. Include at least one of `prompt`, `path`, or `originUrl`; otherwise the link does nothing. |

89 89 

90This debug flow initializes with `experimentalApi: true`, starts a thread, sends a turn, and streams server notifications. Use it to reproduce and inspect app-server protocol behavior locally.90For `codex://threads/new` or `codex://new`, add any of these query parameters as needed; you can combine them in the same URL.

91 91 

92### `codex debug models`92| Query parameter | Required | What it does |

93 93| ---------------------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------- |

94Print the raw model catalog Codex sees as JSON.94| `prompt=<text>` | No | Sets the initial composer text. |

95 95| `path=<absolute-path>` | No | Opens the new chat in a local workspace. `path` must be an absolute path to a local directory. When valid, Codex uses that directory as the active workspace. |

96<ConfigTable client:load options={debugModelsOptions} />96| `originUrl=<git-remote-url>` | No | Matches one of your current workspace roots by Git remote URL. If `path` is also present, Codex resolves `path` first. |

97 97 

98Use `--bundled` when you want to inspect only the catalog bundled with the current binary, without refreshing from the remote models endpoint.98Example: [Show me some fun stats about how I've been using Codex](codex://threads/new?prompt=Show%20me%20some%20fun%20stats%20about%20how%20I%27ve%20been%20using%20Codex)

99 99 

100### `codex debug prompt-input`100<a id="start-a-task-with-a-plugin"></a>

101 101 

102Render the exact model-visible prompt input list as JSON. Use this when102#### Start a chat with a plugin

103debugging instruction discovery, session context, or prompt construction.103 

104 104To help users start a plugin-backed chat, include a plugin mention in the

105<ConfigTable client:load options={debugPromptInputOptions} />105prompt before you encode it:

106 106 

107### `codex apply`107```text

108 108[@Example](plugin://example@openai-curated) Summarize this document: https://example.com/document/123

109Apply the most recent diff from a Codex cloud chat to your local repository. You must authenticate and have access to the chat.

110 

111<ConfigTable client:load options={applyOptions} />

112 

113Codex prints the patched files and exits non-zero if `git apply` fails (for example, due to conflicts).

114 

115### `codex review`

116 

117Run a code review non-interactively. Choose exactly one review target, or pass

118custom review instructions as a prompt.

119 

120<ConfigTable client:load options={reviewOptions} />

121 

122`--uncommitted`, `--base`, `--commit`, and a custom `PROMPT` conflict with one

123another. Use `--title` only with `--commit`.

124 

125### `codex archive` and `codex unarchive`

126 

127Archive or restore a saved interactive session by session ID or session name.

128Use these commands when you want to clean up the session picker without deleting

129the transcript. Session IDs take precedence over session names.

130 

131```bash

132codex archive <SESSION>

133codex unarchive <SESSION>

134```109```

135 110 

136<ConfigTable client:load options={archiveOptions} />111Encode the complete prompt as a URI component—for example, with

112`encodeURIComponent` in JavaScript—and pass it to the `prompt` parameter:

137 113 

138### `codex delete`114```text

139 115codex://new?prompt=%5B%40Example%5D(plugin%3A%2F%2Fexample%40openai-curated)%20Summarize%20this%20document%3A%20https%3A%2F%2Fexample.com%2Fdocument%2F123

140Permanently delete a saved interactive session by session ID or session name.

141Use this only when you want to remove the transcript instead of hiding it from

142active session lists.

143 

144```bash

145codex delete <SESSION>

146codex delete <SESSION_UUID> --force

147```116```

148 117 

149<ConfigTable client:load options={deleteOptions} />118The link opens a new chat with the decoded prompt in the composer. It doesn't

150 119send the prompt automatically. After the user sends it, Codex can use an

151Use `--force` only with a session UUID. Named sessions still require120installed plugin in that chat. If the plugin isn't installed but is available

152confirmation so Codex doesn't delete a repeated or ambiguous name without a prompt.121to the user, Codex asks the user to install it and connect any required connectors.

153 122After setup, the user can select **Continue** to resume the same chat. Workspace

154### `codex cloud`123settings can limit which plugins a user can install. For plugin installation

155 124and permission details, see [Plugins](https://learn.chatgpt.com/docs/plugins).

156Interact with Codex cloud chats from the terminal. The default command opens an interactive picker; `codex cloud exec` submits a task directly, and `codex cloud list` returns recent chats for scripting or quick inspection.

157 

158<ConfigTable client:load options={cloudExecOptions} />

159 

160Authentication follows the same credentials as the main CLI. Codex exits non-zero if the task submission fails.

161 

162#### `codex cloud list`

163 

164List recent cloud chats with optional filtering and pagination.

165 

166<ConfigTable client:load options={cloudListOptions} />

167 

168Plain-text output prints a task URL followed by status details. Use `--json` for automation. The JSON payload contains a `tasks` array plus an optional `cursor` value. Each task includes `id`, `url`, `title`, `status`, `updated_at`, `environment_id`, `environment_label`, `summary`, `is_review`, and `attempt_total`.

169 

170### `codex completion`

171 

172Generate shell completion scripts and redirect the output to the appropriate location, for example `codex completion zsh > "${fpath[1]}/_codex"`.

173 

174<ConfigTable client:load options={completionOptions} />

175 

176### `codex doctor`

177 

178Generate a local diagnostic report before filing a support issue or

179while investigating a broken Codex installation. The report checks installation,

180configuration, authentication, runtime, Git, terminal, app-server, and thread

181inventory health.

182 

183<ConfigTable client:load options={doctorOptions} />

184 

185### `codex features`

186 

187Manage feature flags stored in `$CODEX_HOME/config.toml`. The `enable` and

188`disable` commands persist changes so they apply to future sessions. The

189`features` subcommand doesn't accept `--profile`.

190 

191<ConfigTable client:load options={featuresOptions} />

192 

193### `codex exec`

194 

195Use `codex exec` (or the short form `codex e`) for scripted or CI-style runs that should finish without human interaction.

196 

197<ConfigTable client:load options={execOptions} />

198 

199Codex writes formatted output by default. Add `--json` to receive newline-delimited JSON events (one per state change). The optional `resume` subcommand lets you continue non-interactive tasks. Use `--last` to pick the most recent session from the current working directory, or add `--all` to search across all sessions:

200 

201<ConfigTable client:load options={execResumeOptions} />

202 

203### `codex execpolicy`

204 

205Check `execpolicy` rule files before you save them. `codex execpolicy check` accepts one or more `--rules` flags (for example, files under `~/.codex/rules`) and emits JSON showing the strictest decision and any matching rules. Add `--pretty` to format the output. The `execpolicy` command is currently in preview.

206 

207<ConfigTable client:load options={execpolicyOptions} />

208 

209### `codex login`

210 

211Authenticate the CLI with a ChatGPT account, API key, or access token. With no flags, Codex opens a browser for the ChatGPT OAuth flow.

212 

213<ConfigTable client:load options={loginOptions} />

214 

215`codex login status` exits with `0` when credentials are present, which is helpful in automation scripts.

216 

217### `codex logout`

218 

219Remove saved credentials for both API key and ChatGPT authentication. This command has no flags.

220 

221### `codex mcp`

222 

223Manage Model Context Protocol server entries stored in `~/.codex/config.toml`.

224 

225<ConfigTable client:load options={mcpCommands} />

226 

227The `add` subcommand supports both stdio and streamable HTTP transports:

228 

229<ConfigTable client:load options={mcpAddOptions} />

230 

231OAuth actions (`login`, `logout`) only work with streamable HTTP servers (and only when the server supports OAuth).

232 

233### `codex plugin`

234 

235Install, list, and remove plugins from configured marketplaces.

236 

237<ConfigTable client:load options={pluginCommands} />

238 

239`codex plugin add --json` prints `pluginId`, `name`, `marketplaceName`,

240`version`, `installedPath`, and `authPolicy`. `codex plugin list --json` prints

241`installed` and `available` arrays. Entries include `pluginId`, `name`,

242`marketplaceName`, `version`, `installed`, `enabled`, `source`, `installPolicy`,

243`authPolicy`, and, when available, `marketplaceSource` with the configured

244marketplace source type and value. `codex plugin remove --json` prints

245`pluginId`, `name`, and `marketplaceName`.

246 

247### `codex plugin marketplace`

248 

249Manage plugin marketplace sources that Codex can browse and install from.

250 

251<ConfigTable client:load options={marketplaceCommands} />

252 

253`codex plugin marketplace add` accepts GitHub shorthand such as `owner/repo` or

254`owner/repo@ref`, HTTP or HTTPS Git URLs, SSH Git URLs, and local marketplace

255root directories. Use `--ref` to pin a Git ref, and repeat `--sparse PATH` to

256use a sparse checkout for Git-backed marketplace repositories.

257 

258`codex plugin marketplace list` prints in-scope marketplace names and roots,

259including implicitly discovered default marketplaces and configured marketplace

260snapshots.

261 

262Add `--json` to marketplace add, list, upgrade, or remove commands for

263automation-friendly output. Marketplace add JSON includes `marketplaceName`,

264`installedRoot`, and `alreadyAdded`; list JSON includes a `marketplaces` array

265with `name`, `root`, and optional `marketplaceSource`; upgrade JSON includes

266`selectedMarketplaces`, `upgradedRoots`, and `errors`; remove JSON includes

267`marketplaceName` and `installedRoot`.

268 

269### `codex mcp-server`

270 

271Run Codex as an MCP server over stdio so that other tools can connect. This command inherits global configuration overrides and exits when the downstream client closes the connection.

272 

273### `codex resume`

274 

275Continue an interactive session by ID or resume the most recent chat. `codex resume` scopes `--last` to the current working directory unless you pass `--all`. It accepts the same global flags as `codex`, including model and sandbox overrides.

276 

277If the current working directory differs from the session's saved directory,

278Codex asks which directory to use. Set

279[`tui.resume_cwd`](https://learn.chatgpt.com/docs/config-file/config-reference) to `"current"` or

280`"session"` to reuse that choice without a prompt. An explicit `--cd` (`-C`)

281override takes precedence over `tui.resume_cwd`.

282 

283<ConfigTable client:load options={resumeOptions} />

284 

285### `codex fork`

286 

287Fork a previous interactive session into a new chat. By default, `codex fork` opens the session picker; add `--last` to fork your most recent session instead.

288 

289When the current and saved session directories differ, `codex fork` uses the

290same working-directory prompt and `tui.resume_cwd` setting as `codex resume`.

291 

292<ConfigTable client:load options={forkOptions} />

293 

294### `codex sandbox`

295 

296Use the sandbox helper to run a command under the same policies Codex uses internally.

297 

298#### macOS seatbelt

299 

300<ConfigTable client:load options={sandboxMacOptions} />

301 

302#### Linux Landlock

303 

304<ConfigTable client:load options={sandboxLinuxOptions} />

305 

306#### Windows

307 

308<ConfigTable client:load options={sandboxWindowsOptions} />

309 

310### `codex update`

311 

312Check for and apply a Codex CLI update when the installed release supports self-update. Debug builds print a message telling you to install a release build instead.

313 

314## Flag combinations and safety tips

315 

316- Use `--sandbox workspace-write` for unattended local work that can stay inside the workspace, and avoid `--dangerously-bypass-approvals-and-sandbox` unless you are inside a dedicated sandbox VM.

317- When you need to grant Codex write access to more directories, prefer `--add-dir` rather than forcing `--sandbox danger-full-access`.

318- Pair `--json` with `--output-last-message` in CI to capture machine-readable progress and a final natural-language summary.

319 

320## Interactive shortcuts

321 

322- Type `@` to search for a file in the workspace and add its path to the prompt.

323- Press <kbd>Up</kbd> or <kbd>Down</kbd> to restore draft history.

324- Press <kbd>Ctrl</kbd>+<kbd>R</kbd> to search prompt history, then press <kbd>Enter</kbd> to use a match or <kbd>Esc</kbd> to cancel.

325- Press <kbd>Ctrl</kbd>+<kbd>O</kbd> or run `/copy` to copy the latest completed Codex output.

326- Prefix a line with `!` to run a local shell command under the current approval and sandbox settings.

327- Press <kbd>Tab</kbd> while Codex is working to queue a follow-up prompt, slash command, or shell command for the next turn.

328- Press <kbd>Enter</kbd> while Codex is working to inject new instructions into the current turn.

329- Press <kbd>Esc</kbd> twice with an empty composer to edit the previous user message and fork the chat from that point.

330- Press <kbd>Ctrl</kbd>+<kbd>C</kbd> or run `/exit` to close the session.

331 

332## Related resources

333 

334- [Codex CLI overview](https://learn.chatgpt.com/docs/codex/cli): installation, upgrades, and quick tips.

335- [Config basics](https://learn.chatgpt.com/docs/config-file/config-basic): persist defaults like the model and provider.

336- [Advanced Config](https://learn.chatgpt.com/docs/config-file/config-advanced): profiles, providers, sandbox tuning, and integrations.

337- [AGENTS.md](https://learn.chatgpt.com/docs/agent-configuration/agents-md): conceptual overview of Codex agent capabilities and best practices.

338 

339Slash commands give you fast, keyboard-first control over Codex. Type `/` in

340the composer to open the slash popup, choose a command, and Codex will perform

341actions such as switching models, adjusting permissions, or summarizing long

342chats without leaving the terminal.

343 

344This guide shows you how to:

345 

346- Find the right built-in slash command for a task

347- Steer an active session with commands like `/model`, `/fast`,

348 `/personality`, `/permissions`, `/approve`, `/raw`, `/agent`, and `/status`

349 

350## Built-in slash commands

351 

352Codex ships with the following commands. Open the slash popup and start typing

353the command name to filter the list.

354 

355When a chat is already running, you can type a slash command and press `Tab` to

356queue it for the next turn. Codex parses queued slash commands when they run, so

357command menus and errors appear after the current turn finishes. Slash

358completion still works before you queue the command.

359 

360| Command | Purpose | When to use it |

361| ------------------------------------------------------------------------------------------- | --------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- |

362| [`/permissions`](#update-permissions-with-permissions) | Set what Codex can do without asking first. | Relax or tighten approval requirements mid-session, such as switching between Auto and Read Only. |

363| [`/ide`](#include-ide-context-with-ide) | Include open files, current selection, and other IDE context. | Pull editor context into the next prompt without re-explaining what's open in your IDE. |

364| [`/keymap`](#remap-tui-shortcuts-with-keymap) | Remap TUI keyboard shortcuts. | Inspect and persist custom shortcut bindings in `config.toml`. |

365| [`/vim`](#toggle-vim-mode-with-vim) | Toggle Vim mode for the composer. | Switch between Vim normal/insert behavior and the default composer editing mode. |

366| [`/setup-default-sandbox`](#set-up-the-elevated-windows-sandbox-with-setup-default-sandbox) | Set up the elevated agent sandbox (Windows only). | Replace the degraded Windows sandbox after Codex offers the elevated setup. |

367| [`/sandbox-add-read-dir`](#grant-sandbox-read-access-with-sandbox-add-read-dir) | Grant sandbox read access to an extra directory (Windows only). | Unblock commands that need to read an absolute directory path outside the current readable roots. |

368| [`/agent`, `/subagents`](#switch-agent-threads-with-agent) | Switch the active agent thread. | Inspect or continue work in a spawned subagent thread. |

369| [`/apps`](#browse-apps-with-apps) | Browse apps (connectors) and insert them into your prompt. | Attach an app as `$app-slug` before asking Codex to use it. |

370| [`/plugins`](#browse-plugins-with-plugins) | Browse installed and discoverable plugins. | Inspect plugin tools, install suggested plugins, or manage plugin availability. |

371| [`/hooks`](#view-and-manage-lifecycle-hooks-with-hooks) | View and manage lifecycle hooks. | Inspect configured hooks, trust new or changed hooks, or disable non-managed hooks before they run. |

372| [`/clear`](#clear-the-terminal-and-start-a-new-chat-with-clear) | Clear the terminal and start a fresh chat. | Reset the visible UI and chat context together when you want a fresh start. |

373| [`/rename`](#rename-the-current-chat-with-rename) | Rename the current chat. | Give a saved session a recognizable name without leaving the TUI. |

374| [`/archive`](#archive-the-current-session-with-archive) | Archive the current session and exit Codex. | Remove the current session from active session lists without deleting its transcript. |

375| [`/delete`](#delete-the-current-session-with-delete) | Permanently delete the current session and exit Codex. | Remove the transcript and descendant sessions when archiving isn't enough. |

376| [`/compact`](#keep-transcripts-lean-with-compact) | Summarize the visible chat to free tokens. | Use after long runs so Codex retains key points without blowing the context window. |

377| [`/copy`](#copy-the-latest-response-with-copy) | Copy the latest completed Codex output. | Grab the latest finished response or plan text without manually selecting it. You can also press `Ctrl+O`. |

378| [`/diff`](#review-changes-with-diff) | Show the Git diff, including files Git isn't tracking yet. | Review Codex's edits before you commit or run tests. |

379| [`/exit`](#exit-the-cli-with-quit-or-exit) | Exit the CLI (same as `/quit`). | Alternative spelling; both commands exit the session. |

380| [`/experimental`](#toggle-experimental-features-with-experimental) | Toggle experimental features. | Enable options such as Network proxy or Prevent sleep while running. |

381| [`/approve`](#approve-an-auto-review-denial-with-approve) | Approve one retry of a recent auto review denial. | Retry a command or action that the auto reviewer denied. |

382| [`/memories`](#configure-memories-with-memories) | Configure memory use and generation. | Turn memory injection or memory generation on or off without leaving the TUI. |

383| [`/skills`](#use-skills-with-skills) | Browse and use skills. | Improve task-specific behavior by selecting a relevant local skill. |

384| [`/import`](#import-claude-code-or-cursor-configuration-with-import) | Import Claude Code or Cursor setup, projects, and recent chats. | Migrate supported external-agent artifacts into Codex configuration and local files. |

385| [`/feedback`](#send-feedback-with-feedback) | Send logs to the Codex maintainers. | Report issues or share diagnostics with support. |

386| [`/init`](#generate-agentsmd-with-init) | Generate an `AGENTS.md` scaffold in the current directory. | Capture persistent instructions for the repository or subdirectory you're working in. |

387| [`/logout`](#sign-out-with-logout) | Sign out of Codex. | Clear local credentials when using a shared machine. |

388| [`/mcp`](#list-mcp-tools-with-mcp) | List configured Model Context Protocol (MCP) tools. | Check which external tools Codex can call during the session; add `verbose` for server details. |

389| [`/mention`](#highlight-files-with-mention) | Attach a file to the chat. | Point Codex at specific files or folders you want it to inspect next. |

390| [`/model`](#set-the-active-model-with-model) | Choose the active model (and reasoning effort, when available). | Switch between models such as `gpt-5.6-luna` and `gpt-5.6-terra` before running a task. |

391| [`/fast`](#toggle-fast-mode-with-fast) | Toggle a Fast service tier when the model catalog exposes one. | Turn the current model's Fast tier on or off and persist the selection. |

392| [`/plan`](#switch-to-plan-mode-with-plan) | Switch to plan mode and optionally send a prompt. | Ask Codex to propose an execution plan before implementation work starts. |

393| [`/goal`](#set-or-view-a-task-goal-with-goal) | Set, edit, pause, resume, view, or clear a task goal. | Give Codex a persistent target to track while a larger task runs. |

394| [`/personality`](#set-a-communication-style-with-personality) | Choose a communication style for responses. | Make Codex more concise, more explanatory, or more collaborative without changing your instructions. |

395| [`/ps`](#check-background-terminals-with-ps) | Show background terminals and their recent output. | Check long-running commands without leaving the main transcript. |

396| [`/stop`](#stop-background-terminals-with-stop) | Stop all background terminals. | Cancel background terminal work started by the current session. |

397| [`/fork`](#fork-the-current-chat-with-fork) | Fork the current chat into a new chat. | Branch the active session to explore a new approach without losing the current transcript. |

398| [`/app`](#continue-in-the-desktop-app-with-app) | Continue the current session in the ChatGPT desktop app. | Move from the TUI to the desktop app on macOS or Windows. |

399| [`/side`, `/btw`](#start-a-side-chat-with-side) | Start an ephemeral side chat. | Ask a focused follow-up without disrupting the main chat's transcript. |

400| [`/raw`](#toggle-raw-scrollback-with-raw) | Toggle raw scrollback mode. | Make terminal selection and copying less formatted while reviewing long output. |

401| [`/resume`](#resume-a-saved-chat-with-resume) | Resume a saved chat from your session list. | Continue work from a previous CLI session without starting over. |

402| [`/new`](#start-a-new-chat-with-new) | Start a new chat inside the same CLI session. | Reset the chat context without leaving the CLI when you want a fresh prompt in the same repo. |

403| [`/quit`](#exit-the-cli-with-quit-or-exit) | Exit the CLI. | Leave the session immediately. |

404| [`/review`](#ask-for-a-working-tree-review-with-review) | Ask Codex to review your working tree. | Run after Codex completes work or when you want a second set of eyes on local changes. |

405| [`/status`](#inspect-the-session-with-status) | Display session configuration and token usage. | Confirm the active model, approval policy, writable roots, and remaining context capacity. |

406| [`/usage`](#view-account-usage-with-usage) | View account token usage or use a rate-limit reset. | Inspect daily, weekly, or cumulative ChatGPT token activity from inside the TUI. |

407| [`/debug-config`](#inspect-config-layers-with-debug-config) | Print config layer and requirements diagnostics. | Debug precedence and policy requirements, including experimental network constraints. |

408| [`/statusline`](#configure-footer-items-with-statusline) | Configure TUI status-line fields interactively. | Pick and reorder footer items (model/context/limits/git/tokens/session) and persist in config.toml. |

409| [`/title`](#configure-terminal-title-items-with-title) | Configure terminal window or tab title fields interactively. | Pick and reorder title items such as project, status, thread, branch, model, and task progress. |

410| [`/theme`](#choose-a-syntax-theme-with-theme) | Choose a syntax-highlighting theme. | Preview and persist a terminal syntax-highlighting theme. |

411| [`/pets`, `/pet`](#choose-a-terminal-pet-with-pets) | Choose or hide a terminal pet. | Personalize the TUI with a built-in or custom ambient pet. |

412 

413`/quit` and `/exit` both exit the CLI. Use them only after you have saved or

414committed any important work.

415 

416Use `/permissions` to adjust what Codex can do without asking first. Use

417`/approve` only when you need to retry a recent action that automatic review

418denied.

419 

420## Control your session with slash commands

421 

422The following workflows keep your session on track without restarting Codex.

423 

424### Set the active model with `/model`

425 

4261. Start Codex and open the composer.

4272. Type `/model` and press Enter.

4283. Choose a model such as `gpt-5.6-luna` or `gpt-5.6-terra` from the popup.

429 

430Expected: Codex confirms the new model in the transcript. Run `/status` to verify the change.

431 

432### Toggle Fast mode with `/fast`

433 

4341. Type `/fast` to turn the current model's Fast service tier on.

4352. Type `/fast` again to turn it off.

436 

437Expected: Codex toggles the tier and saves the selection. In the TUI footer,

438you can also show a Fast mode status-line item with `/statusline`.

439 

440Fast tier commands are catalog-driven. If the current model doesn't advertise a

441Fast tier, Codex won't show `/fast`.

442 

443### Set a communication style with `/personality`

444 

445Use `/personality` to change how Codex communicates without rewriting your prompt.

446 

4471. In an active chat, type `/personality` and press Enter.

4482. Choose a style from the popup.

449 

450Expected: Codex confirms the new style in the transcript and uses it for later

451responses in the chat.

452 

453Codex supports `friendly`, `pragmatic`, and `none` personalities. Use `none`

454to disable personality instructions.

455 

456If the active model doesn't support personality-specific instructions, Codex hides this command.

457 

458### Switch to plan mode with `/plan`

459 

4601. Type `/plan` and press Enter to switch the active chat into plan

461 mode.

4622. Optional: provide inline prompt text (for example, `/plan Propose a

463migration plan for this service`).

4643. You can paste content or attach images while using inline `/plan` arguments.

465 

466Expected: Codex enters plan mode and uses your optional inline prompt as the first planning request.

467 

468While Codex is already working, `/plan` is temporarily unavailable.

469 

470### Set or view a task goal with `/goal`

471 

4721. Type `/goal <objective>` to set the goal, for example `/goal Finish the migration and keep tests green`.

4732. Type `/goal` to view the current goal.

4743. Use `/goal edit` to revise the objective. Use `/goal pause`, `/goal resume`, or `/goal clear` to pause, resume, or remove it.

475 

476Expected: Codex keeps the goal attached to the active chat while work continues.

477 

478Goal objectives must be non-empty and at most 4,000 characters. For longer

479instructions, put the details in a file and point the goal at that file.

480 

481### Toggle experimental features with `/experimental`

482 

4831. Type `/experimental` and press Enter.

4842. Toggle the features you want (for example, Network proxy or Prevent sleep while running), then restart Codex if the prompt asks you to.

485 

486Expected: Codex saves your feature choices to config and applies them on restart.

487 

488### Approve an auto review denial with `/approve`

489 

490Use `/approve` when the automatic reviewer denied a recent action and you want

491Codex to retry it once.

492 

4931. Type `/approve`.

4942. Confirm the retry when Codex shows the relevant denied action.

495 

496Expected: Codex retries that denied action once under the current session

497policy.

498 

499### Configure memories with `/memories`

500 

5011. Type `/memories`.

5022. Choose whether Codex should use existing memories, generate new memories, or

503 keep memory behavior disabled.

504 

505Expected: Codex updates the relevant memory settings for future sessions.

506 

507### Use skills with `/skills`

508 

5091. Type `/skills`.

5102. Pick the skill you want Codex to apply.

511 

512Expected: Codex inserts the selected skill context so the next request follows

513that skill's instructions.

514 

515<a id="import-claude-code-configuration-with-import"></a>

516 

517### Import Claude Code or Cursor configuration with `/import`

518 

5191. Type `/import`.

5202. Choose **Claude Code** or **Cursor**.

5213. Select the setup, project files, or recent chats you want to migrate.

522 

523Expected: Codex opens the external-agent import picker and imports the selected

524supported artifacts into Codex configuration and local files. Session discovery

525includes up to 50 chats from the last 30 days.

526 

527Run `/import` from a local TUI session. It's unavailable while a task is running,

528in remote sessions, and while connected to the local app-server daemon.

529 

530For the desktop app workflow and supported artifact types, see [Import from

531another agent](https://learn.chatgpt.com/docs/import).

532 

533<a id="clear-the-terminal-and-start-a-new-chat-with-clear"></a>

534<a id="clear-the-terminal-and-start-a-new-task-with-clear"></a>

535 

536### Clear the terminal and start a new chat with `/clear`

537 

5381. Type `/clear` and press Enter.

539 

540Expected: Codex clears the terminal, resets the visible transcript, and starts

541a fresh chat in the same CLI session.

542 

543To name the new chat as you create it, run `/clear release prep`.

544 

545Unlike <kbd>Ctrl</kbd>+<kbd>L</kbd>, `/clear` starts a new chat.

546 

547<kbd>Ctrl</kbd>+<kbd>L</kbd> only clears the terminal view and keeps the current

548chat. Codex disables both actions while a task is in progress.

549 

550### Archive the current session with `/archive`

551 

5521. Type `/archive` and press Enter.

5532. Confirm that you want to archive the current session and exit Codex.

554 

555Expected: Codex archives the current session and closes the interactive TUI.

556Codex keeps the session transcript stored locally; restore it later with

557`codex unarchive <SESSION>`.

558 

559`/archive` is unavailable while a task is running.

560 

561### Delete the current session with `/delete`

562 

5631. Type `/delete` and press Enter.

5642. Confirm that you want to delete the current session and exit Codex.

565 

566Expected: Codex deletes the current session transcript and closes the

567interactive TUI. Deletion is permanent and also removes spawned descendant

568sessions.

569 

570`/delete` is unavailable while a chat is running or in a side chat.

571 

572### Update permissions with `/permissions`

573 

5741. Type `/permissions` and press Enter.

5752. Select the approval preset that matches your comfort level, for example

576 `Auto` for hands-off runs or `Read Only` to review edits. When named

577 permission profiles are active, the picker also shows configured custom

578 profiles and their descriptions.

579 

580Expected: Codex announces the updated policy. Future actions respect the

581updated approval mode until you change it again.

582 

583### Include IDE context with `/ide`

584 

5851. Type `/ide`.

5862. Add optional inline text if you want to explain what Codex should do with the

587 current IDE selection or open files.

588 

589Expected: Codex includes available IDE context in the next prompt.

590 

591### Toggle Vim mode with `/vim`

592 

5931. Type `/vim`.

5942. Continue editing in the composer.

595 

596Expected: Codex toggles composer Vim mode for the current session. To make Vim

597mode the default for new sessions, set `tui.vim_mode_default = true` in

598`config.toml`.

599 

600### Set up the elevated Windows sandbox with `/setup-default-sandbox`

601 

602This command appears only on Windows when Codex is using the degraded

603restricted-token sandbox.

604 

6051. Type `/setup-default-sandbox`.

6062. Follow the administrator setup flow.

607 

608Expected: Codex configures the elevated Windows sandbox and selects the

609corresponding automatic approval preset.

610 

611### Copy the latest response with `/copy`

612 

6131. Type `/copy` and press Enter.

614 

615Expected: Codex copies the latest completed Codex output to your clipboard.

616 

617If a turn is still running, `/copy` uses the latest completed output instead of

618the in-progress response. The command is unavailable before the first completed

619Codex output and immediately after a rollback.

620 

621You can also press <kbd>Ctrl</kbd>+<kbd>O</kbd> from the main TUI to copy the

622latest completed response without opening the slash command menu.

623 

624### Toggle raw scrollback with `/raw`

625 

6261. Type `/raw`, `/raw on`, or `/raw off`.

627 

628Expected: Codex toggles raw scrollback mode, which makes terminal selection and

629copying more direct. You can also use the default <kbd>Alt</kbd>+<kbd>R</kbd>

630binding or persist the default with `tui.raw_output_mode = true`.

631 

632### Grant sandbox read access with `/sandbox-add-read-dir`

633 

634This command is available only when running the CLI natively on Windows.

635 

6361. Type `/sandbox-add-read-dir C:\absolute\directory\path` and press Enter.

6372. Confirm the path is an existing absolute directory.

638 

639Expected: Codex refreshes the Windows sandbox policy and grants read access to

640that directory for later commands that run in the sandbox.

641 

642### Inspect the session with `/status`

643 

6441. In any chat, type `/status`.

6452. Review the output for the active model, approval policy, writable roots, and

646 current token usage. When the TUI connects remotely, the output also

647 shows the remote address and the server version.

648 

649Expected: Codex prints a summary confirming that it's operating where you

650expect.

651 

652### View account usage with `/usage`

653 

6541. Type `/usage` to open the usage menu.

6552. Choose whether to show token activity or redeem an available earned reset.

6563. To open token activity directly, type `/usage daily`, `/usage weekly`, or `/usage cumulative`.

657 

658Expected: Codex opens usage actions or shows account token activity for the

659selected view. If the session doesn't have Codex service account auth, Codex

660shows a sign-in requirement.

661 

662### Inspect config layers with `/debug-config`

663 

6641. Type `/debug-config`.

6652. Review the output for config layer order (lowest precedence first), on/off

666 state, and policy sources.

667 

668Expected: Codex prints layer diagnostics plus policy details such as

669`allowed_approval_policies`, `allowed_sandbox_modes`, `mcp_servers`, `rules`,

670`enforce_residency`, and `experimental_network` when configured.

671 

672Use this output to debug why an effective setting differs from `config.toml`.

673 

674### Configure footer items with `/statusline`

675 

6761. Type `/statusline`.

6772. Use the picker to toggle and reorder items, then confirm.

678 

679Expected: The footer status line updates immediately and persists to

680`tui.status_line` in `config.toml`.

681 

682Available status-line items include model, model+reasoning, context stats, rate

683limits, git branch, token counters, session id, current directory/project root,

684and Codex version.

685 

686### Configure terminal title items with `/title`

687 

6881. Type `/title`.

6892. Use the picker to toggle and reorder items, then confirm.

690 

691Expected: The terminal window or tab title updates immediately and persists to

692`tui.terminal_title` in `config.toml`.

693 

694Available title items include app name, project, spinner, status, thread, git

695branch, model, and task progress.

696 

697### Choose a syntax theme with `/theme`

698 

6991. Type `/theme`.

7002. Preview a theme from the picker, then confirm.

701 

702Expected: Codex updates syntax highlighting and persists the choice to

703`tui.theme` in `config.toml`.

704 

705### Choose a terminal pet with `/pets`

706 

7071. Type `/pets` (or `/pet`) to open the pet picker.

7082. Choose a built-in or custom pet, or turn pets off.

709 

710Expected: Codex displays the selected ambient pet in supported terminals and

711persists the selection. You can also type `/pets off` to hide it.

712 

713### Remap TUI shortcuts with `/keymap`

714 

715Use `/keymap` to inspect, update, and persist keyboard shortcut bindings for the TUI.

716 

7171. Type `/keymap`.

7182. Pick the shortcut context and action you want to change.

7193. Enter the new binding or remove the existing one.

720 

721Expected: Codex updates the active keymap and writes the custom binding to `tui.keymap` in `config.toml`.

722 

723Key bindings use names such as `ctrl-a`, `shift-enter`, and `page-down`. Context-specific bindings override `tui.keymap.global`; an empty binding list unbinds the action.

724 

725### Check background terminals with `/ps`

726 

7271. Type `/ps`.

7282. Review the list of background terminals and their status.

729 

730Expected: Codex shows each background terminal's command plus up to three

731recent, non-empty output lines so you can gauge progress at a glance.

732 

733Background terminals appear when `unified_exec` is in use; otherwise, the list may be empty.

734 

735### Stop background terminals with `/stop`

736 

7371. Type `/stop`.

7382. Confirm if Codex asks before stopping the listed terminals.

739 

740Expected: Codex stops all background terminals for the current session. `/clean`

741is still available as an alias for `/stop`.

742 

743### Keep transcripts lean with `/compact`

744 

7451. After a long exchange, type `/compact`.

7462. Confirm when Codex offers to summarize the chat so far.

747 

748Expected: Codex replaces earlier turns with a concise summary, freeing context

749while keeping critical details.

750 

751### Review changes with `/diff`

752 

7531. Type `/diff` to inspect the Git diff.

7542. Scroll through the output inside the CLI to review edits and added files.

755 

756Expected: Codex shows changes you've staged, changes you haven't staged yet,

757and files Git hasn't started tracking, so you can decide what to keep.

758 

759### Highlight files with `/mention`

760 

7611. Type `/mention` followed by a path, for example `/mention src/lib/api.ts`.

7622. Select the matching result from the popup.

763 

764Expected: Codex adds the file to the chat, ensuring follow-up turns reference it directly.

765 

766<a id="start-a-new-conversation-with-new"></a>

767 

768### Start a new chat with `/new`

769 

7701. Type `/new` and press Enter.

771 

772Expected: Codex starts a fresh chat in the same CLI session, so you

773can switch chats without leaving your terminal.

774 

775To name the new chat as you create it, run `/new bug bash`.

776 

777Unlike `/clear`, `/new` doesn't clear the current terminal view first.

778 

779<a id="rename-the-current-chat-with-rename"></a>

780<a id="rename-the-current-task-with-rename"></a>

781 

782### Rename the current chat with `/rename`

783 

7841. Type `/rename <name>`, or type `/rename` to open the naming prompt.

7852. Enter a short name that will help you find the chat later.

786 

787Expected: Codex updates the saved chat name without changing its transcript.

788 

789<a id="resume-a-saved-conversation-with-resume"></a>

790 

791### Resume a saved chat with `/resume`

792 

7931. Type `/resume` and press Enter.

7942. Choose the session you want from the saved-session picker.

795 

796Expected: Codex reloads the selected chat's transcript so you can pick

797up where you left off, keeping the original history intact.

798 

799<a id="fork-the-current-conversation-with-fork"></a>

800 

801### Fork the current chat with `/fork`

802 

8031. Type `/fork` and press Enter.

804 

805Expected: Codex clones the current chat into a new chat with a fresh

806ID, leaving the original transcript untouched so you can explore an alternative

807approach in parallel.

808 

809If you need to fork a saved session instead of the current one, run

810`codex fork` in your terminal to open the session picker.

811 

812### Continue in the desktop app with `/app`

813 

814On macOS and Windows, type `/app` to open the current session in the ChatGPT

815desktop app. If the app isn't installed or running, Codex shows an error asking

816you to install or launch it.

817 

818Expected: The desktop app opens the same saved chat so you can continue there.

819 

820<a id="start-a-side-conversation-with-side"></a>

821 

822### Start a side chat with `/side`

823 125 

824Use `/side` to start an ephemeral fork from the current chat without switching away from the main chat.126### Settings

825 127 

8261. Type `/side` to open a side chat.128Use these links when you need to open Settings or a specific settings page.

8272. Optionally add inline text, for example `/side Check whether this plan has an obvious risk`.

8283. Return to the parent chat after the focused detour finishes.

829 129 

830Expected: Codex opens a side chat whose transcript is separate from130| Deep link | Opens |

831the parent chat. While you are in side mode, the TUI continues to show the131| ------------------------------------------------------------- | -------------------------------------------------------------------------------------------- |

832parent chat's status so you can see whether the main chat is still running.132| `codex://settings` | Settings. |

133| `codex://settings/browser-use` | Browser settings. |

134| `codex://settings/computer-use/google-chrome` | Google Chrome settings for computer use. |

135| `codex://settings/connections` | Remote connections settings. |

136| `codex://settings/connections/computer` | Settings for controlling this Mac or PC from another device. |

137| `codex://settings/connections/devices` | Settings for controlling other devices. |

138| `codex://settings/connections/ssh` | SSH connection settings. |

139| `codex://settings/connections/ssh/add?name=<ssh-config-host>` | Adds the named host alias as a Codex-managed connection, then opens SSH connection settings. |

833 140 

834`/side` is unavailable inside another side chat and during review mode.141The `name` value must match a host alias in `~/.ssh/config`. The link disables

142automatic connection for the added host. If Codex can't find the named host, it

143opens SSH connection settings and shows an error.

835 144 

836### Generate `AGENTS.md` with `/init`145Unsupported `codex://settings/...` paths open the main Settings page.

837 146 

8381. Run `/init` in the directory where you want Codex to look for persistent instructions.147### Skills

8392. Review the generated `AGENTS.md`, then edit it to match your repository conventions.

840 148 

841Expected: Codex creates an `AGENTS.md` scaffold you can refine and commit for149Use these links when you need to open Skills.

842future sessions.

843 150 

844### Ask for a working tree review with `/review`151| Deep link | Opens |

152| ---------------- | ------- |

153| `codex://skills` | Skills. |

845 154 

8461. Type `/review`.155### Scheduled

8472. Follow up with `/diff` if you want to inspect the exact file changes.

848 156 

849Expected: Codex summarizes issues it finds in your working tree, focusing on157Use these links when you need to open **Scheduled**.

850behavior changes and missing tests. It uses the current session model unless

851you set `review_model` in `config.toml`.

852 158 

853### List MCP tools with `/mcp`159| Deep link | Opens |

160| --------------------- | ------------------------------------ |

161| `codex://automations` | Scheduled with the create flow open. |

854 162 

8551. Type `/mcp`.163### Plugins

8562. Review the list to confirm which MCP servers and tools are available.

857 164 

858Expected: You see the configured Model Context Protocol (MCP) tools Codex can call in this session.165Plugin links use different forms depending on whether you are installing from a marketplace, opening a plugin, or working from a local `marketplace.json`. For plugin basics, see [Plugins](https://learn.chatgpt.com/docs/plugins). For local or repo marketplace setup, see [Build plugins](https://developers.openai.com/plugins/build/plugins#build-your-own-curated-plugin-list).

859 166 

860Use `/mcp verbose` to include detailed server diagnostics. If you pass anything other than `verbose`, Codex shows the command usage.167#### Plugin install

861 168 

862### Browse apps with `/apps`169Use this form to open the install flow for a plugin from a marketplace that Codex already knows about.

863 170 

8641. Type `/apps`.171| Deep link | Opens |

8652. Pick an app from the list.172| ---------------------------------------------------------------------- | ----------------------------------------------- |

173| `codex://plugins/install/<plugin-name>?marketplace=<marketplace-name>` | The plugin detail or install flow for a plugin. |

866 174 

867Expected: Codex inserts the app mention into the composer as `$app-slug`, so175| Query parameter | Required | What it does |

868you can immediately ask Codex to use it.176| -------------------------------- | -------- | ------------------------------------------------------------------------------- |

177| `marketplace=<marketplace-name>` | Yes | Identifies the marketplace. For an OpenAI-curated plugin, use `openai-curated`. |

869 178 

870### Browse plugins with `/plugins`179The install link accepts only the `marketplace` query parameter. If Codex can't find the requested marketplace or plugin, it opens the Plugins page instead.

871 180 

8721. Type `/plugins`.181#### Plugin detail

8732. Choose a marketplace tab, then pick a plugin to inspect its capabilities or available actions.

874 182 

875Expected: Codex opens the plugin browser so you can review installed plugins,183| Deep link | Opens |

876discoverable plugins that your configuration allows, and installed plugin state.184| ----------------------------- | --------------------- |

877Press <kbd>Space</kbd> on an installed plugin to toggle its enabled state.185| `codex://plugins/<plugin-id>` | A plugin detail page. |

878 186 

879### View and manage lifecycle hooks with `/hooks`187`<plugin-id>` must identify the plugin. For an OpenAI-curated plugin, use the form `<plugin-name>@openai-curated`.

880 188 

8811. Type `/hooks`.189Codex-generated plugin links can also include these query parameters. Omit both when you write a link manually.

8822. Choose a hook event to inspect the matching handlers.

8833. Trust, disable, or re-enable non-managed hooks as needed.

884 190 

885Expected: Codex opens the hook browser so you can review configured lifecycle191| Query parameter | Required | What it does |

886hooks. Managed hooks appear as managed and can't be disabled from the user hook192| ------------------ | -------- | ----------------------------------------------------------------------------------------------------------------------------------------------- |

887browser.193| `hostId=<host-id>` | No | Identifies the Codex host that owns the plugin context, such as `local` or one of your configured remote connections. Codex provides these IDs. |

194| `source=manage` | No | Preserves the app's plugin-management entry point. It's not admin-only. |

888 195 

889### Switch agent threads with `/agent`196Example: [Open the OpenAI Developers plugin](codex://plugins/openai-developers@openai-curated)

890 197 

8911. Type `/agent` or `/subagents` and press Enter.198#### Local plugin

8922. Select the thread you want from the picker.

893 199 

894Expected: Codex switches the active thread so you can inspect or continue that200For local or repo marketplace setup, see [Build plugins](https://developers.openai.com/plugins/build/plugins#build-your-own-curated-plugin-list).

895agent's work.

896 201 

897### Send feedback with `/feedback`202| Deep link | Opens |

203| --------------------------------------------------------------------------- | ---------------------------------------------------- |

204| `codex://plugins/<plugin-name>?marketplacePath=<absolute-marketplace-path>` | A local plugin detail page from a local marketplace. |

898 205 

8991. Type `/feedback` and press Enter.206| Query parameter | Required | What it does |

9002. Follow the prompts to include logs or diagnostics.207| --------------------------------------------- | -------- | ---------------------------------------------------------------------------------------------------------- |

208| `marketplacePath=<absolute-marketplace-path>` | Yes | Absolute path to the local `marketplace.json`, for example `/Users/alex/.agents/plugins/marketplace.json`. |

209| `mode=share` | No | Opens the share flow for that local plugin. |

901 210 

902Expected: Codex collects the requested diagnostics and submits them to the211### Pets

903maintainers.

904 212 

905### Sign out with `/logout`213Use these links to open the pet install flow when that feature is enabled.

906 214 

9071. Type `/logout` and press Enter.215| Deep link | Opens |

216| ----------------------------------------------------------------- | --------------------- |

217| `codex://pets/install?name=<pet-name>&imageUrl=<https-image-url>` | The pet install flow. |

908 218 

909Expected: Codex clears local credentials for the current user session.219| Query parameter | Required | What it does |

220| ------------------------------ | -------- | ------------------------------------------------------------------------------------------- |

221| `name=<pet-name>` | Yes | Sets the pet name. The value must contain at least one non-whitespace character. |

222| `imageUrl=<https-image-url>` | Yes | Provides an absolute HTTPS URL for the pet image or sprite sheet. |

223| `description=<text>` | No | Adds a description to the install flow. |

224| `spriteVersionNumber=<1-or-2>` | No | Selects the sprite-sheet format. The default is `1`; the only other supported value is `2`. |

910 225 

911### Exit the CLI with `/quit` or `/exit`226The install link accepts only these query parameters. Invalid names, non-HTTPS

227image URLs, unsupported sprite versions, or extra path segments cause the link

228to do nothing.

912 229 

9131. Type `/quit` (or `/exit`) and press Enter.230## See also

914 231 

915Expected: Codex exits immediately. Save or commit any important work first.232- [Features](https://learn.chatgpt.com/docs/features)

233- [Settings](https://learn.chatgpt.com/docs/reference/settings)

234- [Slash commands](https://learn.chatgpt.com/docs/reference/slash-commands)

ide/commands.md +231 −57

Details

1# Developer commands1# Commands

2 2 

3> For the complete documentation index, see [llms.txt](https://learn.chatgpt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to the page URL.3> For the complete documentation index, see [llms.txt](https://learn.chatgpt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to the page URL.

4 4 

5Use these commands to control Codex from the VS Code Command Palette. You can also bind them to keyboard shortcuts.5Use these commands and keyboard shortcuts to navigate the app.

6 6 

7## Assign a key binding7## Keyboard shortcuts

8 8 

9To assign or change a key binding for a Codex command:9| | Action | Shortcut |

10 10| ----------- | ------------------- | ---------------------------------------------------------------------------------------------------------------------- |

111. Open the Command Palette (**Cmd+Shift+P** on macOS or **Ctrl+Shift+P** on Windows/Linux).11| **General** | | |

122. Run **Preferences: Open Keyboard Shortcuts**.12| | Command menu | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>P</kbd> or <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>K</kbd> |

133. Search for `Codex` or the command ID (for example, `chatgpt.newChat`).13| | Settings | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>,</kbd> |

144. Select the pencil icon, then enter the shortcut you want.14| | Keyboard shortcuts | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>/</kbd> |

15 15| | Open folder | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>O</kbd> |

16## Extension commands16| | Navigate back | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>[</kbd> |

17 17| | Navigate forward | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>]</kbd> |

18| Command | Default key binding | Description |18| | Increase font size | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>+</kbd> |

19| ------------------------- | ------------------------------------------ | ------------------------------------------------------- |19| | Decrease font size | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>-</kbd> |

20| `chatgpt.addToThread` | - | Add selected text range as context for the current chat |20| | Toggle sidebar | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>B</kbd> |

21| `chatgpt.addFileToThread` | - | Add the entire file as context for the current chat |21| | Open review tab | <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>G</kbd> |

22| `chatgpt.newChat` | macOS: `Cmd+N`<br />Windows/Linux: `Ctrl+N` | Create a new chat |22| | Toggle review panel | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>B</kbd> |

23| `chatgpt.newCodexPanel` | - | Create a new Codex panel |23| | Toggle bottom panel | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>J</kbd> |

24| `chatgpt.openCommandMenu` | - | Open the Codex command menu |24| | Toggle terminal | <kbd>Ctrl</kbd> + <kbd>`</kbd> |

25| `chatgpt.openSidebar` | - | Open the Codex sidebar panel |25| | Clear the terminal | <kbd>Ctrl</kbd> + <kbd>L</kbd> |

26 26| **Chat** | Quick chat | <kbd>Cmd</kbd> + <kbd>Option</kbd> + <kbd>N</kbd> (macOS) or <kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>N</kbd> (Windows) |

27Slash commands let you control Codex without leaving the composer. Use them to check status, switch between local and cloud mode, or send feedback.27| | New chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>N</kbd> or <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>O</kbd> |

28 28| | Search chats | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>G</kbd> |

29## Use a slash command29| | Find in chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>F</kbd> |

30 30| | Previous chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>[</kbd> |

311. In the Codex composer, type `/`.31| | Next chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>]</kbd> |

322. Select a command from the list, or keep typing to filter (for example, `/status`).32| **Input** | Dictation | <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>D</kbd> |

333. Press **Enter**.33 

34 34To find, customize, or reset shortcuts, open **Settings > Keyboard Shortcuts**.

35## Available slash commands35You can search by command name or switch the search field into keystroke mode

36 36and press the shortcut you want to find.

37| Slash command | Description |37 

38| -------------------- | --------------------------------------------------------------------------------------- |38<a id="search-past-tasks-and-find-in-a-task"></a>

39| `/approve` | Approve one retry of a recent automatic-review denial, when automatic review is active. |39 

40| `/cloud` | Run the chat in the cloud, when cloud execution is available. |40## Search past chats and find in a chat

41| `/cloud-environment` | Choose the cloud environment for the chat. |41 

42| `/compact` | Compact the current chat's context. |42Use chat search (<kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>G</kbd>) to reopen a past

43| `/fast` | Turn a catalog-provided Fast service tier on or off, when available. |43chat. When expanded matching is available, it can also match chat content and

44| `/feedback` | Open the feedback dialog to submit feedback and optionally include logs. |44Git branch names, so you can search for a phrase from the chat or a

45| `/fork` | Copy a local chat into a new local chat. |45branch such as `fix/login-redirect`.

46| `/goal` | Set a persistent goal for Codex to work toward. |46 

47| `/ide-context` | Turn automatic IDE context on or off. |47Use **Find in chat** (<kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>F</kbd>) after opening

48| `/init` | Generate an `AGENTS.md` scaffold for the current project. |48a chat to find text within it. It doesn't search across other chats.

49| `/local` | Run the chat in your local workspace. |49 

50| `/mcp` | Open MCP status to view connected servers. |50For actions that start with `/`, see [Slash commands](https://learn.chatgpt.com/docs/reference/slash-commands).

51| `/memories` | Configure whether the chat can use or generate memories, when Memories is available. |51 

52| `/model` | Choose the model for the current chat. |52## Deep links

53| `/personality` | Choose how Codex responds, when the current model supports personalities. |53 

54| `/plan` | Toggle plan mode for multi-step planning. |54The ChatGPT desktop app keeps the `codex://` URL scheme for compatibility, so

55| `/project` | Choose a project for new chats. |55links can open specific parts of the app directly. Encode query string values

56| `/reasoning` | Choose the reasoning effort for the current chat. |56before adding them to a URL.

57| `/review` | Start code review mode to review uncommitted changes or compare against a base branch. |57 

58| `/side` | Start a temporary side chat without interrupting the main chat. |58### Supported links

59| `/status` | Show the chat ID, context usage, and rate limits. |59 

60| `/worktree` | Run the chat in a new Git worktree. |60Use these canonical forms when you create links. The sections below list the full reference by link type.

61 

62| Deep link | Opens |

63| --------------------------------------------------------------------------- | ------------------------------------------------------- |

64| `codex://threads/new` | A new local chat. |

65| `codex://new?<query>` | A new local chat with at least one query parameter. |

66| `codex://threads/<thread-id>` | A local chat. `<thread-id>` is its technical thread ID. |

67| `codex://settings` | Settings. |

68| `codex://settings/connections/<connection-type>` | Computer, device, or SSH connection settings. |

69| `codex://settings/connections/ssh/add?name=<ssh-config-host>` | Adds a host from your SSH config to Codex. |

70| `codex://skills` | Skills. |

71| `codex://automations` | Scheduled with the create flow open. |

72| `codex://plugins/install/<plugin-name>?marketplace=<marketplace-name>` | The install flow for a plugin from a known marketplace. |

73| `codex://plugins/<plugin-id>` | A plugin detail page. |

74| `codex://plugins/<plugin-name>?marketplacePath=<absolute-marketplace-path>` | A local plugin detail page from a local marketplace. |

75| `codex://pets/install?name=<pet-name>&imageUrl=<https-image-url>` | The pet install flow. |

76 

77<a id="tasks"></a>

78 

79### Chats

80 

81Use these links when you need to open an existing local chat or start a new one.

82 

83| Deep link | Opens |

84| ----------------------------- | ------------------------------------------------------------------------------------------------------------ |

85| `codex://threads/<thread-id>` | A local chat. `<thread-id>` is its technical thread ID. |

86| `codex://threads/new` | A new local chat. |

87| `codex://threads/new?<query>` | A new local chat with optional query parameters. |

88| `codex://new?<query>` | A new local chat. Include at least one of `prompt`, `path`, or `originUrl`; otherwise the link does nothing. |

89 

90For `codex://threads/new` or `codex://new`, add any of these query parameters as needed; you can combine them in the same URL.

91 

92| Query parameter | Required | What it does |

93| ---------------------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------- |

94| `prompt=<text>` | No | Sets the initial composer text. |

95| `path=<absolute-path>` | No | Opens the new chat in a local workspace. `path` must be an absolute path to a local directory. When valid, Codex uses that directory as the active workspace. |

96| `originUrl=<git-remote-url>` | No | Matches one of your current workspace roots by Git remote URL. If `path` is also present, Codex resolves `path` first. |

97 

98Example: [Show me some fun stats about how I've been using Codex](codex://threads/new?prompt=Show%20me%20some%20fun%20stats%20about%20how%20I%27ve%20been%20using%20Codex)

99 

100<a id="start-a-task-with-a-plugin"></a>

101 

102#### Start a chat with a plugin

103 

104To help users start a plugin-backed chat, include a plugin mention in the

105prompt before you encode it:

106 

107```text

108[@Example](plugin://example@openai-curated) Summarize this document: https://example.com/document/123

109```

110 

111Encode the complete prompt as a URI component—for example, with

112`encodeURIComponent` in JavaScript—and pass it to the `prompt` parameter:

113 

114```text

115codex://new?prompt=%5B%40Example%5D(plugin%3A%2F%2Fexample%40openai-curated)%20Summarize%20this%20document%3A%20https%3A%2F%2Fexample.com%2Fdocument%2F123

116```

117 

118The link opens a new chat with the decoded prompt in the composer. It doesn't

119send the prompt automatically. After the user sends it, Codex can use an

120installed plugin in that chat. If the plugin isn't installed but is available

121to the user, Codex asks the user to install it and connect any required connectors.

122After setup, the user can select **Continue** to resume the same chat. Workspace

123settings can limit which plugins a user can install. For plugin installation

124and permission details, see [Plugins](https://learn.chatgpt.com/docs/plugins).

125 

126### Settings

127 

128Use these links when you need to open Settings or a specific settings page.

129 

130| Deep link | Opens |

131| ------------------------------------------------------------- | -------------------------------------------------------------------------------------------- |

132| `codex://settings` | Settings. |

133| `codex://settings/browser-use` | Browser settings. |

134| `codex://settings/computer-use/google-chrome` | Google Chrome settings for computer use. |

135| `codex://settings/connections` | Remote connections settings. |

136| `codex://settings/connections/computer` | Settings for controlling this Mac or PC from another device. |

137| `codex://settings/connections/devices` | Settings for controlling other devices. |

138| `codex://settings/connections/ssh` | SSH connection settings. |

139| `codex://settings/connections/ssh/add?name=<ssh-config-host>` | Adds the named host alias as a Codex-managed connection, then opens SSH connection settings. |

140 

141The `name` value must match a host alias in `~/.ssh/config`. The link disables

142automatic connection for the added host. If Codex can't find the named host, it

143opens SSH connection settings and shows an error.

144 

145Unsupported `codex://settings/...` paths open the main Settings page.

146 

147### Skills

148 

149Use these links when you need to open Skills.

150 

151| Deep link | Opens |

152| ---------------- | ------- |

153| `codex://skills` | Skills. |

154 

155### Scheduled

156 

157Use these links when you need to open **Scheduled**.

158 

159| Deep link | Opens |

160| --------------------- | ------------------------------------ |

161| `codex://automations` | Scheduled with the create flow open. |

162 

163### Plugins

164 

165Plugin links use different forms depending on whether you are installing from a marketplace, opening a plugin, or working from a local `marketplace.json`. For plugin basics, see [Plugins](https://learn.chatgpt.com/docs/plugins). For local or repo marketplace setup, see [Build plugins](https://developers.openai.com/plugins/build/plugins#build-your-own-curated-plugin-list).

166 

167#### Plugin install

168 

169Use this form to open the install flow for a plugin from a marketplace that Codex already knows about.

170 

171| Deep link | Opens |

172| ---------------------------------------------------------------------- | ----------------------------------------------- |

173| `codex://plugins/install/<plugin-name>?marketplace=<marketplace-name>` | The plugin detail or install flow for a plugin. |

174 

175| Query parameter | Required | What it does |

176| -------------------------------- | -------- | ------------------------------------------------------------------------------- |

177| `marketplace=<marketplace-name>` | Yes | Identifies the marketplace. For an OpenAI-curated plugin, use `openai-curated`. |

178 

179The install link accepts only the `marketplace` query parameter. If Codex can't find the requested marketplace or plugin, it opens the Plugins page instead.

180 

181#### Plugin detail

182 

183| Deep link | Opens |

184| ----------------------------- | --------------------- |

185| `codex://plugins/<plugin-id>` | A plugin detail page. |

186 

187`<plugin-id>` must identify the plugin. For an OpenAI-curated plugin, use the form `<plugin-name>@openai-curated`.

188 

189Codex-generated plugin links can also include these query parameters. Omit both when you write a link manually.

190 

191| Query parameter | Required | What it does |

192| ------------------ | -------- | ----------------------------------------------------------------------------------------------------------------------------------------------- |

193| `hostId=<host-id>` | No | Identifies the Codex host that owns the plugin context, such as `local` or one of your configured remote connections. Codex provides these IDs. |

194| `source=manage` | No | Preserves the app's plugin-management entry point. It's not admin-only. |

195 

196Example: [Open the OpenAI Developers plugin](codex://plugins/openai-developers@openai-curated)

197 

198#### Local plugin

199 

200For local or repo marketplace setup, see [Build plugins](https://developers.openai.com/plugins/build/plugins#build-your-own-curated-plugin-list).

201 

202| Deep link | Opens |

203| --------------------------------------------------------------------------- | ---------------------------------------------------- |

204| `codex://plugins/<plugin-name>?marketplacePath=<absolute-marketplace-path>` | A local plugin detail page from a local marketplace. |

205 

206| Query parameter | Required | What it does |

207| --------------------------------------------- | -------- | ---------------------------------------------------------------------------------------------------------- |

208| `marketplacePath=<absolute-marketplace-path>` | Yes | Absolute path to the local `marketplace.json`, for example `/Users/alex/.agents/plugins/marketplace.json`. |

209| `mode=share` | No | Opens the share flow for that local plugin. |

210 

211### Pets

212 

213Use these links to open the pet install flow when that feature is enabled.

214 

215| Deep link | Opens |

216| ----------------------------------------------------------------- | --------------------- |

217| `codex://pets/install?name=<pet-name>&imageUrl=<https-image-url>` | The pet install flow. |

218 

219| Query parameter | Required | What it does |

220| ------------------------------ | -------- | ------------------------------------------------------------------------------------------- |

221| `name=<pet-name>` | Yes | Sets the pet name. The value must contain at least one non-whitespace character. |

222| `imageUrl=<https-image-url>` | Yes | Provides an absolute HTTPS URL for the pet image or sprite sheet. |

223| `description=<text>` | No | Adds a description to the install flow. |

224| `spriteVersionNumber=<1-or-2>` | No | Selects the sprite-sheet format. The default is `1`; the only other supported value is `2`. |

225 

226The install link accepts only these query parameters. Invalid names, non-HTTPS

227image URLs, unsupported sprite versions, or extra path segments cause the link

228to do nothing.

229 

230## See also

231 

232- [Features](https://learn.chatgpt.com/docs/features)

233- [Settings](https://learn.chatgpt.com/docs/reference/settings)

234- [Slash commands](https://learn.chatgpt.com/docs/reference/slash-commands)

ide/settings.md +123 −38

Details

1# Developer settings1# Settings

2 2 

3> For the complete documentation index, see [llms.txt](https://learn.chatgpt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to the page URL.3> For the complete documentation index, see [llms.txt](https://learn.chatgpt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to the page URL.

4 4 

5The Codex IDE extension has two settings layers:5Use the settings panel to personalize the app and manage everyday preferences.

6Open [**Settings**](codex://settings) from the app menu or press

6 7 

7- **Codex settings** control agent behavior shared with Codex CLI, including the8<kbd>Cmd</kbd>+<kbd>,</kbd> on macOS or <kbd>Ctrl</kbd>+<kbd>,</kbd> on Windows.

8 model, reasoning effort, permissions, sandbox, MCP servers, and

9 personalization. Codex reads these settings from `config.toml`.

10- **Editor settings** control how the extension behaves inside VS Code and

11 compatible editors. These settings use `chatgpt.*` keys in the editor's

12 settings system.

13 9 

14## Open Codex settings10## General

15 11 

16Select the gear icon in the Codex sidebar, then select **Codex Settings**. Use12Require <kbd>Cmd</kbd>+<kbd>Enter</kbd> for multiline prompts, or turn on

17the settings panel for common agent controls, or select **Open config.toml** to13**Prevent sleep while running** so local chats can continue while you step away.

18edit the active configuration layer directly.14Under **Follow-up behavior**, choose whether a message sent while ChatGPT works

15should steer the current run or wait for the next run.

19 16 

20For the configuration layer order and common keys, see [Config17## Profile

21basics](https://learn.chatgpt.com/docs/config-file/config-basic). For every supported `config.toml` key, see the

22[Configuration reference](https://learn.chatgpt.com/docs/config-file/config-reference).

23 18 

24## Change an editor setting19Use **Profile** to review activity insights, lifetime tokens, peak tokens,

20streaks, your longest task, and token activity. You can also update your profile

21details, such as your picture, display name, and username, and save a profile

22card with usage highlights. Sharing profile cards is available on consumer

23ChatGPT plans.

25 24 

26To change a setting, follow these steps:25Eligible users can also send Codex invitations from the profile menu. Choose

26**Invite a friend** on an eligible personal plan or **Invite a coworker** in an

27eligible Business workspace. See

28[Invite friends and coworkers](https://learn.chatgpt.com/docs/pricing#invite-friends-and-coworkers) for

29current rewards, limits, and eligibility.

27 30 

281. Open your editor settings.31## Keyboard shortcuts

292. Search for `@ext:openai.chatgpt`, `Codex`, or the setting name.

303. Update the value.

31 32 

32The extension also honors VS Code's built-in chat font settings for Codex chat surfaces.33Open **Keyboard Shortcuts** to review commands, change bindings, or reset custom

34shortcuts to their defaults. Use the search field to find shortcuts by command

35name, or switch to keystroke search and press a key combination to find the

36command that uses it.

33 37 

34## Editor settings reference38## Notifications

35 39 

36| Setting | Default | Description |40Choose when turn completion notifications appear, and whether the app should prompt for

37| -------------------------------------------- | -------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |41notification permissions.

38| `chatgpt.commentCodeLensEnabled` | `true` | Show CodeLens above `TODO` comments so Codex can address them. |

39| `chatgpt.openOnStartup` | `false` | Focus the Codex sidebar when the extension finishes starting. |

40| `chatgpt.followUpQueueMode` | `queue` | Choose whether messages sent during a run wait for the next run (`queue`) or steer the current run (`steer`). The extension treats the legacy `interrupt` value as `steer`. Press <kbd>Cmd</kbd>/<kbd>Ctrl</kbd>+<kbd>Shift</kbd>+<kbd>Enter</kbd> to invert the behavior for one message. |

41| `chatgpt.composerEnterBehavior` | `enter` | Choose whether <kbd>Enter</kbd> always sends (`enter`), <kbd>Cmd</kbd>/<kbd>Ctrl</kbd>+<kbd>Enter</kbd> sends multiline prompts (`cmdIfMultiline`), or the modifier is always required (`cmdAlways`). |

42| `chatgpt.reviewDelivery` | `inline` | Run `/review` in the current chat when possible (`inline`) or start a separate review chat (`detached`). |

43| `chatgpt.localeOverride` | Auto | Set the preferred language for the Codex UI. Leave empty to detect it automatically. |

44| `chatgpt.runCodexInWindowsSubsystemForLinux` | `false` | Windows only: Run Codex in WSL when WSL is available. Use this when your repositories and tooling live in WSL2 or when you need Linux-native tooling. Changing this setting reloads VS Code. |

45| `chatgpt.cliExecutable` | Unset | Development only: Set the path to the Codex CLI executable. You don't need this setting unless you're developing the Codex CLI; manually overriding the bundled executable can prevent parts of the extension from working. |

46| `chat.fontSize` | Editor default | Control chat text in the Codex sidebar, including chat content and the composer. |

47| `chat.editor.fontSize` | Editor default | Control code-rendered content in Codex chats, including code snippets and diffs. |

48 42 

49The `chatgpt.*` keys above belong to the IDE extension and don't go in43## Appearance

50`config.toml`. For shared agent settings, use [Config44 

51basics](https://learn.chatgpt.com/docs/config-file/config-basic), [Advanced configuration](https://learn.chatgpt.com/docs/config-file/config-advanced),45In **Settings**, you can change the app appearance by choosing a base theme,

52and the [Configuration reference](https://learn.chatgpt.com/docs/config-file/config-reference).46adjusting accent, background, and foreground colors, and changing the UI and

47code fonts. You can also share your custom theme with friends.

48 

49<CodexScreenshot

50 alt="ChatGPT desktop app Appearance settings showing theme selection, color controls, and font options"

51 lightSrc="/images/codex/app/theme-selection-light.webp"

52 darkSrc="/images/codex/app/theme-selection-dark.webp"

53 maxHeight="720px"

54 class="mb-8"

55/>

56 

57## Pets

58 

59 

60 

61

62 

63 Pets are optional animated companions for the app. In **Settings > Pets**,

64 choose a built-in or custom pet, then use `/pet`, **Wake Pet**, or

65 **Tuck Away Pet** to control the floating overlay.

66 

67 See [Pets](https://learn.chatgpt.com/docs/pets?surface=app) to understand pet status, follow

68 activity across chats, or create your own pet.

69 

70

71 

72 

73 <CodexPetsDemo client:load />

74 

75 

76 

77<a id="browser-use"></a>

78 

79## Browser

80 

81Use these settings to install or enable the bundled Browser plugin, set up the

82[Chrome extension](https://learn.chatgpt.com/docs/chrome-extension), and manage allowed and blocked

83websites. ChatGPT asks before using a website unless you've allowed it. Removing

84a blocked site lets ChatGPT ask again before using it in the browser.

85 

86See [Built-in browser](https://learn.chatgpt.com/docs/browser?surface=app) for browser preview, comment, and

87Computer Use workflows.

88 

89## Computer Use

90 

91Check your Computer Use settings to review desktop-app access and related

92preferences after setup. On macOS, revoke system-level access by updating Screen

93Recording or Accessibility permissions in macOS Privacy & Security settings.

94 

95## Personalization

96 

97Choose **Friendly**, **Pragmatic**, or **None** as your default personality. Use

98**None** to disable personality instructions. You can update this at any time.

99 

100You can also add your own custom instructions. Editing custom instructions updates your

101[personal instructions in `AGENTS.md`](https://learn.chatgpt.com/docs/agent-configuration/agents-md).

102 

103## Suggested prompts

104 

105Use context-aware suggestions to surface follow-ups and tasks you may want to resume when you

106start or return to ChatGPT.

107 

108## Memories

109 

110Enable Memories, where available, to let ChatGPT carry useful context from past

111chats into future work. See [Memories](https://learn.chatgpt.com/docs/customization/memories)

112for setup, storage, and controls for individual chats.

113 

114<a id="archived-tasks"></a>

115 

116## Archived chats

117 

118The **Archived chats** section lists archived chats with dates and project

119context. Use **Unarchive** to restore a chat.

120 

121<a id="keep-an-app-task-near-your-work"></a>

122<a id="keep-an-app-chat-near-your-work"></a>

123<a id="keep-a-task-near-your-work"></a>

124 

125## Keep a chat near your work

126 

127In the ChatGPT desktop app, pop out an active chat into a separate window and place it

128next to your browser, editor, or design preview. Turn on **Always on top** when

129you want the chat to remain visible while you work in another app.

130 

131<CodexScreenshot

132 alt="ChatGPT desktop app chat displayed in a floating pop-out window"

133 lightSrc="/images/codex/app/popover-light.webp"

134 darkSrc="/images/codex/app/popover-dark.webp"

135 maxHeight="400px"

136 class="my-8"

137/>

Details

1# Developer commands1# Commands

2 2 

3> For the complete documentation index, see [llms.txt](https://learn.chatgpt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to the page URL.3> For the complete documentation index, see [llms.txt](https://learn.chatgpt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to the page URL.

4 4 

5Use these commands to control Codex from the VS Code Command Palette. You can also bind them to keyboard shortcuts.5Use these commands and keyboard shortcuts to navigate the app.

6 6 

7## Assign a key binding7## Keyboard shortcuts

8 8 

9To assign or change a key binding for a Codex command:9| | Action | Shortcut |

10 10| ----------- | ------------------- | ---------------------------------------------------------------------------------------------------------------------- |

111. Open the Command Palette (**Cmd+Shift+P** on macOS or **Ctrl+Shift+P** on Windows/Linux).11| **General** | | |

122. Run **Preferences: Open Keyboard Shortcuts**.12| | Command menu | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>P</kbd> or <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>K</kbd> |

133. Search for `Codex` or the command ID (for example, `chatgpt.newChat`).13| | Settings | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>,</kbd> |

144. Select the pencil icon, then enter the shortcut you want.14| | Keyboard shortcuts | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>/</kbd> |

15 15| | Open folder | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>O</kbd> |

16## Extension commands16| | Navigate back | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>[</kbd> |

17 17| | Navigate forward | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>]</kbd> |

18| Command | Default key binding | Description |18| | Increase font size | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>+</kbd> |

19| ------------------------- | ------------------------------------------ | ------------------------------------------------------- |19| | Decrease font size | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>-</kbd> |

20| `chatgpt.addToThread` | - | Add selected text range as context for the current chat |20| | Toggle sidebar | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>B</kbd> |

21| `chatgpt.addFileToThread` | - | Add the entire file as context for the current chat |21| | Open review tab | <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>G</kbd> |

22| `chatgpt.newChat` | macOS: `Cmd+N`<br />Windows/Linux: `Ctrl+N` | Create a new chat |22| | Toggle review panel | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>B</kbd> |

23| `chatgpt.newCodexPanel` | - | Create a new Codex panel |23| | Toggle bottom panel | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>J</kbd> |

24| `chatgpt.openCommandMenu` | - | Open the Codex command menu |24| | Toggle terminal | <kbd>Ctrl</kbd> + <kbd>`</kbd> |

25| `chatgpt.openSidebar` | - | Open the Codex sidebar panel |25| | Clear the terminal | <kbd>Ctrl</kbd> + <kbd>L</kbd> |

26 26| **Chat** | Quick chat | <kbd>Cmd</kbd> + <kbd>Option</kbd> + <kbd>N</kbd> (macOS) or <kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>N</kbd> (Windows) |

27Slash commands let you control Codex without leaving the composer. Use them to check status, switch between local and cloud mode, or send feedback.27| | New chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>N</kbd> or <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>O</kbd> |

28 28| | Search chats | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>G</kbd> |

29## Use a slash command29| | Find in chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>F</kbd> |

30 30| | Previous chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>[</kbd> |

311. In the Codex composer, type `/`.31| | Next chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>]</kbd> |

322. Select a command from the list, or keep typing to filter (for example, `/status`).32| **Input** | Dictation | <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>D</kbd> |

333. Press **Enter**.33 

34 34To find, customize, or reset shortcuts, open **Settings > Keyboard Shortcuts**.

35## Available slash commands35You can search by command name or switch the search field into keystroke mode

36 36and press the shortcut you want to find.

37| Slash command | Description |37 

38| -------------------- | --------------------------------------------------------------------------------------- |38<a id="search-past-tasks-and-find-in-a-task"></a>

39| `/approve` | Approve one retry of a recent automatic-review denial, when automatic review is active. |39 

40| `/cloud` | Run the chat in the cloud, when cloud execution is available. |40## Search past chats and find in a chat

41| `/cloud-environment` | Choose the cloud environment for the chat. |41 

42| `/compact` | Compact the current chat's context. |42Use chat search (<kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>G</kbd>) to reopen a past

43| `/fast` | Turn a catalog-provided Fast service tier on or off, when available. |43chat. When expanded matching is available, it can also match chat content and

44| `/feedback` | Open the feedback dialog to submit feedback and optionally include logs. |44Git branch names, so you can search for a phrase from the chat or a

45| `/fork` | Copy a local chat into a new local chat. |45branch such as `fix/login-redirect`.

46| `/goal` | Set a persistent goal for Codex to work toward. |46 

47| `/ide-context` | Turn automatic IDE context on or off. |47Use **Find in chat** (<kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>F</kbd>) after opening

48| `/init` | Generate an `AGENTS.md` scaffold for the current project. |48a chat to find text within it. It doesn't search across other chats.

49| `/local` | Run the chat in your local workspace. |49 

50| `/mcp` | Open MCP status to view connected servers. |50For actions that start with `/`, see [Slash commands](https://learn.chatgpt.com/docs/reference/slash-commands).

51| `/memories` | Configure whether the chat can use or generate memories, when Memories is available. |51 

52| `/model` | Choose the model for the current chat. |52## Deep links

53| `/personality` | Choose how Codex responds, when the current model supports personalities. |53 

54| `/plan` | Toggle plan mode for multi-step planning. |54The ChatGPT desktop app keeps the `codex://` URL scheme for compatibility, so

55| `/project` | Choose a project for new chats. |55links can open specific parts of the app directly. Encode query string values

56| `/reasoning` | Choose the reasoning effort for the current chat. |56before adding them to a URL.

57| `/review` | Start code review mode to review uncommitted changes or compare against a base branch. |57 

58| `/side` | Start a temporary side chat without interrupting the main chat. |58### Supported links

59| `/status` | Show the chat ID, context usage, and rate limits. |59 

60| `/worktree` | Run the chat in a new Git worktree. |60Use these canonical forms when you create links. The sections below list the full reference by link type.

61 

62| Deep link | Opens |

63| --------------------------------------------------------------------------- | ------------------------------------------------------- |

64| `codex://threads/new` | A new local chat. |

65| `codex://new?<query>` | A new local chat with at least one query parameter. |

66| `codex://threads/<thread-id>` | A local chat. `<thread-id>` is its technical thread ID. |

67| `codex://settings` | Settings. |

68| `codex://settings/connections/<connection-type>` | Computer, device, or SSH connection settings. |

69| `codex://settings/connections/ssh/add?name=<ssh-config-host>` | Adds a host from your SSH config to Codex. |

70| `codex://skills` | Skills. |

71| `codex://automations` | Scheduled with the create flow open. |

72| `codex://plugins/install/<plugin-name>?marketplace=<marketplace-name>` | The install flow for a plugin from a known marketplace. |

73| `codex://plugins/<plugin-id>` | A plugin detail page. |

74| `codex://plugins/<plugin-name>?marketplacePath=<absolute-marketplace-path>` | A local plugin detail page from a local marketplace. |

75| `codex://pets/install?name=<pet-name>&imageUrl=<https-image-url>` | The pet install flow. |

76 

77<a id="tasks"></a>

78 

79### Chats

80 

81Use these links when you need to open an existing local chat or start a new one.

82 

83| Deep link | Opens |

84| ----------------------------- | ------------------------------------------------------------------------------------------------------------ |

85| `codex://threads/<thread-id>` | A local chat. `<thread-id>` is its technical thread ID. |

86| `codex://threads/new` | A new local chat. |

87| `codex://threads/new?<query>` | A new local chat with optional query parameters. |

88| `codex://new?<query>` | A new local chat. Include at least one of `prompt`, `path`, or `originUrl`; otherwise the link does nothing. |

89 

90For `codex://threads/new` or `codex://new`, add any of these query parameters as needed; you can combine them in the same URL.

91 

92| Query parameter | Required | What it does |

93| ---------------------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------- |

94| `prompt=<text>` | No | Sets the initial composer text. |

95| `path=<absolute-path>` | No | Opens the new chat in a local workspace. `path` must be an absolute path to a local directory. When valid, Codex uses that directory as the active workspace. |

96| `originUrl=<git-remote-url>` | No | Matches one of your current workspace roots by Git remote URL. If `path` is also present, Codex resolves `path` first. |

97 

98Example: [Show me some fun stats about how I've been using Codex](codex://threads/new?prompt=Show%20me%20some%20fun%20stats%20about%20how%20I%27ve%20been%20using%20Codex)

99 

100<a id="start-a-task-with-a-plugin"></a>

101 

102#### Start a chat with a plugin

103 

104To help users start a plugin-backed chat, include a plugin mention in the

105prompt before you encode it:

106 

107```text

108[@Example](plugin://example@openai-curated) Summarize this document: https://example.com/document/123

109```

110 

111Encode the complete prompt as a URI component—for example, with

112`encodeURIComponent` in JavaScript—and pass it to the `prompt` parameter:

113 

114```text

115codex://new?prompt=%5B%40Example%5D(plugin%3A%2F%2Fexample%40openai-curated)%20Summarize%20this%20document%3A%20https%3A%2F%2Fexample.com%2Fdocument%2F123

116```

117 

118The link opens a new chat with the decoded prompt in the composer. It doesn't

119send the prompt automatically. After the user sends it, Codex can use an

120installed plugin in that chat. If the plugin isn't installed but is available

121to the user, Codex asks the user to install it and connect any required connectors.

122After setup, the user can select **Continue** to resume the same chat. Workspace

123settings can limit which plugins a user can install. For plugin installation

124and permission details, see [Plugins](https://learn.chatgpt.com/docs/plugins).

125 

126### Settings

127 

128Use these links when you need to open Settings or a specific settings page.

129 

130| Deep link | Opens |

131| ------------------------------------------------------------- | -------------------------------------------------------------------------------------------- |

132| `codex://settings` | Settings. |

133| `codex://settings/browser-use` | Browser settings. |

134| `codex://settings/computer-use/google-chrome` | Google Chrome settings for computer use. |

135| `codex://settings/connections` | Remote connections settings. |

136| `codex://settings/connections/computer` | Settings for controlling this Mac or PC from another device. |

137| `codex://settings/connections/devices` | Settings for controlling other devices. |

138| `codex://settings/connections/ssh` | SSH connection settings. |

139| `codex://settings/connections/ssh/add?name=<ssh-config-host>` | Adds the named host alias as a Codex-managed connection, then opens SSH connection settings. |

140 

141The `name` value must match a host alias in `~/.ssh/config`. The link disables

142automatic connection for the added host. If Codex can't find the named host, it

143opens SSH connection settings and shows an error.

144 

145Unsupported `codex://settings/...` paths open the main Settings page.

146 

147### Skills

148 

149Use these links when you need to open Skills.

150 

151| Deep link | Opens |

152| ---------------- | ------- |

153| `codex://skills` | Skills. |

154 

155### Scheduled

156 

157Use these links when you need to open **Scheduled**.

158 

159| Deep link | Opens |

160| --------------------- | ------------------------------------ |

161| `codex://automations` | Scheduled with the create flow open. |

162 

163### Plugins

164 

165Plugin links use different forms depending on whether you are installing from a marketplace, opening a plugin, or working from a local `marketplace.json`. For plugin basics, see [Plugins](https://learn.chatgpt.com/docs/plugins). For local or repo marketplace setup, see [Build plugins](https://developers.openai.com/plugins/build/plugins#build-your-own-curated-plugin-list).

166 

167#### Plugin install

168 

169Use this form to open the install flow for a plugin from a marketplace that Codex already knows about.

170 

171| Deep link | Opens |

172| ---------------------------------------------------------------------- | ----------------------------------------------- |

173| `codex://plugins/install/<plugin-name>?marketplace=<marketplace-name>` | The plugin detail or install flow for a plugin. |

174 

175| Query parameter | Required | What it does |

176| -------------------------------- | -------- | ------------------------------------------------------------------------------- |

177| `marketplace=<marketplace-name>` | Yes | Identifies the marketplace. For an OpenAI-curated plugin, use `openai-curated`. |

178 

179The install link accepts only the `marketplace` query parameter. If Codex can't find the requested marketplace or plugin, it opens the Plugins page instead.

180 

181#### Plugin detail

182 

183| Deep link | Opens |

184| ----------------------------- | --------------------- |

185| `codex://plugins/<plugin-id>` | A plugin detail page. |

186 

187`<plugin-id>` must identify the plugin. For an OpenAI-curated plugin, use the form `<plugin-name>@openai-curated`.

188 

189Codex-generated plugin links can also include these query parameters. Omit both when you write a link manually.

190 

191| Query parameter | Required | What it does |

192| ------------------ | -------- | ----------------------------------------------------------------------------------------------------------------------------------------------- |

193| `hostId=<host-id>` | No | Identifies the Codex host that owns the plugin context, such as `local` or one of your configured remote connections. Codex provides these IDs. |

194| `source=manage` | No | Preserves the app's plugin-management entry point. It's not admin-only. |

195 

196Example: [Open the OpenAI Developers plugin](codex://plugins/openai-developers@openai-curated)

197 

198#### Local plugin

199 

200For local or repo marketplace setup, see [Build plugins](https://developers.openai.com/plugins/build/plugins#build-your-own-curated-plugin-list).

201 

202| Deep link | Opens |

203| --------------------------------------------------------------------------- | ---------------------------------------------------- |

204| `codex://plugins/<plugin-name>?marketplacePath=<absolute-marketplace-path>` | A local plugin detail page from a local marketplace. |

205 

206| Query parameter | Required | What it does |

207| --------------------------------------------- | -------- | ---------------------------------------------------------------------------------------------------------- |

208| `marketplacePath=<absolute-marketplace-path>` | Yes | Absolute path to the local `marketplace.json`, for example `/Users/alex/.agents/plugins/marketplace.json`. |

209| `mode=share` | No | Opens the share flow for that local plugin. |

210 

211### Pets

212 

213Use these links to open the pet install flow when that feature is enabled.

214 

215| Deep link | Opens |

216| ----------------------------------------------------------------- | --------------------- |

217| `codex://pets/install?name=<pet-name>&imageUrl=<https-image-url>` | The pet install flow. |

218 

219| Query parameter | Required | What it does |

220| ------------------------------ | -------- | ------------------------------------------------------------------------------------------- |

221| `name=<pet-name>` | Yes | Sets the pet name. The value must contain at least one non-whitespace character. |

222| `imageUrl=<https-image-url>` | Yes | Provides an absolute HTTPS URL for the pet image or sprite sheet. |

223| `description=<text>` | No | Adds a description to the install flow. |

224| `spriteVersionNumber=<1-or-2>` | No | Selects the sprite-sheet format. The default is `1`; the only other supported value is `2`. |

225 

226The install link accepts only these query parameters. Invalid names, non-HTTPS

227image URLs, unsupported sprite versions, or extra path segments cause the link

228to do nothing.

229 

230## See also

231 

232- [Features](https://learn.chatgpt.com/docs/features)

233- [Settings](https://learn.chatgpt.com/docs/reference/settings)

234- [Slash commands](https://learn.chatgpt.com/docs/reference/slash-commands)

open-source.md +8 −4

Details

9## Open-source components9## Open-source components

10 10 

11| Component | Where to find | Notes |11| Component | Where to find | Notes |

12| --------------------------- | ------------------------------------------------------------------------------------------------- | -------------------------------------------------- |12| ----------------------------- | --------------------------------------------------------------------------------------------------------- | ------------------------------------------------------- |

13| Codex CLI | [openai/codex](https://github.com/openai/codex) | The primary home for Codex open-source development |13| Codex CLI | [openai/codex](https://github.com/openai/codex) | The primary home for Codex open-source development |

14| Codex SDK | [openai/codex/codex-sdk](https://github.com/openai/codex/tree/main/sdk) | SDK sources live in the Codex repo |14| Codex SDK | [openai/codex/codex-sdk](https://github.com/openai/codex/tree/main/sdk) | SDK sources live in the Codex repo |

15| Codex Security CLI | [openai/codex-security](https://github.com/openai/codex-security) | CLI for finding and validating security vulnerabilities |

16| Codex Security TypeScript SDK | [openai/codex-security/sdk/typescript](https://github.com/openai/codex-security/tree/main/sdk/typescript) | TypeScript SDK for running Codex Security scans |

15| Codex App Server | [openai/codex/codex-rs/app-server](https://github.com/openai/codex/tree/main/codex-rs/app-server) | App-server sources live in the Codex repo |17| Codex App Server | [openai/codex/codex-rs/app-server](https://github.com/openai/codex/tree/main/codex-rs/app-server) | App-server sources live in the Codex repo |

16| Skills | [openai/skills](https://github.com/openai/skills) | Reusable skills that extend ChatGPT and Codex |18| Skills | [openai/skills](https://github.com/openai/skills) | Reusable skills that extend ChatGPT and Codex |

19| Plugins | [openai/plugins](https://github.com/openai/plugins) | Reusable plugins for ChatGPT and Codex |

17| IDE extension | - | Not open source |20| IDE extension | - | Not open source |

18| Codex cloud | - | Not open source |21| Codex cloud | - | Not open source |

19| Universal cloud environment | [openai/codex-universal](https://github.com/openai/codex-universal) | Base environment used by Codex cloud |22| Universal cloud environment | [openai/codex-universal](https://github.com/openai/codex-universal) | Base environment used by Codex cloud |

20 23 

21## Where to report issues and request features24## Where to report issues and request features

22 25 

23Use the Codex GitHub repository for bug reports and feature requests across Codex components:26Use the appropriate GitHub repository for bug reports and feature requests:

24 27 

25- Bug reports and feature requests: [openai/codex/issues](https://github.com/openai/codex/issues)28- Codex bug reports and feature requests: [openai/codex/issues](https://github.com/openai/codex/issues)

29- Codex Security CLI and TypeScript SDK bug reports and feature requests: [openai/codex-security/issues](https://github.com/openai/codex-security/issues)

26- Discussion forum: [openai/codex/discussions](https://github.com/openai/codex/discussions)30- Discussion forum: [openai/codex/discussions](https://github.com/openai/codex/discussions)

27 31 

28When you file an issue, include which component you are using (CLI, SDK, IDE extension, Codex cloud) and the version where possible.32When you file an issue, include which component you are using (CLI, SDK, IDE extension, Codex cloud, or Codex Security) and the version where possible.

Details

48Use the permissions control below the composer in the ChatGPT desktop app or48Use the permissions control below the composer in the ChatGPT desktop app or

49IDE extension.49IDE extension.

50 50 

51<Illustration description="Approval-mode menu with Approve for me selected.">

52 <PermissionModeComposerIllustration ariaLabel="Approval-mode menu with Approve for me selected." />

53</Illustration>

54 

55In the CLI, enter `/permissions`. For technical details, see51In the CLI, enter `/permissions`. For technical details, see

56[Sandbox](https://learn.chatgpt.com/docs/sandboxing), [automatic review](https://learn.chatgpt.com/docs/sandboxing/auto-review), or52[Sandbox](https://learn.chatgpt.com/docs/sandboxing), [automatic review](https://learn.chatgpt.com/docs/sandboxing/auto-review), or

57[permission profiles](https://learn.chatgpt.com/docs/permissions).53[permission profiles](https://learn.chatgpt.com/docs/permissions).

reference/commands.md +234 −0 created

Details

1# Commands

2 

3> For the complete documentation index, see [llms.txt](https://learn.chatgpt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to the page URL.

4 

5Use these commands and keyboard shortcuts to navigate the app.

6 

7## Keyboard shortcuts

8 

9| | Action | Shortcut |

10| ----------- | ------------------- | ---------------------------------------------------------------------------------------------------------------------- |

11| **General** | | |

12| | Command menu | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>P</kbd> or <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>K</kbd> |

13| | Settings | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>,</kbd> |

14| | Keyboard shortcuts | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>/</kbd> |

15| | Open folder | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>O</kbd> |

16| | Navigate back | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>[</kbd> |

17| | Navigate forward | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>]</kbd> |

18| | Increase font size | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>+</kbd> |

19| | Decrease font size | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>-</kbd> |

20| | Toggle sidebar | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>B</kbd> |

21| | Open review tab | <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>G</kbd> |

22| | Toggle review panel | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>B</kbd> |

23| | Toggle bottom panel | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>J</kbd> |

24| | Toggle terminal | <kbd>Ctrl</kbd> + <kbd>`</kbd> |

25| | Clear the terminal | <kbd>Ctrl</kbd> + <kbd>L</kbd> |

26| **Chat** | Quick chat | <kbd>Cmd</kbd> + <kbd>Option</kbd> + <kbd>N</kbd> (macOS) or <kbd>Ctrl</kbd> + <kbd>Alt</kbd> + <kbd>N</kbd> (Windows) |

27| | New chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>N</kbd> or <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>O</kbd> |

28| | Search chats | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>G</kbd> |

29| | Find in chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>F</kbd> |

30| | Previous chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>[</kbd> |

31| | Next chat | <kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>]</kbd> |

32| **Input** | Dictation | <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>D</kbd> |

33 

34To find, customize, or reset shortcuts, open **Settings > Keyboard Shortcuts**.

35You can search by command name or switch the search field into keystroke mode

36and press the shortcut you want to find.

37 

38<a id="search-past-tasks-and-find-in-a-task"></a>

39 

40## Search past chats and find in a chat

41 

42Use chat search (<kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>G</kbd>) to reopen a past

43chat. When expanded matching is available, it can also match chat content and

44Git branch names, so you can search for a phrase from the chat or a

45branch such as `fix/login-redirect`.

46 

47Use **Find in chat** (<kbd>Cmd</kbd>/<kbd>Ctrl</kbd> + <kbd>F</kbd>) after opening

48a chat to find text within it. It doesn't search across other chats.

49 

50For actions that start with `/`, see [Slash commands](https://learn.chatgpt.com/docs/reference/slash-commands).

51 

52## Deep links

53 

54The ChatGPT desktop app keeps the `codex://` URL scheme for compatibility, so

55links can open specific parts of the app directly. Encode query string values

56before adding them to a URL.

57 

58### Supported links

59 

60Use these canonical forms when you create links. The sections below list the full reference by link type.

61 

62| Deep link | Opens |

63| --------------------------------------------------------------------------- | ------------------------------------------------------- |

64| `codex://threads/new` | A new local chat. |

65| `codex://new?<query>` | A new local chat with at least one query parameter. |

66| `codex://threads/<thread-id>` | A local chat. `<thread-id>` is its technical thread ID. |

67| `codex://settings` | Settings. |

68| `codex://settings/connections/<connection-type>` | Computer, device, or SSH connection settings. |

69| `codex://settings/connections/ssh/add?name=<ssh-config-host>` | Adds a host from your SSH config to Codex. |

70| `codex://skills` | Skills. |

71| `codex://automations` | Scheduled with the create flow open. |

72| `codex://plugins/install/<plugin-name>?marketplace=<marketplace-name>` | The install flow for a plugin from a known marketplace. |

73| `codex://plugins/<plugin-id>` | A plugin detail page. |

74| `codex://plugins/<plugin-name>?marketplacePath=<absolute-marketplace-path>` | A local plugin detail page from a local marketplace. |

75| `codex://pets/install?name=<pet-name>&imageUrl=<https-image-url>` | The pet install flow. |

76 

77<a id="tasks"></a>

78 

79### Chats

80 

81Use these links when you need to open an existing local chat or start a new one.

82 

83| Deep link | Opens |

84| ----------------------------- | ------------------------------------------------------------------------------------------------------------ |

85| `codex://threads/<thread-id>` | A local chat. `<thread-id>` is its technical thread ID. |

86| `codex://threads/new` | A new local chat. |

87| `codex://threads/new?<query>` | A new local chat with optional query parameters. |

88| `codex://new?<query>` | A new local chat. Include at least one of `prompt`, `path`, or `originUrl`; otherwise the link does nothing. |

89 

90For `codex://threads/new` or `codex://new`, add any of these query parameters as needed; you can combine them in the same URL.

91 

92| Query parameter | Required | What it does |

93| ---------------------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------- |

94| `prompt=<text>` | No | Sets the initial composer text. |

95| `path=<absolute-path>` | No | Opens the new chat in a local workspace. `path` must be an absolute path to a local directory. When valid, Codex uses that directory as the active workspace. |

96| `originUrl=<git-remote-url>` | No | Matches one of your current workspace roots by Git remote URL. If `path` is also present, Codex resolves `path` first. |

97 

98Example: [Show me some fun stats about how I've been using Codex](codex://threads/new?prompt=Show%20me%20some%20fun%20stats%20about%20how%20I%27ve%20been%20using%20Codex)

99 

100<a id="start-a-task-with-a-plugin"></a>

101 

102#### Start a chat with a plugin

103 

104To help users start a plugin-backed chat, include a plugin mention in the

105prompt before you encode it:

106 

107```text

108[@Example](plugin://example@openai-curated) Summarize this document: https://example.com/document/123

109```

110 

111Encode the complete prompt as a URI component—for example, with

112`encodeURIComponent` in JavaScript—and pass it to the `prompt` parameter:

113 

114```text

115codex://new?prompt=%5B%40Example%5D(plugin%3A%2F%2Fexample%40openai-curated)%20Summarize%20this%20document%3A%20https%3A%2F%2Fexample.com%2Fdocument%2F123

116```

117 

118The link opens a new chat with the decoded prompt in the composer. It doesn't

119send the prompt automatically. After the user sends it, Codex can use an

120installed plugin in that chat. If the plugin isn't installed but is available

121to the user, Codex asks the user to install it and connect any required connectors.

122After setup, the user can select **Continue** to resume the same chat. Workspace

123settings can limit which plugins a user can install. For plugin installation

124and permission details, see [Plugins](https://learn.chatgpt.com/docs/plugins).

125 

126### Settings

127 

128Use these links when you need to open Settings or a specific settings page.

129 

130| Deep link | Opens |

131| ------------------------------------------------------------- | -------------------------------------------------------------------------------------------- |

132| `codex://settings` | Settings. |

133| `codex://settings/browser-use` | Browser settings. |

134| `codex://settings/computer-use/google-chrome` | Google Chrome settings for computer use. |

135| `codex://settings/connections` | Remote connections settings. |

136| `codex://settings/connections/computer` | Settings for controlling this Mac or PC from another device. |

137| `codex://settings/connections/devices` | Settings for controlling other devices. |

138| `codex://settings/connections/ssh` | SSH connection settings. |

139| `codex://settings/connections/ssh/add?name=<ssh-config-host>` | Adds the named host alias as a Codex-managed connection, then opens SSH connection settings. |

140 

141The `name` value must match a host alias in `~/.ssh/config`. The link disables

142automatic connection for the added host. If Codex can't find the named host, it

143opens SSH connection settings and shows an error.

144 

145Unsupported `codex://settings/...` paths open the main Settings page.

146 

147### Skills

148 

149Use these links when you need to open Skills.

150 

151| Deep link | Opens |

152| ---------------- | ------- |

153| `codex://skills` | Skills. |

154 

155### Scheduled

156 

157Use these links when you need to open **Scheduled**.

158 

159| Deep link | Opens |

160| --------------------- | ------------------------------------ |

161| `codex://automations` | Scheduled with the create flow open. |

162 

163### Plugins

164 

165Plugin links use different forms depending on whether you are installing from a marketplace, opening a plugin, or working from a local `marketplace.json`. For plugin basics, see [Plugins](https://learn.chatgpt.com/docs/plugins). For local or repo marketplace setup, see [Build plugins](https://developers.openai.com/plugins/build/plugins#build-your-own-curated-plugin-list).

166 

167#### Plugin install

168 

169Use this form to open the install flow for a plugin from a marketplace that Codex already knows about.

170 

171| Deep link | Opens |

172| ---------------------------------------------------------------------- | ----------------------------------------------- |

173| `codex://plugins/install/<plugin-name>?marketplace=<marketplace-name>` | The plugin detail or install flow for a plugin. |

174 

175| Query parameter | Required | What it does |

176| -------------------------------- | -------- | ------------------------------------------------------------------------------- |

177| `marketplace=<marketplace-name>` | Yes | Identifies the marketplace. For an OpenAI-curated plugin, use `openai-curated`. |

178 

179The install link accepts only the `marketplace` query parameter. If Codex can't find the requested marketplace or plugin, it opens the Plugins page instead.

180 

181#### Plugin detail

182 

183| Deep link | Opens |

184| ----------------------------- | --------------------- |

185| `codex://plugins/<plugin-id>` | A plugin detail page. |

186 

187`<plugin-id>` must identify the plugin. For an OpenAI-curated plugin, use the form `<plugin-name>@openai-curated`.

188 

189Codex-generated plugin links can also include these query parameters. Omit both when you write a link manually.

190 

191| Query parameter | Required | What it does |

192| ------------------ | -------- | ----------------------------------------------------------------------------------------------------------------------------------------------- |

193| `hostId=<host-id>` | No | Identifies the Codex host that owns the plugin context, such as `local` or one of your configured remote connections. Codex provides these IDs. |

194| `source=manage` | No | Preserves the app's plugin-management entry point. It's not admin-only. |

195 

196Example: [Open the OpenAI Developers plugin](codex://plugins/openai-developers@openai-curated)

197 

198#### Local plugin

199 

200For local or repo marketplace setup, see [Build plugins](https://developers.openai.com/plugins/build/plugins#build-your-own-curated-plugin-list).

201 

202| Deep link | Opens |

203| --------------------------------------------------------------------------- | ---------------------------------------------------- |

204| `codex://plugins/<plugin-name>?marketplacePath=<absolute-marketplace-path>` | A local plugin detail page from a local marketplace. |

205 

206| Query parameter | Required | What it does |

207| --------------------------------------------- | -------- | ---------------------------------------------------------------------------------------------------------- |

208| `marketplacePath=<absolute-marketplace-path>` | Yes | Absolute path to the local `marketplace.json`, for example `/Users/alex/.agents/plugins/marketplace.json`. |

209| `mode=share` | No | Opens the share flow for that local plugin. |

210 

211### Pets

212 

213Use these links to open the pet install flow when that feature is enabled.

214 

215| Deep link | Opens |

216| ----------------------------------------------------------------- | --------------------- |

217| `codex://pets/install?name=<pet-name>&imageUrl=<https-image-url>` | The pet install flow. |

218 

219| Query parameter | Required | What it does |

220| ------------------------------ | -------- | ------------------------------------------------------------------------------------------- |

221| `name=<pet-name>` | Yes | Sets the pet name. The value must contain at least one non-whitespace character. |

222| `imageUrl=<https-image-url>` | Yes | Provides an absolute HTTPS URL for the pet image or sprite sheet. |

223| `description=<text>` | No | Adds a description to the install flow. |

224| `spriteVersionNumber=<1-or-2>` | No | Selects the sprite-sheet format. The default is `1`; the only other supported value is `2`. |

225 

226The install link accepts only these query parameters. Invalid names, non-HTTPS

227image URLs, unsupported sprite versions, or extra path segments cause the link

228to do nothing.

229 

230## See also

231 

232- [Features](https://learn.chatgpt.com/docs/features)

233- [Settings](https://learn.chatgpt.com/docs/reference/settings)

234- [Slash commands](https://learn.chatgpt.com/docs/reference/slash-commands)

reference/settings.md +137 −0 created

Details

1# Settings

2 

3> For the complete documentation index, see [llms.txt](https://learn.chatgpt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to the page URL.

4 

5Use the settings panel to personalize the app and manage everyday preferences.

6Open [**Settings**](codex://settings) from the app menu or press

7 

8<kbd>Cmd</kbd>+<kbd>,</kbd> on macOS or <kbd>Ctrl</kbd>+<kbd>,</kbd> on Windows.

9 

10## General

11 

12Require <kbd>Cmd</kbd>+<kbd>Enter</kbd> for multiline prompts, or turn on

13**Prevent sleep while running** so local chats can continue while you step away.

14Under **Follow-up behavior**, choose whether a message sent while ChatGPT works

15should steer the current run or wait for the next run.

16 

17## Profile

18 

19Use **Profile** to review activity insights, lifetime tokens, peak tokens,

20streaks, your longest task, and token activity. You can also update your profile

21details, such as your picture, display name, and username, and save a profile

22card with usage highlights. Sharing profile cards is available on consumer

23ChatGPT plans.

24 

25Eligible users can also send Codex invitations from the profile menu. Choose

26**Invite a friend** on an eligible personal plan or **Invite a coworker** in an

27eligible Business workspace. See

28[Invite friends and coworkers](https://learn.chatgpt.com/docs/pricing#invite-friends-and-coworkers) for

29current rewards, limits, and eligibility.

30 

31## Keyboard shortcuts

32 

33Open **Keyboard Shortcuts** to review commands, change bindings, or reset custom

34shortcuts to their defaults. Use the search field to find shortcuts by command

35name, or switch to keystroke search and press a key combination to find the

36command that uses it.

37 

38## Notifications

39 

40Choose when turn completion notifications appear, and whether the app should prompt for

41notification permissions.

42 

43## Appearance

44 

45In **Settings**, you can change the app appearance by choosing a base theme,

46adjusting accent, background, and foreground colors, and changing the UI and

47code fonts. You can also share your custom theme with friends.

48 

49<CodexScreenshot

50 alt="ChatGPT desktop app Appearance settings showing theme selection, color controls, and font options"

51 lightSrc="/images/codex/app/theme-selection-light.webp"

52 darkSrc="/images/codex/app/theme-selection-dark.webp"

53 maxHeight="720px"

54 class="mb-8"

55/>

56 

57## Pets

58 

59 

60 

61

62 

63 Pets are optional animated companions for the app. In **Settings > Pets**,

64 choose a built-in or custom pet, then use `/pet`, **Wake Pet**, or

65 **Tuck Away Pet** to control the floating overlay.

66 

67 See [Pets](https://learn.chatgpt.com/docs/pets?surface=app) to understand pet status, follow

68 activity across chats, or create your own pet.

69 

70

71 

72 

73 <CodexPetsDemo client:load />

74 

75 

76 

77<a id="browser-use"></a>

78 

79## Browser

80 

81Use these settings to install or enable the bundled Browser plugin, set up the

82[Chrome extension](https://learn.chatgpt.com/docs/chrome-extension), and manage allowed and blocked

83websites. ChatGPT asks before using a website unless you've allowed it. Removing

84a blocked site lets ChatGPT ask again before using it in the browser.

85 

86See [Built-in browser](https://learn.chatgpt.com/docs/browser?surface=app) for browser preview, comment, and

87Computer Use workflows.

88 

89## Computer Use

90 

91Check your Computer Use settings to review desktop-app access and related

92preferences after setup. On macOS, revoke system-level access by updating Screen

93Recording or Accessibility permissions in macOS Privacy & Security settings.

94 

95## Personalization

96 

97Choose **Friendly**, **Pragmatic**, or **None** as your default personality. Use

98**None** to disable personality instructions. You can update this at any time.

99 

100You can also add your own custom instructions. Editing custom instructions updates your

101[personal instructions in `AGENTS.md`](https://learn.chatgpt.com/docs/agent-configuration/agents-md).

102 

103## Suggested prompts

104 

105Use context-aware suggestions to surface follow-ups and tasks you may want to resume when you

106start or return to ChatGPT.

107 

108## Memories

109 

110Enable Memories, where available, to let ChatGPT carry useful context from past

111chats into future work. See [Memories](https://learn.chatgpt.com/docs/customization/memories)

112for setup, storage, and controls for individual chats.

113 

114<a id="archived-tasks"></a>

115 

116## Archived chats

117 

118The **Archived chats** section lists archived chats with dates and project

119context. Use **Unarchive** to restore a chat.

120 

121<a id="keep-an-app-task-near-your-work"></a>

122<a id="keep-an-app-chat-near-your-work"></a>

123<a id="keep-a-task-near-your-work"></a>

124 

125## Keep a chat near your work

126 

127In the ChatGPT desktop app, pop out an active chat into a separate window and place it

128next to your browser, editor, or design preview. Turn on **Always on top** when

129you want the chat to remain visible while you work in another app.

130 

131<CodexScreenshot

132 alt="ChatGPT desktop app chat displayed in a floating pop-out window"

133 lightSrc="/images/codex/app/popover-light.webp"

134 darkSrc="/images/codex/app/popover-dark.webp"

135 maxHeight="400px"

136 class="my-8"

137/>

use-chatgpt.md +23 −1

Details

48### What ChatGPT Work can do48### What ChatGPT Work can do

49 49 

50ChatGPT Work can plan a task, gather context, use tools, and carry the work50ChatGPT Work can plan a task, gather context, use tools, and carry the work

51through to a result you can review. Ask it to:51through to a result you can review.

52 

53<Illustration description="ChatGPT Work comparing vendors and producing a spreadsheet you can review.">

54 <CodexScreenshot

55 alt="ChatGPT Work comparing vendors in a spreadsheet"

56 lightSrc="/codex/get-started-with-work/comparison-spreadsheet.webp"

57 darkSrc="/codex/get-started-with-work/comparison-spreadsheet.webp"

58 maxHeight={520}

59 class="my-6 p-4 md:p-8"

60 />

61</Illustration>

62 

63Ask it to:

52 64 

53- **Research and analyze information.** Search the web, browse websites,65- **Research and analyze information.** Search the web, browse websites,

54 compare sources, read files, analyze data, and summarize findings.66 compare sources, read files, analyze data, and summarize findings.


196on information outside the chat, actions in another system, or a208on information outside the chat, actions in another system, or a

197repeatable workflow.209repeatable workflow.

198 210 

211<Illustration description="ChatGPT plugin directory showing connected tools such as Google Drive, Slack, and SharePoint.">

212 <CodexScreenshot

213 alt="ChatGPT plugin directory showing connected work tools"

214 lightSrc="/codex/get-started-with-work/plugins.webp"

215 darkSrc="/codex/get-started-with-work/plugins.webp"

216 maxHeight={520}

217 class="my-6 p-4 md:p-8"

218 />

219</Illustration>

220 

199Plugin availability depends on your plan, workspace settings, and the plugin221Plugin availability depends on your plan, workspace settings, and the plugin

200itself. Learn more about [skills and plugins](https://learn.chatgpt.com/docs/skills-and-plugins).222itself. Learn more about [skills and plugins](https://learn.chatgpt.com/docs/skills-and-plugins).

201 223