Codex mobile won't connect to desktop
Stuck on "Waiting for desktop", or your machine shows offline in the ChatGPT app. The proxy cause with a working command, plus the open issues covering each variant.
Waiting for desktop…
Could not connect to Codex Desktop
Offline · Last seen 18 hours agoYou scan the QR code on the Codex desktop app, the ChatGPT mobile app opens, and then nothing happens — the desktop never shows an approval prompt and the phone waits forever.
How the pairing actually works#
Knowing the moving parts makes the failure legible:
ChatGPT mobile app
│ (via OpenAI backend)
▼
OpenAI backend ◄── registers as "online" ── remote-control daemon
│ (on your desktop)
▼
Codex DesktopThe critical detail: your desktop registers itself with OpenAI's backend through a headless remote-control daemon. The QR code is only a handshake token. If that daemon can't reach the backend, the backend's environment list stays empty — and your phone shows "waiting for desktop" forever, even though the desktop app is plainly running and showing a QR code.
That's why the QR screen looks fine while nothing works. The QR UI and the daemon are independent.
The one cause with a confirmed fix: proxy configuration#
From #22851. If you run a local proxy — common in corporate networks, and near-universal for developers in some regions — the remote-control daemon does not inherit your machine's proxy settings. It can't reach the backend, so it never registers.
The reported environment was macOS on Apple Silicon, Codex Desktop 26.513.20950, CLI 0.131.0-alpha.9, with a proxy on 127.0.0.1:7897.
Stop the existing daemon:
pkill -f '/Users/.*/.codex/packages/standalone/current/codex .*remote_control'
pkill -f 'app-server daemon pid-update-loop'Restart it with proxy variables set explicitly:
HTTP_PROXY=http://127.0.0.1:7897 \
HTTPS_PROXY=http://127.0.0.1:7897 \
ALL_PROXY=http://127.0.0.1:7897 \
http_proxy=http://127.0.0.1:7897 \
https_proxy=http://127.0.0.1:7897 \
all_proxy=http://127.0.0.1:7897 \
NO_PROXY=localhost,127.0.0.1,::1 \
no_proxy=localhost,127.0.0.1,::1 \
/Applications/Codex.app/Contents/Resources/codex remote-controlSubstitute your own proxy address and port. Both upper and lower case variants are set deliberately — different libraries in the stack read different ones, and setting only HTTPS_PROXY is a common half-fix that doesn't work.
NO_PROXY for loopback matters too: without it, local traffic gets routed through the proxy and breaks in a different way.
Once the daemon reaches the backend, your machine appears as an online environment and the phone connects.
Find your variant#
If proxy isn't your problem, match the symptom:
| Symptom | Platform | Issue |
|---|---|---|
| Stuck on "Waiting for desktop", no prompt on desktop | Android → Windows | #22733 |
| Cannot connect at all | Android → Windows | #25595 |
| Desktop shows offline, Reconnect does nothing | iOS → macOS | #22898 |
| Pairing stuck after account selection | Android | #23117 |
| QR scans, but mobile just says "follow desktop instructions" | Any | #23049 |
| Authorized, still "waiting for desktop" | Any | #22715 |
The offline / Reconnect does nothing variant (#22898) has no identified root cause. The reporter suspected stale pairing, relay discovery or device registration, and noted that Reconnect gives no loading state or error at all — so there's nothing to diagnose from the UI. If that's you, restarting the desktop app to force a fresh registration is the only lever available.
General recovery#
In order of how often it helps:
- Check for a proxy or VPN. Even a system-wide VPN can produce this. Apply the fix above.
- Restart the remote-control daemon, not just the app — the daemon is what registers you.
- Same account on both devices. Obvious, and it does happen.
- Update both the desktop app and the ChatGPT mobile app.
- Check corporate network egress. The daemon needs to reach OpenAI's backend; a firewall that permits browser traffic may still block it.
- Re-pair from scratch rather than tapping Reconnect, which is reported as doing nothing visible.
An alternative that avoids all of this#
If what you actually want is your agent, on your phone, this pairing flow is not the only route. T3 Code serves its own web UI directly from your machine, so you connect over Tailscale or an SSH tunnel with no vendor backend in the path:
npx t3 serve --tailscale-serveScan the QR it prints. Because nothing registers with a third-party backend, the entire class of "desktop shows offline" failures cannot occur — the trade-off being that you set up the network yourself. Phone and tablet guide →
FAQ#
Why does Codex mobile say "Waiting for desktop"?#
Your desktop registers with OpenAI's backend through a headless remote-control daemon, separately from the QR code UI. If that daemon can't reach the backend, the backend never lists your machine and the phone waits indefinitely — even though the desktop looks fine.
How do I fix Codex mobile not connecting when I use a proxy?#
The remote-control daemon doesn't inherit your system proxy settings. Kill it and relaunch codex remote-control with HTTP_PROXY, HTTPS_PROXY, ALL_PROXY and their lowercase variants set explicitly, plus NO_PROXY for loopback addresses.
Codex desktop is running but shows offline on my phone — why?#
A known open issue, reported on iOS with macOS desktops. Reconnect produces no visible response and no root cause has been identified. Restarting the desktop app to force fresh registration is the only available workaround.
Does the Reconnect button in the ChatGPT app work?#
It has been reported as doing nothing — no loading state, no error, no reconnection. Re-pairing from scratch is more reliable than tapping it.
Is there a way to use a coding agent from my phone without this pairing?#
Yes. T3 Code serves a web UI from your own machine, reachable over Tailscale or an SSH tunnel with no third-party backend involved, which avoids this entire class of registration failures.