[BUG] OAuth Authorize button returns 500 Internal Server Error — cannot login to Claude Code in VSCode
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
OAuth token expired in Claude Code (VSCode extension). When clicking the Authorize button on the OAuth page, the server returns a 500 Internal Server Error. Authentication never completes and Claude Code remains unusable.
The page briefly flashes "Build something great. You're all set up for Claude Code." before showing "Authorization failed — Internal server error", suggesting the flow partially completes on the browser side but fails on Anthropic's backend.
What Should Happen?
Clicking "Authorize" should complete the OAuth flow, return a token to Claude Code, and allow normal usage to resume.
Error Messages/Logs
Terminal:
API Error: 401 {"type":"error","error":{"type":"authentication_error","message":"OAuth token has expired. Please obtain a new token or refresh your existing token."}}
Please run /login
OAuth error: timeout of 15000ms exceeded
Browser console (all browsers: Chrome, Edge):
POST https://claude.ai/v1/oauth/eb81b55e-f1e4-4a57-bad1-92e8b1dd60bd/authorize 500 (Internal Server Error)
Failed to load resource: the server responded with a status of 405 ()
[REACT_QUERY_CLIENT] QueryClient error: a: Internal server error
at n (5741-e0df12e868d24a1c.js:1:95179)
at 5741-e0df12e868d24a1c.js:1:100054
at async Object.mutationFn (5741-e0df12e868d24a1c.js:1:100872)
Steps to Reproduce
- Use Claude Code in VSCode until OAuth token expires (~4 days)
- Claude Code prompts to re-authenticate with 401 error
- Run
/loginorclaude auth loginin terminal - Browser opens the OAuth authorize page at
https://claude.ai/oauth/authorize?code=true&client_id=9d1c250a-e61b-44d9-88ed-5944d1962f5e&... - Click the Authorize button
- Page shows "Authorization failed — Internal server error"
- Terminal shows
OAuth error: timeout of 15000ms exceeded
Workarounds attempted (all failed):
- Tried on Chrome, Edge (different browsers)
- Tried in Incognito mode
- Deleted
~/.claude.jsonand~/.claude/then retried - Logged out of claude.ai on browser then re-logged in before authorizing
- status.anthropic.com shows no incidents
Claude Model
Opus
Is this a regression?
Yes, this worked in a previous version
Last Working Version
Unknown — worked before token expiry (5 hours ago)
Claude Code Version
v2.1.76
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
PowerShell
Additional Information
The OAuth endpoint POST /v1/oauth/{session-id}/authorize is returning 500 on Anthropic's server side. This is not reproducible to a specific browser or local config — the error originates from Anthropic's backend. The issue blocks all Claude Code usage until re-authentication is possible.
21 Comments
"Claude Code welcome screen correctly identifies the account (Claude Pro, Opus 4.6) but any actual API call immediately returns 401. This suggests the session/token metadata is cached locally but the token itself is expired and cannot be refreshed due to the server-side 500 error on the authorize endpoint."
Same issue here.
same issue here
Yeah auth server is down for me too.
same issue. I can't log into my account.
Login is timing out. Sometimes I get http 500, sometimes the process completes but very late (>15 seconds).
same issue
Да, у всех так
Сервер компании упал
Ждем решения проблемы от разработчиков
Found 3 possible duplicate issues:
This issue will be automatically closed as a duplicate in 3 days.
🤖 Generated with Claude Code
Same here
Ha....
Same issue. Running Claude Code v2.1.92 on Mac. Max plan.
Even chat messages with the claude chat bot on the web ui (claude.ai) are not working for me either — even though I am logged in, able to navigate, and able to see chats.
I love how productive my productivity tool is making me this morning!
Claude Code v2.1.92 same issue
https://status.claude.com/incidents/vfjv5x6qkd4j
Если у человечества кончится инетрент они будут также удивлены как если у человечества кончится cloude code)))
same issue Claude Code v2.1.91
same
Seems like it is fixed now (at least for me)
Closing for now — inactive for too long. Please open a new issue if this is still relevant.
This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.