Skip to content

Windows desktop app exits after idle and cannot start until AppData\Local\OpenAI\Codex is recreated #30338

Open

Description

@lishaojiekao

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

26.616.10790.0

What subscription do you have?

ChatGPT Pro

What platform is your computer?

Microsoft Windows NT 10.0.19045.6159 x64

What issue are you seeing?

Summary

The Windows desktop app initially works normally.

After being left idle for several hours, the application exits by itself.

After that, every launch only shows the Loading screen briefly and then exits immediately.

The CLI continues to work normally.

Environment

  • Windows 10 22H2 (19045.6159)
  • Codex Desktop 26.616.10790.0
  • Installed from the official Codex download page
  • ChatGPT Pro

What I tried

None of the following resolved the problem:

  • Deleting ~/.codex
  • Deleting AppData\Roaming\Codex
  • Reinstalling the application
  • Deleting runtime subdirectories under AppData\Local\OpenAI\Codex
  • Restarting Windows

The CLI continued to work correctly throughout.

Workaround

The issue is consistently resolved by renaming:

C:\Users\<user>\AppData\Local\OpenAI\Codex

to another name (for example Codex_old).

After doing this, launching Codex recreates a fresh AppData\Local\OpenAI\Codex directory and the desktop application starts normally.

This workaround has worked every time the problem occurred.

Additional observations

  • No Codex.exe process remains running after the application exits.
  • Windows Event Viewer does not record an Application Error.
  • The desktop startup log always stops around:
browser_use_iab_backend_startup_started

with no further log entries.

  • Occasionally, Windows displays an error dialog for:
codex-windows-sandbox-setup.exe

with the message:

The specified module could not be found.

The executable is located under:

C:\Program Files\WindowsApps\OpenAI.Codex_26.616.10790.0_x64__2p2nqsd0c76g0\...

Deleting ~/.codex does not resolve the issue.

Recreating AppData\Local\OpenAI\Codex consistently restores the application.

Reinstalling the application alone does not reliably resolve the issue because the existing AppData\Local\OpenAI\Codex directory is preserved.

What steps can reproduce the bug?

The exact trigger is currently unknown, but this is the sequence that has happened multiple times:

  1. Install Codex Desktop.
  2. Use the application normally.
  3. Leave the application idle for several hours.
  4. The desktop application exits by itself.
  5. Every subsequent launch shows the Loading screen briefly and immediately exits.
  6. CLI continues to work normally.

The issue is consistently resolved by renaming:

C:\Users<user>\AppData\Local\OpenAI\Codex

which causes Codex to recreate a fresh local runtime directory.

What is the expected behavior?

The desktop application should continue running while idle.

If local runtime state becomes invalid or inconsistent, Codex should either:

  • automatically repair the local runtime,
  • recreate the corrupted runtime state,
  • or display an actionable error message,

instead of exiting silently during startup.

Additional information

codex-desktop-e49867e7-0898-41f4-9808-595bb605dacd-17996-t0-i1-034148-0.log

Image Image

Activity

  1. added
    appIssues related to the Codex desktop app
    on Jun 27, 2026
  2. added
    bugSomething isn't working
    windows-osIssues related to Codex on Windows systems
    sandboxIssues related to permissions or sandboxing
    on Jun 27, 2026
  3. lishaojiekao commented on Jun 29, 2026

    @lishaojiekao
    Author

    Update

    I found a more precise timeline.

    After reinstalling Codex, the app initially worked again.

    At around 10:37, Windows AppXDeploymentServer automatically updated Codex from:

    • 26.616.10790.0

    to:

    • 26.623.5546.0

    The AppX deployment log confirms this package update.

    During the update, the log also showed an error while deleting the previous package file:

    app\icudtl.dat

    A few hours later, Codex exited by itself again. After that, launching the app causes it to flash briefly and exit.

    Current installed version is now:

    26.623.5546.0

    This seems different from #29593 because deleting ~/.codex did not resolve my issue. The failure appears correlated with the MSIX package update/migration from 26.616 to 26.623.

    Image
  4. lishaojiekao commented on Jun 29, 2026

    @lishaojiekao
    Author

    I found another important observation.

    Resetting the Windows application from:

    Settings → Apps → OpenAI Codex → Advanced options → Reset

    restores the application.

    After the reset, I restored my original ~/.codex directory, and Codex continued to work normally.

    This suggests that ~/.codex is not the cause of the startup failure.

    The reset recreates the MSIX application state under AppData\Local\Packages\OpenAI.Codex_*, which appears to be more closely related to the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    appIssues related to the Codex desktop appbugSomething isn't workingsandboxIssues related to permissions or sandboxingwindows-osIssues related to Codex on Windows systems

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions