Tried deleting everything as ChatGPT advises and still facing the same issue since yesterday.
This is my environment:
Xcode Codex OAuth login completes successfully and browser shows “Signed in to Codex”, but Xcode immediately returns to “Not Signed In” and shows “Requires Eligible Account or API Key”.
Terminal Codex works with v0.137.0.
Xcode Codex account validation fails after successful OAuth callback.
Xcode version: 26.4 / 17E192.
I’m experiencing the same authentication issue with Codex in Xcode and wanted to share my setup and a temporary workaround that works for me.
Account
ChatGPT Pro (recently upgraded from Plus to Pro)
Environment
macOS 26.5.1 (25F80)
Xcode 26.5 (17F42)
Xcode automatically installs Codex 0.129.0-alpha.9 from Settings
Issue
In Xcode → Settings → Intelligence → Codex → Sign in with ChatGPT account:
A browser window opens for authentication.
I sign in successfully.
The browser shows:
“Signed in to Codex. You may now close this page.”
I close the browser window and return to Xcode.
Xcode still shows “Not signed in”.
I have tried:
Safari
Chrome
Clearing browser cache and cookies related to ChatGPT/OpenAI
Removing related entries from Keychain Access on my Mac and signing in again
None of these resolved the issue.
Temporary Workaround
I found a workaround from this GitHub issue:
Codex 0.129.0-alpha.9 breaks Xcode Coding Assistant with decode error #23109
Instead of using the version that Xcode installs automatically (0.129.0-alpha.9), I manually installed Codex 0.120.0.
I also tested:
0.133.0
0.139.0
but only 0.120.0 worked for me.
The downside is that GPT-5.5 is not available in Codex 0.120.0, so I am currently using GPT-5.4.
I’ve been waiting a couple of days for a fix, and so far this is the only workaround that has worked for me. Hopefully it helps others who are seeing the same behavior.
Codex itself was able to find a workaround for this issue as it seems to be still present:
In Xcode → Settings → Intelligence, install and enable the Codex coding-agent component. Select its TOML/configuration-file authentication option. This creates:
Hi @Peter.wong, thanks for flagging this. I found a newer report of this sign-in problem working again on stable Xcode 27. Could you try to update Xcode and its Codex agent, then sign in again under Settings > Intelligence > Codex, and let me know how it goes! If it still leaves you signed out, try ‘Sign In With a ChatGPT Device Code’ if that option is available.