Codex App for Windows fail to startup in WSL Agent mode

Open 💬 6 comments Opened Apr 9, 2026 by lifei
💡 Likely answer: A maintainer (github-actions[bot], contributor) responded on this thread — see the highlighted reply below.

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

26.406.31014

What subscription do you have?

free

What platform is your computer?

Microsoft Windows NT 10.0.26200.0 x64

What issue are you seeing?

When using the setting "runcodexinwindowssubsystemforlinux": true, the app always stuck in the login UI.

I have to modify the file $env:USERPROFILE\.codex\.codex-global-state.json to remove the following code:
"runcodexinwindowssubsystemforlinux": true.

It fails to startup in VSCode extension too.

What steps can reproduce the bug?

  1. Go to settings page, switch Agent environment to Windows Subsystem for Linux.
  2. Exit the App and restart it.
  3. Stuck in the login UI.
  4. open $env:USERPROFILE\.codex\.codex-global-state.json, and remove the following code:

"runcodexinwindowssubsystemforlinux": true

  1. Open the App again, and it runs fine.

What is the expected behavior?

_No response_

Additional information

_No response_

View original on GitHub ↗

6 Comments

github-actions[bot] contributor · 3 months ago

Potential duplicates detected. Please review them and close your issue if it is a duplicate.

  • #16815
  • #16169

Powered by Codex Action

lifei · 3 months ago

when stuck in the login UI, can not login or enter key, no any response.

lifei · 3 months ago
2026-04-12 22:19:41.087 [info] Activating Codex extension
2026-04-12 22:19:41.087 [info] [CodexMcpConnection] Spawning codex app-server
2026-04-12 22:19:41.087 [info] [wsl] eligible distro list listResult="Ubuntu\npodman"
2026-04-12 22:19:41.087 [info] [spawn-codex-process] Spawning codex process inside WSL
2026-04-12 22:19:41.087 [info] [spawn-codex-process] WSL command command="wsl.exe -d Ubuntu --cd /mnt/d/Code/self-projects/liruixin.net -- /usr/bin/bash -lc /usr/bin/env 'PATH=/mnt/c/Users/lifei/.vscode/extensions/openai.chatgpt-26.409.20454-win32-x64/bin/linux-x86_64:$PATH' RUST_LOG=warn CODEX_INTERNAL_ORIGINATOR_OVERRIDE=codex_vscode /home/linuxbrew/.linuxbrew/bin/codex app-server --analytics-default-enabled"
2026-04-12 22:19:41.087 [info] [IpcRouter] I am the router
2026-04-12 22:19:41.087 [info] [IpcRouter] I am the router
2026-04-12 22:19:41.087 [error] [CodexMcpConnection] cli: message="your 131072x1 screen size is bogus. expect trouble"
2026-04-12 22:19:41.087 [warning] [IpcClient] Received broadcast but no handler is configured method=client-status-changed
2026-04-12 22:19:42.231 [warning] [CodexMcpConnection] cli: message="codex_core::plugins::startup_sync: startup remote plugin sync failed; will retry on next app-server start error=chatgpt authentication required to sync remote plugins; api key auth is not supported"
2026-04-12 22:19:42.598 [info] [CodexMcpConnection] Initialize received id=CodexWebviewProvider.webview:14e65bf5-4cda-41ca-9fa6-ea39d148d11b
2026-04-12 22:19:42.599 [warning] [CodexMcpConnection] Dropping MCP message received before initialization
2026-04-12 22:19:42.642 [info] [CodexMcpConnection] Initialize received id=CodexWebviewProvider.webview:db37607d-9a6f-48d8-9f75-7d0bdc960773
2026-04-12 22:19:42.642 [warning] [CodexMcpConnection] Dropping MCP message received before initialization
2026-04-12 22:19:51.953 [warning] [CodexMcpConnection] cli: message="codex_core::plugins::manager: failed to warm featured plugin ids cache error=failed to send remote plugin sync request to https://chatgpt.com/backend-api/plugins/featured: error sending request for url (https://chatgpt.com/backend-api/plugins/featured?platform=codex)"
lifei · 3 months ago
Potential duplicates detected. Please review them and close your issue if it is a duplicate. Codex app on Windows: WSL agent mode fails with: Error creating task Invalid request: AbsolutePathBuf deserialized without a base path #16815 Codex crashes on startup on Windows when WSL is enabled but no distro is installed #16169 _Powered by Codex Action_

I have review both two issues above. I think either of them is a duplicate.

zerebos · 2 months ago

I am also running into this. I tried moving my .codex folder over from windows to WSL since the docs say they should be identical but that didn't work. I also tried running and logging in via CLI in WSL first before launching codex to make sure at least the auth was there but it still lead to this broken Codex state.

klockk · 2 months ago

Same issue for me... codex cli works in WSL, $CODEX_HOME set to my windows home .codex folder so they are in sync..
Change the agent to WSL and all I get on restart is a login window that stalls if I re-enter my API key and click continue.....
Only way to fix is kill and set runcodexinwindowssubsystemforlinux=false... 👎