Getting started with the Claude API takes about five minutes. Here is the complete setup sequence for 2026.
Step 1 — Create an Anthropic account
Go to console.anthropic.com and sign up with an email address or Google account. No credit card is required to create an account.
Step 2 — Generate an API key
Inside the Console, navigate to Settings → API Keys → Create Key. Give the key a name (e.g. dev-local), copy it immediately — Anthropic shows it only once. Store it in a password manager or your shell's environment file:
export ANTHROPIC_API_KEY="sk-ant-api03-..."
Never hardcode the key in source files or commit it to git.
Step 3 — Add billing (required for production use)
New accounts receive a small free-tier credit (sufficient for testing). For production, go to Settings → Billing → Add payment method. Usage is billed monthly.
A successful response returns JSON with a content array. If you see 401 authentication_error, the key was not passed correctly.
Usage tiers and rate limits
Anthropic automatically upgrades your account tier as you spend. Tier 1 (≥$0 usage) starts with conservative limits; Tier 4 unlocks the highest throughput. See the rate-limits guide for full numbers. Estimate costs before scaling with the Claude Cost Calculator.
Organisation keys vs personal keys
For team environments, create Organisation API keys under Settings → Organisation → API Keys. These are scoped to the organisation billing account, not your personal account — easier to rotate and audit.
Frequently asked questions
Is there a free trial for the Claude API?
Anthropic provides a small credit on new accounts so you can test without adding a card. The amount is shown in the Console billing section. Once exhausted, production use requires a payment method.
How do I rotate my Claude API key?
In the Anthropic Console, create a new key, update all services to use it, then delete the old key. There is no in-place rotation — always create before deleting to avoid downtime.
What happens if I accidentally expose my API key?
Delete the key immediately in console.anthropic.com, then create a new one. API keys are bearer tokens — anyone who holds one can make API calls billed to your account. Check your billing dashboard for unexpected charges.
Can I use the same API key in multiple projects?
Yes, but it is better practice to create separate keys per project so you can revoke a single key without affecting others. Each key appears as a separate row in the Console with its own last-used timestamp.