Free Setup Guide

How to Use Claude Code for Free with OmniRoute

One local server. 350+ AI providers. Auto-fallback when one runs dry. Zero API cost to start — no credit card needed. Pick your OS below and follow the steps.

Step 01

Install Node.js

Required before installing OmniRoute. v18 or higher.

Download and run the Windows installer from the official site:

ℹGet it from nodejs.org — pick the LTS version and run the installer.

Once installed, confirm it in PowerShell:

PowerShell
PS > node -v
PS > npm -v
Step 02

Install OmniRoute

Run once globally.

Open PowerShell and run:

PowerShell
PS > npm i -g omniroute
Step 03

Start the OmniRoute server

Keep this terminal open the entire time.

In the same PowerShell window, run:

PowerShell
PS > omniroute

Want it on a specific port instead? Use --port:

PowerShell
PS > omniroute --port 20200
⚠Do not close this window. OmniRoute must keep running in the background. Open a new PowerShell window for the next steps.

Then open your browser and go to:

Browser URL
http://localhost:20128/home
Step 04

Connect your AI providers

Go to Providers section in the web dashboard.

In the OmniRoute dashboard, click Providers in the left sidebar and add these:

AntigravityOAuth login
OllamaAPI key / local
OpenRouterAPI key
OpenCode ZenAPI key
SiliconFlowAPI key
Step 05

Create your combo

Combine all providers into one smart route.

In the dashboard → Combos → Create New Combo. Chain providers in this order and name it omni_combo:

Combo config
Antigravity   ← Priority 1 (OAuth, subscription-level)
    ↓
Ollama        ← Priority 2 (local, free)
    ↓
OpenRouter    ← Priority 3 (API key fallback)
    ↓
OpenCode Zen  ← Priority 4 (API key fallback)
    ↓
SiliconFlow   ← Priority 5 (final fallback)
    ↓
Model Name: omni_combo
ℹOmniRoute will automatically fall back to the next provider if one hits a rate limit or fails.
Step 06

Create an API key

This is your OmniRoute auth token.

Go to API Keys in the left sidebar → Generate a new key → Copy it. You'll use this as YOUR_TOKEN_HERE in the next step.

✓Generate one key per environment (e.g., "claude-code", "n8n", "dev"). Makes it easy to revoke individual tools later.
Step 07

Set environment variables

Open a NEW PowerShell window for this step.

Run these commands in a new PowerShell window (replace YOUR_TOKEN_HERE with your actual key):

PowerShell
$env:CLAUDE_CONFIG_DIR = "$HOME\.claude-omniroute"
$env:ANTHROPIC_BASE_URL = "http://localhost:20128"
$env:ANTHROPIC_AUTH_TOKEN = "YOUR_TOKEN_HERE"
$env:ANTHROPIC_API_KEY = ""
$env:ANTHROPIC_MODEL = "omni_combo"
CLAUDE_CONFIG_DIRSeparate Claude config so it doesn't conflict with your main Claude install
ANTHROPIC_BASE_URLRedirects Claude to your local OmniRoute server
ANTHROPIC_AUTH_TOKENYour OmniRoute API key (from Step 06)
ANTHROPIC_API_KEYCleared so Claude doesn't try to hit Anthropic directly
ANTHROPIC_MODELTells Claude to use your custom omni_combo
Step 08

Verify the configuration

Confirm all variables are set correctly.

In the same PowerShell window, run:

PowerShell
echo $env:CLAUDE_CONFIG_DIR
echo $env:ANTHROPIC_BASE_URL
echo $env:ANTHROPIC_MODEL

You should see something like:

Expected output
C:\Users\YOUR_USERNAME\.claude-omniroute
http://localhost:20128
omni_combo
Step 09 · Optional

Make settings permanent

So you don't have to re-run on every session.

To persist these variables permanently in Windows, run this in PowerShell (as Administrator):

PowerShell (Admin)
[System.Environment]::SetEnvironmentVariable("CLAUDE_CONFIG_DIR", "$HOME\.claude-omniroute", "User")
[System.Environment]::SetEnvironmentVariable("ANTHROPIC_BASE_URL", "http://localhost:20128", "User")
[System.Environment]::SetEnvironmentVariable("ANTHROPIC_AUTH_TOKEN", "YOUR_TOKEN_HERE", "User")
[System.Environment]::SetEnvironmentVariable("ANTHROPIC_API_KEY", "", "User")
[System.Environment]::SetEnvironmentVariable("ANTHROPIC_MODEL", "omni_combo", "User")
ℹAfter running, restart PowerShell for changes to take effect.
Step 10 · Final

Launch Claude Code

Run Claude through OmniRoute.

PowerShell
PS > claude

🎉 Claude Code → OmniRoute → omni_combo

Claude is now routing through your local OmniRoute server with auto-fallback across Antigravity → Ollama → OpenRouter → OpenCode Zen → SiliconFlow. Monitor usage at localhost:20128/home.

⚡ Quick setup

Already know what you're doing? Full flow in two PowerShell windows.

Window 1 — start server:

PowerShell — Window 1
npm i -g omniroute
omniroute

Window 2 — configure & run Claude:

PowerShell — Window 2
$env:CLAUDE_CONFIG_DIR = "$HOME\.claude-omniroute"
$env:ANTHROPIC_BASE_URL = "http://localhost:20128"
$env:ANTHROPIC_AUTH_TOKEN = "YOUR_TOKEN_HERE"
$env:ANTHROPIC_API_KEY = ""
$env:ANTHROPIC_MODEL = "omni_combo"
claude
⚠These are PowerShell commands. Don't mix syntax between Windows and macOS — switch tabs above if you're on the other OS.

Made for the OmniRoute community · MIT License · github.com/diegosouzapw/OmniRoute