9Router
Unlimited FREE AI coding. Connect Claude Code, Codex, Cursor, Cline, Copilot, Antigravity to FREE Claude/GPT/Gemini via 40+ providers. Auto-fallback, RTK -40% tokens, never hit limits.
Last verified:
What is 9Router?
9Router is a free, open-source local AI proxy that connects AI coding tools like Claude Code, Cursor, Codex, Cline, Copilot, and Antigravity to 40+ AI providers and 100+ models. It implements an intelligent 3-tier fallback routing system that automatically switches between subscription, cheap, and free providers so you never hit rate limits mid-coding session. The tool runs locally on port 20128 and exposes an OpenAI-compatible API endpoint that any CLI tool can point to.
Key features include RTK Token Saver which compresses tool outputs (git diff, grep, ls, tree) to save 20-40% input tokens per request, Caveman Mode which reduces output tokens by up to 65%, real-time quota tracking with reset countdowns, format translation between OpenAI/Claude/Gemini/Cursor/Kiro/Vertex protocols, multi-account support with round-robin load balancing, auto token refresh for OAuth providers, custom model combos, request logging, cloud sync across devices, and usage analytics. The dashboard at localhost:20128 provides real-time quota tracking, usage analytics, and combo management.
9Router is designed for developers and AI coding enthusiasts who use CLI-based AI tools and want to maximize their AI subscriptions while minimizing costs. It's ideal for developers on tight budgets who need free AI access, professionals who need 24/7 uninterrupted coding without rate limit interruptions, and anyone with existing subscriptions who wants to maximize their value before hitting limits. The tool supports Windows, macOS, and Linux via npm installation or Docker deployment.
9Router pricing
Pricing model: Freemium
9Router software is 100% free forever under MIT License and never charges users anything. You only pay providers directly for their services. Free tier includes Kiro AI (unlimited free Claude 4.5 + GLM-5 + MiniMax via OAuth), OpenCode Free (no auth required, unlimited), and Vertex AI ($300 free credits for new GCP accounts for 90 days). Cheap tier includes GLM-5.1/GLM-4.7 at $0.6 per 1M tokens with daily 10AM reset, MiniMax M2.7 at $0.2 per 1M tokens with 5-hour rolling reset, and Kimi K2.5 at $9/month flat for 10M tokens. Subscription tier includes Claude Code Pro/Max at $20-200/month with 5-hour + weekly quota reset, Codex Plus/Pro at $20-200/month, GitHub Copilot at $10-19/month, and Cursor IDE at $20/month. The dashboard cost display shows estimated savings, not actual billing.
9Router pros
- 100% free and open-source under MIT License, never charges users anything
- Connects to 40+ AI providers and 100+ models through one interface
- Smart 3-tier fallback automatically switches subscription → cheap → free
- RTK Token Saver reduces input tokens by 20-40% per request
- Caveman Mode saves up to 65% output tokens with terse technical responses
- Never hit rate limits mid-coding session with automatic fallback
- Real-time quota tracking shows token count and reset countdown
- Works with all major AI coding tools: Claude Code, Cursor, Codex, Cline, Copilot
- OpenAI-compatible API endpoint at localhost:20128/v1 works with any CLI tool
- Multi-account support with round-robin load balancing per provider
- OAuth tokens automatically refresh without manual re-authentication
- Custom model combos let you create unlimited fallback chains
- Cloud sync keeps providers, combos, and settings consistent across devices
- Format translation between OpenAI, Claude, Gemini, Cursor, Kiro, Vertex protocols
- Deploy locally, on VPS, via Docker, or on Cloudflare Workers
- Dashboard provides usage analytics with cost tracking and monthly reports
- Request logging with debug mode for troubleshooting integration issues
9Router cons
- Requires Node.js 20+ installation and npm knowledge for setup
- Runs locally so not accessible from other devices without VPS deployment
- Free providers (Kiro, OpenCode) may have undisclosed reliability risks
- Some free tiers like iFlow and Qwen discontinued in 2026, reducing options
- Dashboard cost display can confuse users into thinking they are being charged
- Windows users must use 127.0.0.1 instead of localhost for OpenClaw
- OAuth providers require initial setup and authentication configuration
- Custom combo creation requires understanding of provider tier hierarchy
- No official mobile app or web-based interface beyond localhost dashboard
- MIT license means no commercial support or SLA guarantees
Frequently asked questions about 9Router
Why does my dashboard show high costs?
The dashboard tracks token usage and displays estimated costs as if you were using paid APIs directly. This is not actual billing - it is a reference to show how much you are saving by using free models or existing subscriptions. For example, if the dashboard shows $290 total cost while using Kiro AI (FREE unlimited), your actual cost is $0.00. The $290 represents the amount you saved by using free models instead of paid APIs. Think of it as a savings tracker showing your usage patterns and optimization opportunities.
Will I be charged by 9Router?
No. 9Router is free, open-source software under MIT License that runs on your own computer and never charges you anything. You only pay subscription providers (Claude Code $20/mo, Codex $20-200/mo) directly on their websites, or cheap providers (GLM, MiniMax) directly. 9Router itself never charges anything, ever. It is a local proxy/router that does not have your credit card, cannot send invoices, and has no billing system.
Are the FREE providers really unlimited?
Yes! The current FREE providers are genuinely free with no hidden charges. Kiro AI offers free unlimited Claude 4.5 + GLM-5 + MiniMax via AWS Builder ID / Google / GitHub OAuth. OpenCode Free is a no-auth passthrough proxy with models auto-fetched from opencode.ai/zen/v1/models. Vertex AI provides $300 free credits for new Google Cloud accounts for 90 days. Note that iFlow and Qwen Code free tiers were discontinued in 2026, and Gemini CLI free tier may result in account bans when used with non-CLI tools.
How do I minimize my actual AI costs?
Use the free-first strategy: Start with a 100% free combo using Kiro AI (Claude 4.5 free unlimited), GLM-5 free via Kiro, and Vertex AI ($300 free credits) for $0/month cost. Add cheap backup only if needed like GLM at $0.6/1M tokens, paying only for what you actually use. Use subscription providers last, only if you already have them, since 9Router helps maximize their value through quota tracking. Most users can operate at $0/month using only free tiers with RTK saving an additional 20-40% tokens.
What if my usage suddenly spikes during a coding sprint?
9Router's smart fallback prevents surprise charges. When subscription hits its limit, it auto-fallbacks to the cheap tier. When the cheap tier gets expensive, it auto-fallbacks to the free tier. You never stop coding and costs remain predictable. You are in control because you can set spending limits per provider in the dashboard, and 9Router respects them. This is better than without 9Router where you would hit rate limits and work stops, or accidentally rack up huge API bills.
How do I install and set up 9Router?
Install globally by running 'npm install -g 9router' then execute '9router'. The dashboard opens at http://localhost:20128. Connect a FREE provider like Kiro AI (free Claude unlimited) or OpenCode Free (no auth) via Dashboard → Providers → Connect. In your CLI tool settings, set Endpoint to http://localhost:20128/v1, copy the API Key from dashboard, and select a model like kr/claude-sonnet-4.5. That's it - start coding with FREE AI models. Alternatively, run from source by cloning the GitHub repo, copying .env.example to .env, running npm install, then 'PORT=20128 NEXT_PUBLIC_BASE_URL=http://localhost:20128 npm run dev'.
What is RTK Token Saver and how does it work?
RTK Token Saver is a built-in feature that compresses tool outputs like git diff, grep, find, ls, tree, and log dumps before sending them to the LLM, saving 20-40% input tokens per request. It auto-detects by peeking the first 1KB of each tool_result and picks the right filter for git-diff, git-status, grep, find, ls, tree, dedup-log, smart-truncate, read-numbered, and search-list. It is safe by design because if a filter fails or makes output bigger, RTK silently keeps the original text and errors never break your request. It works across all formats because it runs before any format translation, and is default ON but can be toggled in Dashboard → Endpoint settings.
What is the 3-tier fallback system?
The smart 3-tier fallback automatically routes requests in priority order: Tier 1 is SUBSCRIPTION (Claude Code, Codex, GitHub Copilot), Tier 2 is CHEAP (GLM at $0.6/1M, MiniMax at $0.2/1M), and Tier 3 is FREE (Kiro, OpenCode Free, Vertex with $300 credits). When quota is exhausted on a higher tier, it automatically switches to the next tier with zero downtime. You create combos with this structure, for example: cc/claude-opus-4-6 as primary, then glm/glm-4.7 as cheap backup, then if/kimi-k2-thinking as free fallback. This ensures you never stop coding while minimizing costs.
Which AI coding tools are supported?
9Router works seamlessly with all major AI coding tools including Claude Code, OpenClaw, Codex, OpenCode, Cursor IDE, Antigravity, Cline, Continue, Droid, Roo, GitHub Copilot, and Kilo Code. Any tool that supports custom OpenAI endpoints can use 9Router by pointing to http://localhost:20128/v1 with the API key from the dashboard. The format translation feature ensures compatibility across OpenAI, Claude, Gemini, Cursor, Kiro, Vertex, Antigravity, Ollama, and OpenAI Responses protocols.