9router — What is it?

9Router is an open-source AI coding router and token saver that connects various AI coding tools to multiple AI providers, optimizing token usage and providing fallback options to ensure continuous coding without hitting limits or incurring high costs.

⭐ 21,817 Stars 🍴 3,678 Forks JavaScript MIT Author: decolua
Source: Official README and linked documentation View on GitHub →

Why it matters

9Router is being discussed because its ability to address the pain points of subscription quotas, rate limits, and expensive APIs. It fills the gap by providing an efficient way to manage and save tokens across various AI providers, offering auto-fallback options, and supporting a wide range of AI coding tools.

Source: Official README and linked documentation

Core Features

RTK Token Saver

Auto-compresses tool_result content to save 20-40% tokens per request, optimizing token usage and reducing costs.

Source: Official README and linked documentation
Maximize Subscriptions

Tracks quota usage to ensure every bit of the subscription is used before it resets, maximizing the value of subscriptions.

Source: Official README and linked documentation
Auto Fallback

Automatically switches between subscription, cheap, and free AI models when limits are hit, ensuring continuous coding without downtime.

Source: Official README and linked documentation
Multi-account

Rounds-robin between accounts per provider to evenly distribute usage and avoid hitting individual account limits.

Source: Official README and linked documentation
Universal Compatibility

Works with a wide range of AI coding tools such as Claude Code, Codex, Cursor, Cline, and more, providing a direct integration experience.

Source: Official README and linked documentation

Architecture

The architecture of 9Router is inferred to be modular, with a clear separation of concerns. It likely employs design patterns such as the Proxy pattern for routing requests to different AI providers, and the Strategy pattern for managing different token-saving strategies. The data flow involves a central router handling requests from connected tools, which are then processed by various modules responsible for token management, provider communication, and fallback logic.

Source: Official repository tree and dependency files

Project Knowledge Graph

Knowledge graph: project (center) + core features (inner hexagons) + key dependencies (outer chips) @dnd-kit/core @dnd-kit/sortable@dnd-kit/sorta… @monaco-editor/react@monaco-editor… express http-proxy-middlewarehttp-proxy-mid… RTK Token Saver Maximize SubscriptionsMaximize Subscripti… Auto Fallback Multi-account Universal CompatibilityUniversal Compatibi… 9router Project Core feature Key dependency

Tech Stack

LanguageJavaScriptFrameworkNext.js for web dashboard, Express.js for server-side logic
@dnd-kit/core@dnd-kit/sortable@monaco-editor/reactexpresshttp-proxy-middlewarejosemarkedmonaco-editornextnode-forgeopenorareactreact-domreact-isrechartssql.jsundiciuuidzustand
Docker for containerization, likely deployed on a server or cloud platform
Source: Official repository tree and dependency files

Quick Start

npm install -g 9router 9router Dashboard opens at http://localhost:20128 Connect a FREE provider (no signup needed) Use in your CLI tool: Endpoint: http://localhost:20128, API Key: [copy from dashboard], Model: kr/claude-sonnet-4.5 Alternative: run from source (this repository): PORT=20128 NEXT_PUBLIC_BASE_URL=http://localhost:20128 npm run dev Production mode: PORT=20128 HOSTNAME=0.0.0.0 NEXT_PUBLIC_BASE_URL=http://localhost:20128 npm run start
Source: Official README and linked documentation

Use Cases

9Router is suitable for developers and technical teams who use AI coding tools and need to manage and optimize their AI token usage. It is useful in scenarios where developers want to avoid hitting subscription limits, reduce costs, and ensure continuous coding without interruptions.

Source: Official README and linked documentation

Strengths & Limitations

Strengths

  • broad token management and fallback options
  • Supports a wide range of AI coding tools
  • Open-source and customizable

Limitations

  • May require technical knowledge to set up and configure
  • Dependency on external AI providers
Source: Official README and linked documentation

Latest Release

v0.5.65 (2026-07-16): Added Grok Imagine video generation, Copilot Claude route, i18n th/fa version 0.5.35

Source: Official releases

Verdict

9Router is a tool for developers looking to optimize their AI coding workflows. Its broad token management features and support for a wide range of AI coding tools make it a option for teams aiming to reduce costs and ensure continuous coding without interruptions.

Sources and review scope
This review is based on the project's public documentation. Versions, installation commands, and feature boundaries can change upstream; check the cited sources and current release before use. Sources checked on: 2026-09-23 13:55.

Reference materials: README, GitHub API, dependency files