Repository navigation
Description
What version of the Codex App are you using (From “About Codex” dialog)?
OpenAI.Codex 26.1007.2314.0
What subscription do you have?
GPT Plus
What platform is your computer?
Microsoft Windows NT 10.0.26200.0 x64
What issue are you seeing?
After an apparent Codex Desktop update around October 10, 2026, the Windows application began failing to complete ChatGPT authentication.
The login interface displays the following error:
Sign-in could not be completedToken exchange failed: error sending request for url
(https://auth.openai.com/oauth/token)
Error code: token_exchange_failed
Before this update, I had been using Codex with a TUN-based global proxy configuration without authentication problems. Occasional network instability previously caused interrupted responses, but did not cause login failures or repeated sign-outs.
Since the update, I have observed:
Codex Desktop cannot reliably complete the ChatGPT OAuth login process.
Repeated workspace routing discovery timeouts in the application logs.
Multiple HTTP 432 responses with
Workspace routing is unavailable.The ChatGPT desktop application unexpectedly requires authentication again after Windows restarts. This occurred after two separate restarts and was not previously observed.
ChatGPT remains accessible through a web browser, although response performance is sometimes slow.
The installed package version is OpenAI.Codex 26.1007.2314.0.
Diagnostic logs collected over the most recent three days contain:
| Log pattern | Occurrences |
|---|---|
| workspace routing discovery timed out | 20 |
| Workspace routing is unavailable | 22 |
| status=432 | 23 |
| account/read | 88 |
| CRYPT_E_REVOCATION_OFFLINE | 0 |
| certificate verify failed | 0 |
These are keyword occurrence counts, not necessarily distinct failures. In particular, the account/read count includes all matching log entries, not exclusively errors.
The token_exchange_failed message is displayed in the login UI, but that exact string was not found in the inspected application log files.
The onset closely coincides with the application update. However, I cannot yet determine whether the underlying cause is an application regression, changed proxy handling, authentication/workspace routing behavior, or a combination of these factors.
What steps can reproduce the bug?
The bug could be reproduced by simply restart the computer and then open Codex (ChatGPT) again. Detailed steps are shown below:
- Run Codex Desktop for Windows, version
26.1007.2314.0. - Use a local proxy application with TUN mode and global routing enabled, which previously worked consistently.
- Launch Codex Desktop and attempt to sign in using an existing ChatGPT account.
- Complete the browser-based authentication flow and return to Codex.
- Observe the
token_exchange_failederror during OAuth token exchange. - Inspect the local Codex Desktop logs and observe repeated workspace routing discovery failures, timeouts, and HTTP 432 responses.
- Switch from TUN mode to the Windows system proxy while keeping global proxy routing enabled, and retry authentication. The login issue persists.
Additional observation: After restarting Windows on two separate occasions, the ChatGPT desktop application also required a fresh login, despite previously retaining authentication across system restarts.
This issue is reproducible in my current environment, but I have not confirmed whether it also occurs without a proxy or on earlier application versions.
What is the expected behavior?
Codex Desktop should successfully exchange the OAuth authorization code for an access token, complete ChatGPT authentication, and initialize account and workspace routing.
Previously authenticated desktop sessions should normally remain available across application and Windows restarts, provided the session is still valid.
Temporary network interruptions should not unnecessarily invalidate locally persisted authentication state.
If workspace routing or token exchange fails because of a transient network condition, the application should provide a recoverable error and allow a retry without requiring repeated full authentication.
Additional information
Update and runtime information
- Codex Desktop package:
OpenAI.Codex 26.1007.2314.0 - Approximate onset: October 10, 2026, following an apparent application update.
- Local runtime executable:
%LOCALAPPDATA%\OpenAI\Codex\bin\2e5e00daee91c61d\codex.exe - Runtime executable last modified: October 10, 2026, at 17:18:52 (local time). This timestamp is consistent with the suspected update period but does not independently establish the package installation time.
Network configuration
- Local HTTP proxy:
127.0.0.1:X - Previously working configuration: TUN mode + global proxy routing.
- Also tested: Windows system proxy + global routing.
- Proxy nodes have shown intermittent connectivity problems and elevated latency.
OAuth endpoint connectivity test
A request containing deliberately invalid OAuth parameters was sent directly to the relevant endpoint through the local HTTP proxy:
curl.exe -sS -D - -o NUL `
--max-time 60 `
--proxy "http://127.0.0.1:X" `
-H "Content-Type: application/x-www-form-urlencoded" `
--data "grant_type=test" `
-w "HTTP=%{http_code} TLS-ready=%{time_appconnect}s Total=%{time_total}s Exit=%{exitcode}`n" `
"https://auth.openai.com/oauth/token"The test completed successfully at the HTTP transport level:
HTTP/1.1 200 Connection established
HTTP/1.1 400 Bad Request
HTTP=400
TLS-ready=14.356540s
Total=15.949031s
Exit=0
openai-processing-ms: 10
The HTTP 400 response is expected because the OAuth parameters were deliberately invalid.
This confirms that the endpoint is reachable through the proxy and can process requests, although TLS establishment is unusually slow.
Earlier diagnostic attempts also produced connection timeouts and intermittent Schannel TLS errors, indicating potentially unstable network conditions.
Additional diagnostic finding:
I executed login status using the exact codex.exe bundled with my Codex Desktop installation (26.1007.2314.0).
The result was:
Logged in using ChatGPT
However, the Desktop application still fails after browser authorization with:
Sign-in failed: workspace routing discovery timed out
My logs also contain repeated account/read failures, workspace routing discovery timeouts, and HTTP 432 (Workspace routing is unavailable).
This indicates that local ChatGPT authentication state is present and recognized by the bundled CLI, while the Desktop application is unable to complete account/workspace initialization.
My explicit-proxy test of the OAuth token endpoint returned HTTP 400 as expected, with a TLS establishment time of 14.36 seconds. The possibility of a workspace-routing timeout interacting with high network latency may be worth investigating.
Related issues
- [Windows Desktop 26.1007.2314.0] Persistent HTTP 432 workspace routing failures and account lookup failure #52996 — Same Windows desktop version with HTTP 432 workspace routing failures and account lookup problems.
- Windows desktop: repeated workspace routing discovery failures and durable WebSocket 403 reconnect loop #53055 — Same desktop version with repeated workspace routing discovery failures and reconnect behavior.
The application update may have changed authentication or networking behavior in a way that makes previously tolerated network instability more disruptive. However, causality has not been established.
I would appreciate guidance on whether this is a known regression in 26.1007.2314.0, and whether a fix or supported workaround is available that does not require deleting local authentication data or changing a previously working system-wide proxy configuration.
Activity
github-actions commentedon Oct 12, 2026
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
HTTNH commentedon Oct 12, 2026
Additional diagnostic finding:
I executed
login statususing the exactcodex.exebundled with my Codex Desktop installation (26.1007.2314.0).The result was:
However, the Desktop application still fails after browser authorization with:
My logs also contain repeated
account/readfailures, workspace routing discovery timeouts, and HTTP 432 (Workspace routing is unavailable).This indicates that local ChatGPT authentication state is present and recognized by the bundled CLI, while the Desktop application is unable to complete account/workspace initialization.
My explicit-proxy test of the OAuth token endpoint returned HTTP 400 as expected, with a TLS establishment time of 14.36 seconds. The possibility of a workspace-routing timeout interacting with high network latency may be worth investigating.
BXNS-X commentedon Oct 12, 2026
I'm using the free version and yesterday I was logged in and used it, but today I can't sign in
ranjanilobo commentedon Oct 12, 2026
Additional reproduction details from a separate Windows 11 user (Codex desktop
OpenAI.Codex 26.1007.2314.0):token_exchange_failed/error sending request for url (https://auth.openai.com/oauth/token).oauth token exchange succeeded;codex login statusreports logged in using ChatGPT). Browser access to the user's ChatGPT Enterprise workspace also works normally.Ok, can log in successfully. Both PCs showNorton Web/Mail Shield Rootas the issuer forauth.openai.com; therefore Norton TLS interception alone does not distinguish the failing machine.curl.exe -4reacheshttps://auth.openai.com/oauth/tokenover TLS; GET returns HTTP 405 and invalid-grant POST returns HTTP 400, suggesting the endpoint is reachable from this machine via curl (not proof the desktop network stack works).account/login/startfollowed byaccount_login_completed ... success=false; other log lines showsa_server_request_failed ... errorMessage="Workspace routing is unavailable" ... status=432on/settings/userand/wham/usage, plusworkspace routing discovery failed.SettingsInitializefailure, followed byRepair of state locations ... returned Error Code: 0; no newer related event found. Reinstall, reboot, Windows sign-out, and Windows app Repair did not resolve it.SSL_CERT_FILEset in an auto-activated PowerShell environment; disabling auto-activation did not fix desktop login.This is a separate Enterprise-workspace user, not the original issue reporter (who listed Plus). These observations do not establish whether workspace routing errors are causal or a downstream symptom. No tokens, authorization codes, or private log files are included.
Lamonin commentedon Oct 13, 2026
Yeah, same problem, started from yesterday
x-xyu commentedon Oct 14, 2026
did u solve this problem yet?
x-xyu commentedon Oct 14, 2026
Confirmed workaround: set proxy variables at the Windows user level
I encountered the same symptoms with Codex Desktop for Windows
OpenAI.Codex 26.1007.2314.0, using Clash / Clash Verge with a local HTTP proxy:token_exchange_failedand/orworkspace routing discovery timed out.Logged in using ChatGPTfromlogin status.https://auth.openai.com/oauth/tokenthrough the proxy returned the expected HTTP 400 for intentionally invalid parameters, so the OAuth endpoint was reachable through the proxy.HTTP_PROXY,HTTPS_PROXY, etc. to%USERPROFILE%\.codex\.envand restarting Codex did not fix the desktop error.Get-ChildItem Env: | Where-Object Name -Match 'PROXY'in PowerShell returned nothing.What worked: I set the proxy environment variables in the Windows user environment (not just the
.codex\.envfile or current PowerShell session):After applying this user-level configuration and restarting the Codex desktop sign-in flow, the desktop login succeeded. I then opened a project and confirmed that Codex was usable, not merely signed in.
For anyone trying this, fully exit Codex and sign out/in to Windows or reboot before retrying, so the desktop process starts with the updated user environment. Keep Clash running on the configured port. Note that user-level proxy variables can also affect other applications, so back up any existing values before changing them.
This is a workaround confirmed on one machine, not proof of the underlying cause or a universal fix. It suggests that the desktop app's inheritance/use of proxy settings is worth investigating.
bugrabastaban commentedon Oct 14, 2026
I have the same problem and I haven't been able to solve it yet.
melroe commentedon Oct 14, 2026
[Windows Codex 26.1007.9446.0] Intermittent
token_exchange_failed— Login succeeds after signing out of ChatGPT Web without clearing cookiesDate: October 14, 2026
Platform: Windows x64, native Windows execution
Codex Desktop:
OpenAI.Codex 26.1007.9446.0(Microsoft Store)Subscription: Two ChatGPT Plus accounts
Related issue: #53261
Problem
Codex Desktop intermittently fails to authenticate ChatGPT accounts, even though browser authentication works and the OAuth token endpoint is reachable.
The displayed error is:
Observed behavior
~/.codex/auth.jsonafter backing it up did not resolve the failure.Important discovery: Successful recovery
I eventually recovered the Codex Desktop login using the following procedure:
Result: Codex Desktop login succeeded.
The recovery required no reinstall, system network changes, or manual clearing of authentication files during this final attempt.
Network diagnostics
127.0.0.1:7890auth.openai.com/oauth/tokenreturned the expected HTTP 400 for an intentionally invalid grant type, confirming basic connectivity.Additional logs showed repeated App Server WebSocket failures:
The WebSocket failures have not been established as the cause of OAuth failure.
Possible area to investigate
The recovery suggests that the interaction between browser authentication sessions and Codex Desktop's OAuth state may be relevant.
Possible areas include:
This is a hypothesis, not a confirmed root cause. A single successful recovery does not establish that the workaround is reliable.
Expected behavior
Codex Desktop should authenticate reliably after account sign-out and sign-in, regardless of whether another ChatGPT account was previously authenticated in the browser.
When token exchange fails, the client should expose a more precise diagnostic error and recover cleanly on the next attempt.
Request
Could the Codex team investigate intermittent OAuth token exchange failures involving browser login state and multi-account transitions on Windows Desktop?
In particular, why does signing out of ChatGPT Web — without clearing cookies — allow a previously failing Codex Desktop authorization to complete?
SAR-December5 commentedon Oct 21, 2026
Additional reproduction details: Clash Party / Windows Desktop 26.1013.4894.0
I am experiencing the same intermittent login failure on Windows 11 x64 (OS build 10.0.26200.0) with Codex Desktop package
OpenAI.Codex 26.1013.4894.0.Observed errors
token_exchange_failed:error sending request for url (https://auth.openai.com/oauth/token)workspace routing discovery failed/workspace routing discovery timed outThe UI alternates between these errors across retry attempts. ChatGPT login in the browser works, but Codex Desktop does not complete login reliably.
Proxy and connectivity checks
7890, SOCKS7891, and HTTP7892; the Windows system proxy is enabled at127.0.0.1:7890.auth.openai.com:443matchingDomainKeyword(openai)and routing through a proxy group to a Japan node (notDIRECT).Test-NetConnection 127.0.0.1 -Port 7892succeeds.127.0.0.1:7892tohttps://auth.openai.com/oauth/tokenreturns HTTP400with a JSONinvalid_valueerror forgrant_type=test. This confirms that this test request reaches the OAuth endpoint through that proxy; it does not prove that Codex's own token exchange succeeds.403challenge, but the OAuth POST above returned the expected API JSON error.HTTP_PROXYandHTTPS_PROXYtohttp://127.0.0.1:7890, addedALL_PROXYandNO_PROXY, restarted Windows, and also tried Clash Party's Global mode. The issue persists.127.0.0.1:7890, but its .NET OAuth probes still timed out. These probes are not the Codex application's own requests.I have not confirmed a root cause. The results suggest that basic OAuth endpoint connectivity through the local proxy works for a simple test request, while the desktop application's actual token exchange and/or subsequent workspace routing initialization still fails.
Could the team advise what additional sanitized logs or diagnostics would help determine whether this is a Windows desktop regression, proxy/environment inheritance issue, or workspace-routing service problem?