# Claude Code on anyrouter.dev

> Claude Code on anyrouter.dev. cli.sh then anyr claude. ANTHROPIC_BASE_URL=https://anyrouter.dev/api. Free has no monthly credits; Go is $2/mo ($2.63 charged) → $4.

- Date: September 1, 2026
- Category: guides
- HTML: https://anyrouter.dev/blog/claude-code-anyrouter-dev

## Point Claude Code at anyrouter.dev

Claude Code on this product is [anyrouter.dev](https://anyrouter.dev).

The Anthropic-compatible base URL is `https://anyrouter.dev/api` (no `/v1` on that env var. Claude Code appends `/v1/messages`). The OpenAI-compatible API is `https://anyrouter.dev/api/v1`.

## Fast path: cli.sh + anyr claude

```bash
curl -fsSL https://anyrouter.dev/cli.sh | bash
anyr login
anyr claude
```

Full reference: [anyrouter.dev/docs/cli/claude-code](https://anyrouter.dev/docs/cli/claude-code).

## Manual env (only if you skip anyr)

```bash
export ANTHROPIC_BASE_URL="https://anyrouter.dev/api"
export ANTHROPIC_API_KEY="sk-ar-your-key"
claude
```

_Claude Code on anyrouter.dev._

Create the key in the [dashboard](https://dash.anyrouter.dev/keys) first. Every AnyRouter key starts with `sk-ar-`.

## BYOK and anyr

Attach your own provider keys under [Dashboard → BYOK](https://dash.anyrouter.dev/byok). BYOK traffic has no AnyRouter markup. `anyr claude` still talks to `https://anyrouter.dev/api`.

To get Go without a card, [donate an eligible BYOK key](/blog/donate-a-key-for-go).

## Free has no monthly credits

The **Free** plan includes **no monthly credits**. Free callers get a 5-request lifetime trial on `anyrouter/free` and `:free` models; after that they need Go or higher, with no daily cap. Paid models return 402 without credits or a subscription.

**Go** is **$2/mo** (Polar charges **$2.63**) → **$4** credits. Or [donate an eligible BYOK key](/blog/donate-a-key-for-go).

Go rate limits: **60 req/min** and **3,000 req per rolling 5 hours**. Older posts that say $1 Go are wrong, see [Free vs Go](/blog/anyrouter-pricing-free-vs-go).
