# Anthropic API Keys vs OAuth Tokens: What OpenClaw Users Need to Know
**The #1 setup mistake that breaks your OpenClaw account switching**
If you’ve ever wondered why your Anthropic account isn’t working with OpenClaw even though you *know* you have a Max subscription, you’re not alone. The confusion between API keys and OAuth tokens trips up almost everyone.
## The Two Types of Anthropic Credentials
### API Keys (`sk-ant-api03-…`)
These are **pay-as-you-go credits**. You:
– Create them at [console.anthropic.com](https://console.anthropic.com) under API Keys
– Load credits manually ($5, $20, whatever)
– Pay per token used
– Run out when credits hit zero
**Good for:** Testing, low-volume usage, one-off scripts
### OAuth Tokens (`sk-ant-oat01-…`)
These are **subscription tokens**. You:
– Get them by authenticating through the Anthropic CLI
– They’re tied to your Max subscription ($20/mo, $100/mo, etc.)
– Have rate limits but don’t “run out” mid-month
– Auto-refresh and stay connected to your subscription
**Good for:** OpenClaw, Claude Code, daily AI assistant usage
## The Problem
When you grab a key from the Anthropic Console and paste it into OpenClaw, you’re probably grabbing an **API key**. That works… until your credits run out. Then you get a “billing” error and wonder why your $100/month Max subscription isn’t being used.
**The subscription and the API credits are separate billing systems!**
Your Max subscription gives you rate-limited access through OAuth tokens. Your API credits are a separate pay-as-you-go balance.
## The Fix: Get Your OAuth Token
Instead of copying keys from the console, use the OpenClaw auth flow:
“`bash
openclaw models auth setup-token
“`
This runs the Anthropic CLI authentication, opens a browser, and pulls your **OAuth token** that’s connected to your actual subscription.
### For Multiple Accounts
If you have multiple Anthropic accounts (personal + business), you can add them with different names:
“`bash
openclaw models auth add
“`
Then set up your failover order:
“`bash
openclaw models auth order set anthropic personal-sub,business-sub,api-credits
“`
Now OpenClaw will automatically switch between accounts when one hits rate limits!
## How to Tell Which You Have
Look at the prefix of your key:
– `sk-ant-api03-…` = API key (credits-based) ❌ Not what you want for daily use
– `sk-ant-oat01-…` = OAuth token (subscription-based) ✅ This is the good stuff
## Quick Checklist
1. ✅ Do you have a Max subscription? Check at [console.anthropic.com/settings/plans](https://console.anthropic.com/settings/plans)
2. ✅ Run `openclaw models auth setup-token` to get the OAuth token
3. ✅ Check `openclaw models status` to verify the token type
4. ✅ Set up failover with multiple accounts if you have them
## Still Confused?
The [OpenClaw docs](https://docs.openclaw.ai) have more details on multi-account setup. Or grab our ebook [How To Open Claw For Dummies](https://howtoopenclawfordummies.com) for the complete walkthrough with screenshots!
—
*Having OpenClaw issues? Drop by the [Discord community](https://discord.com/invite/clawd) — we’ve all been there.*