Claude OAuth Not Working — 401 Error
Claude OAuth token expired or invalid. How to re-authenticate.
⚠️ The Problem
401 invalid bearer token
Provider anthropic is treating OAuth as API key
``
Other providers (OpenAI, etc.) still work fine.🔍 Why This Happens
✅ The Fix
Re-authenticate with Claude using OAuth:
openclaw auth add anthropicWhen prompted, choose the OAuth flow (opens browser).
If that doesn't work, try removing the old auth first:
openclaw auth remove anthropicopenclaw auth add anthropicVerify the auth is working:
openclaw models status --probeCheck what auth type is stored:
openclaw config get authIf it shows api_key but you want OAuth, the auth flow might not be detecting OAuth correctly. Try the OAuth flow explicitly.
🔥 Your AI should run your business, not just answer questions.
We'll show you how.$97/mo (going to $197 soon)
📋 Quick Commands
| Command | Description |
|---|---|
| openclaw auth add anthropic | Re-authenticate with Claude |
| openclaw auth remove anthropic | Remove old auth |
| openclaw models status --probe | Test if auth works |
Related Issues
📚 You Might Also Like
Best AI Assistants 2026: The Definitive Ranking for Power Users
I've tested every major AI assistant — ChatGPT, Claude, Gemini, and more. Here's my honest ranking of what actually works for people who want an AI that does things, not just talks.
How to Use Claude API: Complete Beginner's Guide
Step-by-step guide to getting started with Anthropic's Claude API. From getting your API key to making your first call to building with OpenClaw.
OpenClaw vs Claude
Same brain, but it can actually do things
AI Assistant for Students
Study smarter, not harder
🐙 Your AI should run your business.
Weekly live builds + template vault. We'll show you how to make AI actually work.$97/mo (going to $197 soon)
Join Vibe Combinator →