Windows Sandbox feature required but cannot be installed - Codex fails to initialize

Open 💬 10 comments Opened Apr 8, 2026 by dbradtathena

What version of the Codex App are you using (From “About Codex” dialog)?

codex-cli 0.117.0-alpha.12

What subscription do you have?

Enterprise

What platform is your computer?

Microsoft Windows NT 10.0.26200.0 x64

What issue are you seeing?

Codex fails to send messages with error "Unable to send message - Set up Agent sandbox to continue".

The sandbox initialization hangs indefinitely when attempting to execute commands. Investigation revealed:

  1. Sandbox log shows ACL helper process gets stuck: "read ACL helper already running; skipping spawn"
  2. Testing codex sandbox windows echo "test" hangs indefinitely
  3. Root cause: Windows Sandbox feature is not installed/enabled on the system
  4. Attempted to enable Windows Sandbox via Windows Features but installation failed after 90 minutes (likely blocked by corporate IT policies)

Error from sandbox log (C:\Users\dbradt\.codex\.sandbox\sandbox.log):

What steps can reproduce the bug?

  1. Use Windows 10 Enterprise with Windows Sandbox feature disabled/not installed
  2. Install Codex/Windsurf
  3. Open Codex and attempt to send any message
  4. Observe "Unable to send message - Set up Agent sandbox to continue" error
  5. Sandbox initialization hangs indefinitely

To verify Windows Sandbox status:

  • Open "Turn Windows features on or off"
  • Check if "Windows Sandbox" is unchecked
  • Attempting to enable it may fail on corporate-managed systems

Configuration tested:

  • config.toml with sandbox = "elevated" (with admin rights)
  • config.toml with sandbox = "none" and enabled = false
  • Cleared sandbox state directories (.sandbox, .sandbox-secrets, .tmp)
  • Killed stuck sandbox processes
  • All configurations result in same hanging behavior

Also tried to enable Windows sandbox. Machine attempted to do this update for 90 minutes and then it failed.

What is the expected behavior?

Codex should either:

  1. Detect that Windows Sandbox feature is not available and provide a clear error message explaining the requirement
  2. Provide alternative sandbox mechanisms (WSL, Docker, or restricted token mode) that don't require Windows Sandbox feature
  3. Allow graceful degradation or fallback when Windows Sandbox is unavailable
  4. Document Windows Sandbox as a system requirement in installation documentation

Expected error message example:
"Windows Sandbox feature is required but not installed. Please enable it via Windows Features or contact your IT administrator."

Additional information

  • System: Windows 10 Enterprise 2009 (Build 26200)
  • Codex version: 0.117.0-alpha.12
  • Running with Administrator privileges
  • Corporate-managed system where Windows Sandbox installation is blocked by IT policy
  • Virtualization appears to be available (HyperVisorPresent check passed)
  • Issue affects both Windsurf-integrated Codex and standalone Codex app
  • Worked once briefly, then stopped working (suggesting sandbox state corruption)

This appears to be a common issue in enterprise environments where Windows Sandbox feature cannot be enabled due to corporate security policies. A workaround or alternative sandbox mechanism would greatly improve enterprise usability.

View original on GitHub ↗

10 Comments

rwalle · 3 months ago

Interesting, what makes you think Codex's sandboxing is related to the native "Windows Sandbox" feature? I was looking into how Codex does sandboxing, and my conclusion is that what Codex is doing is just access control based sandbox that has nothing to do with VM or "Windows Sandbox" feature, based on my reading of windows-sandbox-rs folder. It uses a combination of local user accounts, restricted tokens, firewall rules etc to achieve sandboxing.

In fact, with v0.118.0 on a Windows 11 machine, I was able to use the "elevated sandbox" without even turning on the "Windows Sandbox" feature.

~I am aware that OpenAI's sandboxing documentation says Codex uses the native Windows Sandbox, but that is inconsistent with my finding. Unless there is some non-public code paths or experimental flag, I suspect that the documentation is wrong.~ I misread the documentation. The documentation does not actually refer to the built-in Windows Sandbox or links to it.

dbradtathena · 3 months ago

I tried that because somebody in my organization tried turning on windows sandbox during troubleshooting and it fixed his issue.

rwalle · 3 months ago

Thanks. Have you by any chance observed similar issues on a Windows 11 machine?

dbradtathena · 3 months ago

Somebody else on my team is having the same issue and I think on a Windows 11 machine. I keep getting told the issue should be fixed soon but we are approaching 3 weeks with it still not working.

dbradtathena · 3 months ago

It works now never mind.

harissaleem156-debug · 2 months ago

This appears similar to the linked duplicate issues. My environment is Windows desktop, and I see:

  • “Couldn’t set up admin sandbox”
  • “Use backup sandbox” also fails
  • I cannot send messages because setup never completes

Please confirm whether this is the same root cause and whether there is a recommended workaround.

dbradtathena · 2 months ago
This appears similar to the linked duplicate issues. My environment is Windows desktop, and I see: “Couldn’t set up admin sandbox” “Use backup sandbox” also fails * I cannot send messages because setup never completes Please confirm whether this is the same root cause and whether there is a recommended workaround.

This was the same issue I had. The only fix for me was OpenAI fixing the issue in a release last week.

harissaleem156-debug · 2 months ago
> This appears similar to the linked duplicate issues. My environment is Windows desktop, and I see: > > “Couldn’t set up admin sandbox” > “Use backup sandbox” also fails > * I cannot send messages because setup never completes > > Please confirm whether this is the same root cause and whether there is a recommended workaround. This was the same issue I had. The only fix for me was OpenAI fixing the issue in a release last week.

I got this get fixed by doing a minor change from working files I took assistance for chat gpt. But I am running through another problem my codex is running g very slow on responding to threads and commands its like taking hours. How to deal with it? Is it because i may be running a heavy project with back to back prompts on single chat?

hiredmonk · 1 month ago

Adding a separate root cause that produces this exact same "Set up Agent sandbox to continue" symptom, in case it helps others landing here — this is not the OP's Windows-Sandbox-can't-install scenario, but the surface error is identical.

Environment: Windows 11 Home, Codex desktop app, hit immediately after a recent app update.

Symptom chain:

  1. Composer shows Set up Agent sandbox to continue.
  2. Clicking Set upCouldn't set up admin sandbox.
  3. Use backup sandbox also fails.
  4. The real tell only appeared on a chat resume: a Failed to resume chat toast reading:

> failed to load configuration: legacy profile = "full_access" config is no longer supported; use --profile full_access with full_access.config.toml instead

Actual root cause: after the update, the legacy top-level profile = "..." key in ~/.codex/config.toml (Windows: C:\Users\<you>\.codex\config.toml) is no longer supported. When that key is present, the entire config fails to parse, so Codex silently falls back to defaults that try to initialize the admin/Windows Sandbox — which can't be created on Windows Home — and you get stuck at the sandbox prompt. The sandbox message is a downstream symptom of the config not loading, not the underlying problem.

Fix: remove the legacy profile = "..." line and its [profiles.<name>] table, and promote the settings you care about to the top level. Mine went from:

profile = "full_access"
sandbox_mode = "danger-full-access"

[profiles.full_access]
approval_policy = "never"
sandbox_mode = "danger-full-access"
web_search = "live"

to:

sandbox_mode = "danger-full-access"
approval_policy = "never"
web_search = "live"

Then fully quit Codex (end any lingering codex.exe in Task Manager) and relaunch. Config parses cleanly and the sandbox prompt disappears.

(Alternatively, follow the message's own suggestion: move the profile into a separate full_access.config.toml selected via --profile full_access. For a single always-on setup, top-level keys are simpler.)

Suggested product fix: a config-parse failure should surface a blocking, explicit error (or migrate the legacy profile = key automatically) instead of silently degrading into an unrelated "set up sandbox" prompt — the current behavior sends people down the wrong debugging path.

abevol · 1 month ago
Actual root cause: after the update, the legacy top-level profile = "..." key in ~/.codex/config.toml (Windows: C:\Users\<you>\.codex\config.toml) is no longer supported. When that key is present, the entire config fails to parse, so Codex silently falls back to defaults that try to initialize the admin/Windows Sandbox — which can't be created on Windows Home — and you get stuck at the sandbox prompt. The sandbox message is a downstream symptom of the config not loading, not the underlying problem.

Yes, it is related to a configuration parsing failure. Codex returned to normal after I removed the following incompatible items from the configuration:

[mcp_servers.codegraph]
approval_mode = "approve"

[mcp_servers.codegraph.tools]

[mcp_servers.codegraph.tools.codegraph_context]
approval_mode = "approve"

[mcp_servers.codegraph.tools.codegraph_status]
approval_mode = "approve"

[mcp_servers.codegraph.tools.codegraph_files]
approval_mode = "approve"

[mcp_servers.codegraph.tools.codegraph_explore]
approval_mode = "approve"

[mcp_servers.codegraph.tools.codegraph_search]
approval_mode = "approve"

[mcp_servers.codegraph.tools.codegraph_node]
approval_mode = "approve"

[tools.codegraph_context]
approval_mode = "approve"

[tools.codegraph_status]
approval_mode = "approve"

[tools.codegraph_files]
approval_mode = "approve"

[tools.codegraph_explore]
approval_mode = "approve"

[tools.codegraph_search]
approval_mode = "approve"

[tools.codegraph_node]
approval_mode = "approve"