cliproxy-rs is a small server you run on your own computer that lets coding tools such as Claude Code, Codex CLI, or Cursor use the AI subscriptions and API keys you already have, like a Claude Max plan or a ChatGPT plan, through one local address. A dashboard built into the server shows which accounts work, how much of each plan's limits remains, and how to connect each tool.

The project is a Rust rewrite of CLIProxyAPI and reads the same config.yaml and account files, allowing users to switch between the two in either direction. Primary use cases include sharing Claude and ChatGPT plans across multiple tools, distributing requests across several Claude or Codex accounts, and translating between Anthropic, OpenAI and Gemini formats so an OpenAI-only tool can use a Claude account and vice versa.

Installation and Setup

On macOS or Linux, run: curl -fsSL https://raw.githubusercontent.com/vayungodara/cliproxy-rs/master/install.sh | sh. On Windows, in PowerShell: irm https://raw.githubusercontent.com/vayungodara/cliproxy-rs/master/install.ps1 | iex. The install command checks the release checksum, writes a config with new keys to ~/.cliproxy-rs, starts the proxy in the background, and opens the dashboard in your browser. Keys remain in ~/.cliproxy-rs/keys.env and are never printed.

In the dashboard, sign in with the CLIPROXY_MANAGEMENT_KEY line from keys.env and choose Connect account. Then open Use with tools and copy the settings for Claude Code, Codex CLI, or another tool. The proxy serves the Anthropic Messages API at http://127.0.0.1:8317, the OpenAI API at http://127.0.0.1:8317/v1, and the Gemini API at http://127.0.0.1:8317, all with your client key. For Claude Code:

export ANTHROPIC_BASE_URL=http://127.0.0.1:8317
export ANTHROPIC_AUTH_TOKEN=your-client-key
claude

docs/CLIENTS.md has copy-paste setups for Claude Code, Codex CLI, Gemini CLI, Amp, OpenCode, Factory Droid, Cline, Roo Code, Kilo Code, Cursor, Zed, Continue, Aider and the OpenAI, Anthropic and Gemini SDKs.

Multi-Account Routing

Sign in to as many Claude and Codex accounts as you have and choose how the proxy rotates between them: round-robin, fill-first, weighted-round-robin, or soonest-reset (experimental, a cliproxy-rs addition that spends the account whose weekly window resets soonest first). Session affinity keeps each conversation on one account so the provider's prompt cache stays warm, and an account that hits a limit rests while the others take over. docs/MULTI-ACCOUNT.md covers routing, cooldowns, the quota view, per-account proxies, Codex over WebSocket and reaching the proxy from other machines over Tailscale.

API Compatibility

cliproxy-rs serves the same routes and the same v8 Management API as CLIProxyAPI, so community apps built on CLIProxyAPI should work with it, for example CPA-Manager-Plus, CLIProxyAPI Quota Inspector, ZeroLimit, Quotio, VibeProxy and CCS. Apps that talk to a running server need only its address and management key; apps that start their own bundled CLIProxyAPI need an option to use an existing server instead.

Performance and Benchmarks

On a 2-vCPU test machine with a local fake upstream (2026-10-03), Go is faster on non-streaming throughput: CLIProxyAPI handled about 34% more non-streaming requests per second (1,568 against 1,168) and about 10% more plain streams (916 against 833). cliproxy-rs was faster on streams it translates between the Anthropic and OpenAI formats (793 against 564 per second, about 41% more) and used less than half of Go's memory: 17 MB at idle against 45 MB, and 25 to 50 MB under load against 58 to 104 MB. It answers its first request about 17 ms after launch, and the release binary is 36 MB against 69 MB. docs/BENCHMARKS.md has the method and every number.

Workspace Structure

The workspace consists of crates/cpa-core (config and account formats), crates/cpa-exec (one module per upstream provider), crates/cpa-translate (format translation), crates/cpa-server (routes, account selection and the Management API), crates/cliproxy (the binary) and ui/ (the dashboard, see ui/README.md). The workspace has 935 tests run against local mock upstreams only; CI runs the whole suite on every push, with Go and PostgreSQL installed so the tests that compare against them run too. A differential harness sends the same 57 cases to CLIProxyAPI and cliproxy-rs and compares the results.

Build checks: cargo fmt --all --check, cargo clippy --workspace --all-targets --locked -- -D warnings, cargo test --workspace --locked. CONTRIBUTING.md explains how to send a change. The project is MIT licensed; CLIProxyAPI, which this project follows closely, is also MIT licensed.