codex - 💡(How to fix) Fix The Codex application cannot use the built-in browser if the project files are in WSL(Windows Subsystem for Linux)

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…

Error Message

Actual error:

Fix Action

Fix / Workaround

At minimum, Codex should provide a documented workaround or configuration for WSL workspaces.

Code Example

{
  "kernel_status": "running",
  "kernel_stderr_tail": "windows sandbox failed: setup refresh failed with status exit code: 1",
  "reason": "stdout_eof",
  "stream_error": null
}

---

const { setupBrowserRuntime } = await import(
  'C:/Users/<user>/.codex/plugins/cache/openai-bundled/browser/26.519.81530/scripts/browser-client.mjs'
);

---

await setupBrowserRuntime({ globals: globalThis });
globalThis.browser = await agent.browsers.get('iab');
RAW_BUFFERClick to expand / collapse

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

26.519.81530

What subscription do you have?

GPT Pro

What platform is your computer?

Microsoft Windows NT 10.0.19045.0 x64

What issue are you seeing?

The Codex Desktop in-app browser is visible and can display a local page, but the agent cannot connect to/control it through the Browser plugin when the workspace is opened from WSL via a UNC path.

The failure happens before any real browser navigation or click.

Actual error: node_repl kernel exited unexpectedly node_repl diagnostics:

{
  "kernel_status": "running",
  "kernel_stderr_tail": "windows sandbox failed: setup refresh failed with status exit code: 1",
  "reason": "stdout_eof",
  "stream_error": null
}

What steps can reproduce the bug?

  1. On Windows, open a project located inside WSL in Codex Desktop.

Example workspace path: \\wsl$\Ubuntu\home\user\projects\testsite

  1. Start a local frontend app.

Example: http://localhost:5005

  1. Open the Codex in-app browser.

The in-app browser visually opens and can show: http://localhost:5005/login

  1. Try to control the in-app browser through the Browser plugin / node_repl using the browser-client bootstrap:
const { setupBrowserRuntime } = await import(
  'C:/Users/<user>/.codex/plugins/cache/openai-bundled/browser/26.519.81530/scripts/browser-client.mjs'
);
await setupBrowserRuntime({ globals: globalThis });
globalThis.browser = await agent.browsers.get('iab');
  1. The node_repl kernel exits unexpectedly with:

"windows sandbox failed: setup refresh failed with status exit code: 1"

Notes:

  • The same localhost app works when tested through an external Google Chrome instance launched with remote debugging / CDP.
  • Through external Chrome/CDP, the agent can open the app, log in, and run UI smoke tests successfully.
  • The built-in browser works normally when the workspace is opened from a regular Windows folder instead of a WSL UNC path.

What is the expected behavior?

The Browser plugin should be able to connect to and control the Codex in-app browser when the workspace is opened from a WSL UNC path.

At minimum, Codex should provide a documented workaround or configuration for WSL workspaces.

Additional information

Environment:

  • OS: Microsoft Windows NT 10.0.19045.0 x64
  • Windows edition observed separately: Windows 10 Pro
  • Workspace is located in WSL
  • Workspace is opened in Codex as a UNC path, for example: \wsl$\Ubuntu\home\user\projects\testsite
  • Local frontend example: http://localhost:5005
  • In-app browser example URL: http://localhost:5005/login
  • Browser plugin path/version: C:\Users<user>.codex\plugins\cache\openai-bundled\browser\26.519.81530\scripts\browser-client.mjs
  • Codex runtime binary path observed: C:\Users<user>\AppData\Local\OpenAI\Codex\bin\958d608b5e0546a5\codex.exe
  • Codex app version was not visible in Windows uninstall registry entries or EXE ProductVersion metadata on this machine.

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 The Codex application cannot use the built-in browser if the project files are in WSL(Windows Subsystem for Linux)