codex - 💡(How to fix) Fix Windows: local runner cannot start, CreateProcessAsUserW failed: 5

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

Codex Desktop cannot execute any local workspace command on Windows. The workspace folder is readable from PowerShell outside Codex, but Codex tool execution fails before the command starts with:

windows sandbox: runner error: CreateProcessAsUserW failed: 5

Error Message

windows sandbox: runner error: CreateProcessAsUserW failed: 5 execution error: Io(Custom { kind: Other, error: "windows sandbox: runner error: CreateProcessAsUserW failed: 5" }) The Node REPL helper also failed with a sandbox/process launch error: Retried command after permission grant; same error.

Root Cause

Troubleshooting Already TriedConfirmed Controlled Folder Access is off. Confirmed folder is readable outside Codex. Tried explicit Codex file permission grant for D:\temp\temp\Codex. Retried command after permission grant; same error. PowerShell is MSI-installed, not Store-installed. NotesThis appears to be a Codex Desktop Windows runner/session-token issue rather than a workspace ACL or shell issue, because both PowerShell command execution and Node helper startup fail before accessing files.

Code Example

Get-ChildItem -Force -LiteralPath 'D:\temp\temp\Codex'

### What steps can reproduce the bug?

### Environment
- OS: Windows
- App: Codex Desktop
- Workspace path: `D:\temp\temp\Codex`
- Shell: PowerShell 7.6.2 installed via MSI
- Controlled Folder Access: Off
- Workspace sandbox mode shown in thread: `workspace-write`
- Writable root shown in thread: `D:\temp\temp\Codex`

### Reproduction
1. Open Codex Desktop on Windows.
2. Open workspace: `D:\temp\temp\Codex`
3. Ask Codex to read/list the folder.
4. Codex attempts to run:
RAW_BUFFERClick to expand / collapse

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

26.527.31326

What subscription do you have?

pro

What platform is your computer?

Microsoft Windows NT 10.0.26200.0 x6

What issue are you seeing?

Bug: Codex Desktop on Windows cannot launch local runner: CreateProcessAsUserW failed: 5

Summary

Codex Desktop cannot execute any local workspace command on Windows. The workspace folder is readable from PowerShell outside Codex, but Codex tool execution fails before the command starts with:

windows sandbox: runner error: CreateProcessAsUserW failed: 5

Environment

  • OS: Windows
  • App: Codex Desktop
  • Workspace path: D:\temp\temp\Codex
  • Shell: PowerShell 7.6.2 installed via MSI
  • Controlled Folder Access: Off
  • Workspace sandbox mode shown in thread: workspace-write
  • Writable root shown in thread: D:\temp\temp\Codex

Reproduction

  1. Open Codex Desktop on Windows.
  2. Open workspace: D:\temp\temp\Codex
  3. Ask Codex to read/list the folder.
  4. Codex attempts to run:
    Get-ChildItem -Force -LiteralPath 'D:\temp\temp\Codex'

What steps can reproduce the bug?

Environment

  • OS: Windows
  • App: Codex Desktop
  • Workspace path: D:\temp\temp\Codex
  • Shell: PowerShell 7.6.2 installed via MSI
  • Controlled Folder Access: Off
  • Workspace sandbox mode shown in thread: workspace-write
  • Writable root shown in thread: D:\temp\temp\Codex

Reproduction

  1. Open Codex Desktop on Windows.
  2. Open workspace: D:\temp\temp\Codex
  3. Ask Codex to read/list the folder.
  4. Codex attempts to run:
    Get-ChildItem -Force -LiteralPath 'D:\temp\temp\Codex'

What is the expected behavior?

Codex should be able to launch its local helper/runner and read files inside the configured workspace. Actual BehaviorCodex fails to spawn the local runner: Add to chat execution error: Io(Custom { kind: Other, error: "windows sandbox: runner error: CreateProcessAsUserW failed: 5" })

The Node REPL helper also failed with a sandbox/process launch error: Add to chat node_repl kernel exited unexpectedly windows sandbox failed: spawn setup refresh

Additional information

Verification Outside CodexThe same folder is readable from an external PowerShell session: powershell

Get-ChildItem -Force 'D:\temp\temp\Codex'

Output shows files successfully, including: Add to chat PIMCO_PIMS_Income_Fund_A_TSR_AR.pdf PIMCO_PIMS_Income_Fund_A_TSR_SAR.pdf PIMCO_PIMS_Income_Fund_FSTM_AR.pdf PIMCO_PIMS_Income_Fund_FSTM_SAR.pdf

Troubleshooting Already TriedConfirmed Controlled Folder Access is off. Confirmed folder is readable outside Codex. Tried explicit Codex file permission grant for D:\temp\temp\Codex. Retried command after permission grant; same error. PowerShell is MSI-installed, not Store-installed. NotesThis appears to be a Codex Desktop Windows runner/session-token issue rather than a workspace ACL or shell issue, because both PowerShell command execution and Node helper startup fail before accessing files.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

codex - 💡(How to fix) Fix Windows: local runner cannot start, CreateProcessAsUserW failed: 5