Skip to content
All use cases

Free coding agent

Run Claude Code on free models

Point Claude Code at anyrouter/free and it codes on whichever free model is answering, with no credit deduction.

What this is for

Trying a coding agent on a hobby repo should not need a paid plan with one vendor. You want a free model that fails over, and no daily cap.

How the request flows

Claude Code
AnyRouter
Free modelfirst candidate
Next free modelif first fails

Steps, then copy

  1. 1.Install the anyr CLI and sign in. Upgrade to Go ($2/mo) or donate a key to get paid-model access.
  2. 2.Run anyr claude --model anyrouter/free. Requests do not deduct credits.
  3. 3.Run anyr models to list catalog ids, and switch to anyrouter/auto or a pinned model when a task needs more.
anyr CLI
bash
curl -fsSL https://anyrouter.dev/setup.sh | bash
anyr claude --model anyrouter/free
Env wrapper
bash
export ANTHROPIC_BASE_URL="https://anyrouter.dev/api"
export ANTHROPIC_API_KEY="$ANYROUTER_API_KEY"
claude --model anyrouter/free

Ready to try it

The guide has the full walkthrough. Sign up if you still need a key.