Troubleshooting Codex in VS Code: common errors and fixes
Even with a smooth installation, Codex in VS Code can throw errors. From sign-in loops to approval prompts that never stick, these issues are common—and solvable. This guide covers the top problems developers face, why they happen, and how to fix them.
Sign-in problems
Symptom: stuck in a login loop
- Codex keeps asking you to sign in, even after authorizing in the browser.
Fix:
- Fully sign out from VS Code (
Accounts → Sign Out
). - Clear cached credentials: open the Command Palette →
Developer: Open Authentication Storage
. - Retry sign-in with your ChatGPT account.
If you prefer API keys:
- Go to Settings → Extensions → Codex → API Key.
- Paste your key and reload VS Code.
Symptom: “Account not supported”
- Happens when using a free ChatGPT account.
Fix: Upgrade to Plus, Pro, Team, Edu, or Enterprise. Only these plans support Codex integration.
Approval issues
Symptom: Codex asks for approval on every edit
- Even simple local changes trigger confirmation.
Fix:
- Check the active mode. If you’re in Chat mode, Codex can’t apply edits.
- Switch to Agent mode from the sidebar.
- If defaults keep resetting, edit
~/.codex/config.toml
to setdefault_approval = "auto"
.
Symptom: Full Access too permissive
- Codex runs commands without any prompts.
Fix:
- Drop back to Auto or Read Only.
- Treat Full Access as sandbox-only (see our approval modes guide).
Windows and WSL quirks
Symptom: Codex doesn’t run commands on Windows
- Native Windows support is still experimental.
Fix:
- Install WSL2 with Ubuntu.
- Run Codex inside the WSL environment.
- Use
code .
from WSL to launch VS Code connected to the subsystem.
Symptom: Path or shell errors
- Codex can’t find your Node or shell executables.
Fix:
- Verify Node installation inside WSL (
node -v
). - Check that your PATH includes
/usr/local/bin
.
Proxy and firewall errors
Symptom: “Network request failed”
- Usually caused by corporate proxies or firewalls.
Fix:
- In VS Code, set:
"http.proxy": "http://proxy.company.com:8080"
- Ensure Codex-related domains are whitelisted.
- Restart VS Code.
Symptom: SSL certificate errors
- Codex fails to connect due to self-signed or intercepted certificates.
Fix:
- Import the corporate certificate into VS Code.
- Or bypass SSL only if absolutely necessary (not recommended).
Performance hiccups
Symptom: Codex feels slow or unresponsive
Fix:
- Check if you’re accidentally running in cloud mode for short tasks. Switch back to local.
- Close heavy extensions competing for resources.
- Update VS Code and the Codex extension to the latest version.
When all else fails
- Uninstall the Codex extension.
- Delete its config directory in
~/.vscode/extensions/openai.chatgpt-*
. - Reinstall from the Marketplace.
How this article fits the Codex cluster
This troubleshooting guide complements:
Together, they ensure you don’t just install Codex—you keep it running smoothly.
Conclusion
Most Codex errors in VS Code aren’t dealbreakers. They’re configuration hiccups, platform quirks, or missing permissions. Once you know the fixes, you can:
- Sign in cleanly
- Run tasks without endless prompts
- Use Codex on Windows via WSL
- Handle proxies and firewalls confidently
The result: a stable, reliable Codex setup inside VS Code, ready for real work.