Free resource
OmniRoute: How to Run Claude Code for Free, Tested Step by Step
OmniRoute is a small program that runs on your computer, sits between Claude Code and the internet, and sends your prompts to free models through providers like OpenRouter, hopping to the next one when a free plan runs dry. I tested it myself, and here is the honest part up front: the model answering was Xiaomi's MiMo, not Claude. Use it to practice and build your own projects, never for client or private work.
What OmniRoute actually does (read this first)
Claude Code normally talks straight to Anthropic, and you pay for every message. OmniRoute is a small program that runs on your own computer and sits between Claude Code and the internet. Instead of sending your messages to Anthropic, it can send them to other AI companies that have free plans. When one free plan runs out of gas for the day, OmniRoute automatically hops to the next one. That is how people are running Claude Code "for free."
The honest truth nobody tells you: the free version is not Claude answering you. When I tested this myself, the model actually doing the work was Xiaomi's MiMo, a free Chinese model, even though Claude Code's screen still said "Claude." Free models are slower, weaker, and sometimes hand back an empty answer.
So here is the rule: this is great for practice, learning, and building throwaway stuff at 2am without watching a meter. Do not run client work or anything private through it. Your messages pass through other companies' free servers, and free servers usually get to keep and train on what you send. Use it on your own projects only. Okay, here is the whole thing, start to finish.
Before you start
- Node.js installed (version 22 or 24). If you can run
node --versionand see a number, you are good. - A free OpenRouter account. We make one in Step 3. No credit card needed.
- Claude Code already installed and working.
Step 1 and 2: Install it and turn it on
Open your terminal and paste this one line:
npm install -g omniroute
Give it a minute. That puts the omniroute command on your computer. Now start it:
omniroute
You will see a little logo and a line that says "OmniRoute is running!" with a web address:
Dashboard: http://localhost:20128
API Base: http://localhost:20128/v1
Leave this terminal window open. OmniRoute only works while it is running. Closing the window turns it off. Tip: you can also just tell Claude Code "open the OmniRoute dashboard" and it will pop it open for you.
Step 3 and 4: Get an OpenRouter key, add it to OmniRoute
OpenRouter is like a giant vending machine of AI models. One free key gives you access to hundreds of them, including free ones. It is the easiest single provider to start with.
- Go to openrouter.ai and make a free account.
- Click your profile, go to Keys, and create a new key. It looks like
sk-or-v1-xxxxxxxx. Copy it.
Now hand that key to OmniRoute:
- In your browser, open http://localhost:20128 (the dashboard).
- Open the side menu and click Providers.
- Type OpenRouter in the search, scroll to the bottom, and click Add.
- Paste your OpenRouter key into the box.
- The important part: flip on the "free only" toggle. That tells OmniRoute to only use models that cost nothing.
- Click Save.
Done. OmniRoute now has a menu of free models to pull from.
Step 5 and 6: Make your OmniRoute key, then dodge the trap
Claude Code needs a password to talk to OmniRoute. That is a separate key you make inside OmniRoute, not the OpenRouter one.
- In the dashboard, go to Endpoints (or "API Keys").
- Click Create key and copy it. It looks like
sk-c27997f110d15f31. Keep it private; if it ever leaks, just delete it and make a new one.
Now the trap that gets almost everyone. If you are logged into your normal Claude.ai account, Claude Code ignores OmniRoute completely and quietly uses your paid account instead. You would swear it is free while it is actually billing you. Fix it. Inside Claude Code, type:
/logout
When it asks, choose to use the API key instead of claude.ai. When you are done and want your normal Claude back, just run /login again. Nothing is broken. You are only switching which door it uses.
Step 7: Point Claude Code at OmniRoute
Close Claude Code. Then open a fresh, throwaway folder and start it with these settings. Swap in your OmniRoute key from Step 5:
cd /tmp && mkdir -p omni-demo && cd omni-demo
ANTHROPIC_BASE_URL=http://localhost:20128/v1 \
ANTHROPIC_API_KEY=YOUR_OMNIROUTE_KEY \
ANTHROPIC_MODEL=auto/coding:free \
ANTHROPIC_SMALL_FAST_MODEL=auto/fast \
claude
What each line means in plain English:
- ANTHROPIC_BASE_URL: "Send my messages to OmniRoute, not Anthropic." This is the actual switch.
- ANTHROPIC_API_KEY: your OmniRoute password from Step 5.
- ANTHROPIC_MODEL=auto/coding:free: "Use the free coding models." Without this, Claude Code asks for paid Opus by default and it breaks.
- ANTHROPIC_SMALL_FAST_MODEL=auto/fast: Claude Code also fires little background helper calls. This keeps those free too.
When it boots, the top of the window will now say auto/coding:free instead of Opus. That means it worked. Type something small to test it, like build a snake game in one html file, and watch the OmniRoute dashboard light up. One more safety note: those settings only live inside that one terminal window. Close it and your normal Claude Code is exactly as it was. Nothing permanent changed.
Step 8: Prove it is really routing (optional but cool)
Want proof it is using OmniRoute and not Anthropic? Run this, with your OmniRoute key dropped in:
curl -s http://localhost:20128/v1/models -H "Authorization: Bearer YOUR_OMNIROUTE_KEY"
If you get a big list of models back, it is live. When I ran this I got 129 models. If the list is empty, no provider is connected yet, so go back to Step 4.
How to know what model is REALLY running
This part is sneaky, so pay attention. There are three places to look, and two of them lie:
- Claude Code's screen shows
auto/coding:free. That is just the nickname you asked for, not the real model. - Asking the AI "what model are you" usually just makes it repeat the nickname. It genuinely does not know.
- The OmniRoute dashboard, Logs tab. This one is the truth. It shows the real model that answered each message. When I checked, it said
mimo-auto, which is Xiaomi's MiMo.
So if you ever want to know who is actually reading your code, open the Logs tab. Nowhere else tells you straight.
The real limits (so you are not surprised)
- "Unlimited" is a stretch. OpenRouter's free plan is about 50 messages a day, then it slows you down. Adding $10 of credit bumps it to around 1,000 a day.
- To get closer to always-on, connect a few more free providers the same way, so OmniRoute has more places to hop when one runs dry. Easy free ones: Groq, Google AI Studio (Gemini free), and Cerebras.
- Quality is the trade. Everything free is MiMo, DeepSeek, or Gemini-Flash level. Good enough to learn and mess around. Not Claude Opus. If a build comes out messy or an answer comes back empty, that is the free model, not your setup.
- Free models get rate-limited a lot. A "429" error just means "too many requests, slow down." Totally normal, and it is exactly why the auto-hop feature exists.
Quick fixes
- It still says "Opus" and bills me: you did not log out of claude.ai. Redo Step 6.
- "model not found" error: try
ANTHROPIC_MODEL=auto/best-freeorauto/codinginstead. - Empty answers: the free model choked. Ask again, or add another provider like Groq.
- The models list is empty: no provider connected. Redo Step 4.
- Dashboard will not open: OmniRoute is not running. Run
omnirouteagain.
Bottom line, and where to go next
OmniRoute is a real, clever tool. It genuinely lets you keep coding after you hit your Claude limit, for free, by relay-racing across other companies' free models. Just go in with your eyes open: it is free models pretending to be Claude, not Claude itself, and it is for your own projects, never client or private work. Use it to practice, to learn, to build throwaway stuff. That is exactly what it is good for.
When you are ready to do the real work well, the smart move is spending less on the paid models, not dodging them. The Save Tokens in Claude Code guide on this page cuts your bill without swapping in weaker models, and the Fable 5 YES Playbook shows how to make the most powerful model pay for itself. Want the prompts, the routing setups, and a community shipping this stuff daily? Join AI Autopilot Academy.