Sandbox controls
Compare read-only, workspace-write, and danger-full-access modes before giving Codex file or shell permissions.
An OpenAI Codex CLI config generator creates a ready-to-paste config.toml and launch command for model choice, sandbox mode, approval policy, working directory, profiles, and optional web search.
OpenAI documents Codex CLI as a local coding agent with approval modes and sandbox controls. Keep destructive access out of shared presets, and reserve never plus danger-full-access for automation hosts you already control.
model = "gpt-5.1"
sandbox_mode = "workspace-write"
approval_policy = "on-request"
model_reasoning_effort = "high"
codex \
-m \
'gpt-5.1' \
-s \
workspace-write \
-a \
on-request \
-c \
'model_reasoning_effort="high"' \
-C \
'$PWD' \
--strict-config \
'Implement the requested feature and verify it locally.'export CODEX_HOME="${CODEX_HOME:-$HOME/.codex}"
mkdir -p "$CODEX_HOME"
cat > "$CODEX_HOME/config.toml" <<'TOML'
model = "gpt-5.1"
sandbox_mode = "workspace-write"
approval_policy = "on-request"
model_reasoning_effort = "high"
TOML
codex --strict-config --help >/dev/nullCompare read-only, workspace-write, and danger-full-access modes before giving Codex file or shell permissions.
Generate interactive, review, and automation presets using untrusted, on-request, or never approval behavior.
Copy config.toml, profile instructions, and terminal commands for interactive Codex, codex exec, or codex review.
An OpenAI Codex CLI config generator creates a ready-to-paste config.toml and terminal command for model choice, sandbox mode, approval policy, working directory, profiles, and optional web search.
Codex CLI reads configuration from the Codex home directory, normally ~/.codex/config.toml. You can also layer a named profile file with the -p flag.
Use read-only for audits, workspace-write for normal feature work, and danger-full-access only when you already trust the environment and need unrestricted local commands.
The safest interactive default is on-request or untrusted because Codex asks before risky commands. Use never only for automation running in a separately controlled environment.
No. The generator runs in your browser, stores preferences in localStorage, and creates copyable TOML and shell snippets without sending the generated config to Tornic.