[Windows] `codex app` falsely reports Desktop missing when StartApps entry is named ChatGPT
What version of Codex CLI is running?
codex-cli 0.144.0-alpha.4
What version of Codex Desktop is installed?
OpenAI.Codex 26.707.3748.0 from the Microsoft Store / AppX package.
Platform
- Microsoft Windows 11 Pro
- Version
10.0.26200, build26200 - 64-bit
What issue are you seeing?
On Windows, codex app <workspace> reports that Codex Desktop is not installed and opens the installer even though the current OpenAI.Codex AppX package is installed, healthy, running, and its codex:// protocol is registered.
Observed output:
Codex Desktop not found; opening Windows installer...
After installing Codex Desktop, open workspace C:\work\repo.
The false negative comes from the current installation check in codex-rs/cli/src/desktop_app/windows.rs:
Get-StartApps -Name 'Codex' | Select-Object -First 1 -ExpandProperty AppID
On the affected installation, the package's Start entry is named ChatGPT, not Codex:
PS> Get-StartApps -Name 'Codex'
# no output
PS> Get-StartApps | Where-Object { $_.AppID -like 'OpenAI.Codex_*!App' }
Name AppID
---- -----
ChatGPT OpenAI.Codex_2p2nqsd0c76g0!App
AppX itself is healthy:
Name: OpenAI.Codex
Version: 26.707.3748.0
Status: Ok
AppID: OpenAI.Codex_2p2nqsd0c76g0!App
The package manifest also registers the codex protocol, and protocol activation works.
Steps to reproduce
- Install the current Microsoft Store / AppX Codex Desktop package on a machine where its Start entry is displayed as
ChatGPT. - Install or use the bundled/standalone Windows Codex CLI.
- Run:
``powershell``
codex app C:\work\repo
- Observe that the CLI opens the installer instead of the installed Desktop app.
Expected behavior
The CLI should detect the installed OpenAI.Codex package independently of its localized or packaged display name, then open the existing codex://threads/new?path=... protocol URL.
Suggested repair
Detect the stable package/application identity rather than querying the mutable display name. For example:
Get-StartApps |
Where-Object { $_.AppID -like 'OpenAI.Codex_*!App' } |
Select-Object -First 1 -ExpandProperty AppID
Alternatively, use Get-AppxPackage -Name OpenAI.Codex and rely on protocol activation for the final launch check.
A focused regression test should cover this case:
- display name is
ChatGPT - AppID is
OpenAI.Codex_...!App - installation check succeeds
- launcher uses the registered
codex://protocol
Additional evidence
The executable used from LocalAppData is byte-for-byte identical to the active AppX bundled codex.exe; there is no stale npm Codex installation. Direct execution from C:\Program Files\WindowsApps is denied by normal package ACLs and should not be used as a workaround.
Issue #28667 is related but distinct: it concerns the TUI /app path directly executing a packaged WindowsApps executable. This report concerns the codex app <workspace> preflight returning a false not installed result because it searches by display name.
4 Comments
I reproduced this independently on Windows 10 Pro with the same current Desktop package and a standalone Codex CLI installation.
As in this report,
Get-StartApps -Name 'Codex'returns no result even though the package is healthy and the registeredcodex://protocol works. Runningcodex app <workspace>follows the installer path because the current preflight is tied to that display name.I prepared a focused candidate fix on current
main(9e552e9d1, checked on 2026-07-12):https://github.com/starriet9/codex/tree/fix/windows-app-package-detection
Current commit:
https://github.com/starriet9/codex/commit/0b45471acef5d9118360496e9adff602b56d69c4
The candidate replaces the Start-menu display-name query with an exact AppX package identity check:
This makes detection independent of the mutable/localized
CodexversusChatGPTdisplay name and also requires the official OpenAI publisher ID. The existingcodex://threads/new?...protocol launch remains unchanged.Validation on Windows:
The targeted regression test passes on current
main. The Clippy fix pass, rustfmt check, and diff check also passed for the same one-commit candidate. The exact package-identity query found the installed package above even though its Start app display name isChatGPT.An earlier full
codex-clirun of the same candidate passed 298 of 299 tests. The remaining unrelateddoctor::thread_inventorytest failed identically from unmodifiedmainin the same environment.This Windows identity check follows the same package-name and publisher-ID direction proposed in the closed maintainer PR #28253, while keeping this candidate limited to the reported
codex appfalse negative. If maintainers prefer the focused fix, the branch is ready for a PR invitation.I can independently reproduce this on the latest stable Codex CLI.
Environment
codex-cli 0.144.4OpenAI.Codex_26.707.8479.0_x64__2p2nqsd0c76g010.0.26200.8655(Windows 11 Core, x64)C:\Users\akuma\AppData\Local\Programs\OpenAI\Codex\bin\codex.exeObserved behavior
Running:
produces:
However, the AppX package is installed:
Output:
The Start app entry is named
ChatGPTrather thanCodex:Output:
Direct protocol activation successfully opens the requested workspace:
codex doctorreports:This confirms that the issue is still present in stable
0.144.4and Desktop package26.707.8479.0, while both the installed AppX package and the registeredcodex://protocol are working correctly.This was fixed upstream by #33901 and shipped in the stable
rust-v0.145.0release. The merged implementation detects the stable Windows package AppID instead of depending on the Start-menu display name, so both Codex- and ChatGPT-branded Desktop builds are recognized.I verified the release note and the current implementation. The focused local candidate discussed above is superseded by the merged upstream fix, and this issue can be closed as completed.
Yes it works for me on macOS 🎉️
Thanks 🙏🏼️