Answer: You can override configuration for a single run from the CLI by preferring dedicated flags when they exist (for example, `--model`), or by using `-c` / `--config` when you need to override an arbitrary key. Status: Confirmed Entry: tool/codex/commands-and-shortcuts/cli-one-off-overrides Revision: 2 Digest: sha256:859af25fb859d1da (changes whenever the content changes) Timeline: Created: 2026-11-13T03:48:17Z Last changed: 2026-11-14T13:33:14Z (arbitrary key override (long form): — → --config) Last verified: 2026-11-20T13:35:57Z Next check: 2026-11-21T13:35:57Z Check interval: Daily Expected change: No fixed schedule Data: Field | Value | Source | As of dedicated flags | --model | [1] | 2026-11-20 arbitrary key override | -c | [1] | 2026-11-20 arbitrary key override (long form) | --config | [1] | 2026-11-20 config file path | ~/.codex/config.toml | [1] | 2026-11-20 Sources: [1] OpenAI. "Advanced Configuration". https://learn.chatgpt.com/docs/config-file/config-advanced.md Role: primary. Accessed: 2026-11-20T13:35:57Z Quote: "Prefer dedicated flags when they exist (for example, `--model`)." (Supports: dedicated flags) Quote: "Use `-c` / `--config` when you need to override an arbitrary key." (Supports: arbitrary key override, arbitrary key override (long form)) Quote: "You can edit `~/.codex/config.toml` or override configuration for a single run from the CLI:" (Supports: config file path) Snapshot SHA-256: 509cb889c8d02037082a87c240864f0e2618d38ab224c28b562712b2744fbd65 (captured 2026-11-17T13:59:29Z) Verification: Method: Automated extraction from [1] with deepseek-flash (JSON output, thinking disabled). Every value was checked by code to appear verbatim in a quoted passage of [1]. On this check the text of [1] was unchanged since 2026-11-17T13:59:31Z, so the values verified then were kept. Cross-check: not-available at 2026-11-20T13:35:57Z. No independent second source is configured for this entry Last successful check: 2026-11-20T13:35:57Z Last attempt: 2026-11-20T13:35:57Z Notes and limitations: Extracted automatically from a single official source (section "One-off overrides from the CLI"). Related: https://latestn.com/tool/codex/commands-and-shortcuts/codex-cli-image-flag How do I pass one or more image files to Codex from the command line? https://latestn.com/tool/codex/commands-and-shortcuts/codex-ide-extension-commands What commands and default key bindings does the Codex IDE extension provide? https://latestn.com/tool/codex/commands-and-shortcuts/configure-deep-scan How do I configure a deep scan with the Codex Security CLI? https://latestn.com/tool/codex/commands-and-shortcuts/add-mcp-server-cli How do I add an MCP server to Codex with the CLI? https://latestn.com/tool/codex/commands-and-shortcuts/assign-key-binding-codex-ide How do I assign or change a keyboard shortcut for a Codex command in the VS Code IDE extension? https://latestn.com/tool/codex/commands-and-shortcuts/available-slash-commands-codex-ide Which slash commands are available in the Codex IDE extension? https://latestn.com/tool/ All entries in AI tools Change log: Time | Event | Change | Source 2026-11-14T13:33:14Z | changed | arbitrary key override (long form): — → --config | [1] 2026-11-14T13:33:14Z | changed | arbitrary key override: — → -c | [1] 2026-11-14T13:33:14Z | changed | arbitrary key override flag (long): --config → — | [1] 2026-11-14T13:33:14Z | changed | arbitrary key override flag: -c → — | [1] 2026-11-13T03:48:17Z | added | Entry created | — Changes for this entry as a feed: https://latestn.com/tool/codex/commands-and-shortcuts/cli-one-off-overrides/latest Challenge this entry: Open challenges: None How: If a value here is wrong or out of date, send what is wrong and a link to evidence. Challenges are queued and checked against the evidence; they do not change the entry by themselves. If the entry changes as a result, the change log says so. Form: https://latestn.com/dispute/tool/codex/commands-and-shortcuts/cli-one-off-overrides POST: https://latestn.com/dispute/tool/codex/commands-and-shortcuts/cli-one-off-overrides with claim, evidence_url, and optionally field and contact (form-encoded or JSON) GET: https://latestn.com/dispute/tool/codex/commands-and-shortcuts/cli-one-off-overrides?claim={what is wrong}&evidence_url={link} How to cite: LatestN. (2026). How do I override Codex configuration options for a single run from the CLI? Revision 2, last verified 2026-11-20T13:35:57Z. https://latestn.com/tool/codex/commands-and-shortcuts/cli-one-off-overrides (accessed 2026-11-21T10:04:13Z). @misc{LatestN_tool_codex_commands_and_shortcuts_cli_one_off_overrides_r2, title = {How do I override Codex configuration options for a single run from the CLI?}, author = {{LatestN}}, year = {2026}, howpublished = {\url{https://latestn.com/tool/codex/commands-and-shortcuts/cli-one-off-overrides}}, note = {Revision 2; digest sha256:859af25fb859d1da; last verified 2026-11-20T13:35:57Z; accessed 2026-11-21T10:04:13Z} } Reuse: License: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/) Attribution: Copying and adapting are allowed, including commercially, if you credit LatestN and link to the entry you used. Each entry ends with a ready-made citation. URL: https://latestn.com/tool/codex/commands-and-shortcuts/cli-one-off-overrides