General
Set to
1 to treat the current workspace as trusted for this process, without recording it. Project config, hooks, MCP servers, plugins and skills then load as if you had run o4 trust. Any other value is ignored. Meant for automation that has already vetted the repository.A model reference, such as
anthropic:claude-opus-5, that every sub-agent uses. It takes priority over the model you picked for an agent in /sub-agents (subagent_models in settings.json) and over the model the agent tool call or the sub-agent definition asks for. inherit uses the parent session’s model, and so does a reference o4 can’t resolve. When unset, a sub-agent uses the model you picked for it, then the model the tool call asks for, then the one its definition names, then the parent’s model.Has no effect in o4 0.4.23. o4 reads it, and
ACCESSIBILITY_ENABLED, but the saved Screen reader setting replaces the result when the interface starts. To turn on screen reader output, use the --accessibility flag or the Screen reader setting in /config appearance. See Themes and display.Set to
0 to turn off Rena, the small o4 character beside the status line that says what the agent is doing. The start screen then shows the o4 logo instead. Any other value leaves her on.Set to
1 to stop Rena’s motion; her status text stays. O4_NO_ANIMATION=1 does the same. To turn off all animations, use reduce_motion in settings.json or Reduce motion in /config.When set, to any value, Rena becomes a plain-text status, such as
o4: Editing files, without color or motion. The rest of the interface keeps its theme colors.When set, to any value, Rena becomes a plain-text status without color or motion, the same as with
NO_COLOR.Set to
alternate to run the TUI in the terminal’s alternate screen, the way full-screen programs do. By default, o4 draws below your shell prompt and leaves the conversation in your terminal’s scrollback.When o4 can’t copy with a system clipboard command, it falls back to sending the text to your terminal with an OSC 52 escape sequence. Set this to
0, false, no or off to turn that fallback off. On by default.The editor o4 opens when you edit your prompt in an external editor (
Ctrl+G), create or edit an agent definition or a skill, or edit an MCP config file. If it’s unset, o4 uses VISUAL, then vi. o4 runs the value as a single program name or path, without a shell, so it can’t include arguments: with EDITOR="code --wait", Ctrl+G fails with “Failed to launch editor”. Point it at a wrapper script if your editor needs flags.Set by some terminals to their text and background color numbers, such as
15;0. With the auto theme, when the terminal doesn’t report its colors, o4 reads the background number: 8 or more means a light background. See Themes and display.In the VS Code terminal, with the
auto theme, a value that contains light makes o4 use light colors when the terminal doesn’t report its own. See Themes and display.Has no effect in o4 0.4.23. o4 reads it to decide whether your terminal can show inline image previews, but it doesn’t draw previews in any terminal yet. An image you paste or attach shows as a label above the prompt either way.
Model providers and API keys
o4 checks these variables for a provider’s credentials when no key for that provider is stored in~/.o4/settings.json. A key you enter in /config or the setup wizard takes priority over the environment. See Providers and API keys.
For “
A, then B”, o4 uses the first one that is set and not empty.
Amazon Bedrock
Theamazon-bedrock provider looks for credentials in this order:
- A Bedrock API key in
AWS_BEARER_TOKEN_BEDROCK, orBEDROCK_API_KEY. AWS_ACCESS_KEY_IDandAWS_SECRET_ACCESS_KEY, plusAWS_SESSION_TOKENfor temporary credentials.- The profile named in
AWS_PROFILE(ordefault) in~/.aws/credentials.
AWS_REGION, then AWS_DEFAULT_REGION, then the region of the AWS_PROFILE profile (or default) in ~/.aws/config, and finally us-east-1. The bedrock_region key in settings.json has no effect in o4 0.4.23.
BEDROCK_ENDPOINT_OVERRIDE replaces the Bedrock Runtime endpoint URL. o4 accepts only HTTPS Bedrock Runtime endpoints on AWS hosts and ignores anything else, with a warning in the log.
Subscription logins from other tools
Where the
codex CLI keeps its files. Default ~/.codex. o4 reads your ChatGPT sign-in from $CODEX_HOME/auth.json, and /auth import codex without a name signs in there. Other saved ChatGPT accounts use their own folders under ~/.o4/accounts/codex/, whatever CODEX_HOME is.Where Claude Code keeps its files. When o4 can’t run the
claude command, /auth import claude reads .credentials.json from this folder first, then from ~/.claude.Web search
Theweb_search tool uses Brave Search or Tavily when it has a key, and DuckDuckGo otherwise.
A Brave Search API key. Used when no
brave key is stored in settings.json. If both a Brave and a Tavily key are available, Brave is used, and a search that fails on Brave is tried again on Tavily.A Tavily API key. Used when no
tavily key is stored in settings.json and no Brave key is available.Commands run by the
bash, repl and test_run tools, ! commands, o4 watch checks, and the language servers and formatters o4 starts don’t see your provider keys. o4 removes these from their environment: the variables in the provider table above, AWS_BEARER_TOKEN_BEDROCK, BEDROCK_API_KEY, the api_key_env variable of each custom provider, and the key variables of a few providers o4 doesn’t offer. This way the model can’t read your keys through a shell command. Other AWS_* variables, GH_TOKEN, GITHUB_TOKEN and GOOGLE_APPLICATION_CREDENTIALS stay, so tools like aws, gh and gcloud keep working. BRAVE_API_KEY and TAVILY_API_KEY also stay. Hooks, MCP servers and plugin tools get only a short list of basic variables (PATH, HOME, USER, LOGNAME, SHELL, TERM, TMPDIR, TZ, LANG, PWD and LC_*), plus the ones you set for hooks and MCP servers in their config, including an MCP server’s pass_env. Plugin tools also get a fixed PATH of /usr/bin:/bin:/usr/sbin:/sbin.Daemon
The data folder
o4 daemon commands use for the daemon’s socket, lock, record and log. Default ~/.o4. Each data folder has its own daemon, so set the same value for o4 daemon start, status and stop. The [daemon] settings are still read from ~/.o4/config.toml.interactive_sessions on in the [daemon] section, a session that runs in the daemon gets the environment of the window that opened it for its commands, hooks and MCP servers, and the provider keys exported there for its model calls. The daemon’s own O4_* variables and its proxy settings (HTTPS_PROXY, HTTP_PROXY, NO_PROXY, SSL_CERT_FILE, SSL_CERT_DIR) stay those of the window that started the daemon. When yours differ, the window says so; run o4 daemon restart from that terminal, once its sessions are done, to change them. The variables that only change how a window draws itself, such as O4_TUI_MODE and O4_PERSONALITY, may differ without a notice.
Telemetry
o4 sends a small anonymous usage ping at most once a day. See Telemetry and privacy for what it contains. These variables can only turn telemetry off; they can’t turn it on if you disabled it withtelemetry_enabled in settings.json.
The URL the daily ping is sent to, for example an internal mirror. Default
https://t.open4rena.ai/p.A URL to upload the local telemetry event log (
~/.o4/telemetry/events.jsonl) to. When set, o4 posts the logged events there every 5 minutes and when the session ends. Unset by default, so the event log stays on your machine.Debugging
Sets what o4 writes to its log file,
~/.o4/o4.log. It takes the usual tracing filter syntax, such as debug or o4_coding_agent=debug,warn. Default warn. The TUI keeps log output off the screen, so read the file instead.A test switch. Set to
1 to let MCP servers with a remote transport and http hooks use localhost, loopback and private network addresses, which o4 refuses otherwise. Link-local addresses, such as 169.254.169.254, stay blocked.Set to
1 (or true, yes, on) to print how long each TUI frame takes to draw, on standard error. The output contains only timings and counts, no text from your session. Use it when you report a slow or laggy interface.Set by o4
o4 setsO4_SANDBOXED=1 inside the sandbox on Linux, so a script can tell it’s running there. For sandboxed commands in the guarded and airlock tiers, it also sets HTTP_PROXY, HTTPS_PROXY, http_proxy, https_proxy and ALL_PROXY to its egress proxy, unless you turned the proxy off with proxy.enabled = false in the [sandbox] section.