9router: Local Proxy Connecting Free Models to Cline, Claude Code, and Coding Tools

9router connects AI coding agents like Cline and Claude Code to a local proxy, unlocking 40+ models with 3-tier automatic fallback and RTK prompt compression.

tau · September 10, 2026

#9router #Cline #ClaudeCode #AICoding #LocalProxy #DevTools

9router: Local Proxy Connecting Free Models to Cline, Claude Code, and Coding Tools

Amid increasing fragmentation across AI coding environments, an open-source local routing proxy called '9router' is gaining attention for its ability to bridge multiple coding agents and external LLM providers through a single local endpoint, enabling developers to seamlessly tap into free model tiers and existing subscriptions.

Architecture diagram showing 9router local proxy (localhost:20128) routing requests from Cline, Claude Code, and other AI coding tools to multiple model providers

Image source: decolua on GitHub / Luong NGUYEN (@luongnv89) on X

AI coding harnesses in widespread use today—such as Cline, Claude Code, Codex, Cursor, and OpenCode—each rely on distinct configuration schemes and API protocols. 9router runs as a lightweight local proxy middleware designed to normalize these heterogeneous API standards, allowing developers to route requests cleanly while distributing workloads across their paid accounts and vendor promotional tiers.

Unified Local Endpoint and Multi-Harness Integration

At the core of 9router's architecture is a standardized API endpoint served on a local port (defaulting to http://localhost:20128/v1). Instead of manually updating endpoint URLs across different editors and terminals, developers can point all their coding tools toward a single local gateway.

  • Supported Coding Harnesses: Direct integration is supported across more than eight major AI coding environments, including Cline, Claude Code, Codex, Cursor, and OpenCode.
  • Dual-Protocol Routing: According to the official CHANGELOG, the tool features built-in dual-protocol branching for Anthropic-compatible POST /v1/messages and OpenAI-compatible /chat/completions, transparently transforming requests to match client expectations.
  • Standardized JSONC Presets: Official JSONC configuration profiles are provided for clients such as opencode, openclaw, kilo, droid, cowork, copilot, claude, and cline, significantly reducing onboarding friction across diverse workflows.

This setup eliminates the need to manually reconfigure endpoints for each tool, centralizing all coding agent traffic right on the developer's local machine.

Aggregating 40+ Providers with 3-Tier Fallback and Prompt Compression

9router pools promotional allocations and quota allowances across multiple upstream vendors into a unified resource pool.

  • Extensive Provider Coverage: Over 40 providers are aggregated into the single gateway, encompassing Kiro AI (offering roughly 50 monthly free credits for models like Claude 4.5 and GLM-5), OpenCode Free (requiring no authentication), and Cline's official free models (such as DeepSeek V4-Flash and Meta Muse Spark), alongside standard user-supplied subscription tiers.
  • 3-Tier Smart Fallback: To prevent coding agents from stalling during extended autonomous tasks, 9router implements an automatic 3-tier fallback pipeline. The system prioritizes primary subscription models, seamlessly cascades to low-cost paid models upon rate limits or errors, and finally routes to accessible free tiers as a safety net.
  • RTK Prompt Compression: An integrated RTK prompt compression layer helps reduce context token consumption by up to 40%. When feeding extensive conversation logs and large codebase snippets into the context window, this reduces token overhead and minimizes latency.

Setup Considerations and Practical Constraints

Before incorporating 9router into daily development workflows, several architectural and operational realities should be evaluated.

  • Evaluating Free-Tier Marketing Figures: Social posts touting figures like "92 million tokens per day completely free" represent theoretical aggregates derived from combined upstream promotional tiers. Real-world usable capacity will vary depending on upstream rate limits, active quotas, and supplier policy changes.
  • Recommended Execution Environment: The official repository documentation indicates that the core application package (9router-app) remains private. Consequently, deploying via verified source builds or a Docker container environment is recommended for controlled local execution.
  • Security and Environmental Isolation: Because a local proxy sits directly in the path of API keys and source code requests originating from developer machines, testing is best suited for personal projects, open-source explorations, and experimental sandbox setups rather than high-compliance commercial environments.

Sources

  • decolua/9router Repository - GitHub: The official 9router open-source GitHub repository, providing Docker setup instructions, detailed lists of 40+ supported providers, JSONC configuration presets for Cline and Claude Code, and ongoing changelog notes.