9Router on AWS - One Endpoint for Every AI Coding Tool You Actually Use
Every AI coding setup hits the same wall eventually. Claude Code is pointed at one provider, Cursor at another, Codex is on a separate API key entirely, and the moment one of them hits its rate limit mid-task, whatever you were doing just stops. You either wait it out or go rewire a config file while the deadline doesn't move.
Meetrix packaged 9Router into an AWS Marketplace CloudFormation stack that deploys to a single EC2 instance in your own AWS account. One OpenAI-compatible endpoint, 40+ providers behind it, automatic fallback when one runs dry, and nginx already tuned for the long-lived streaming connections coding agents depend on. Ready to try it? Launch the Meetrix 9Router stack on AWS Marketplace.
What Is 9Router?
9Router is a self-hosted AI routing proxy, not another model provider. It sits between your coding tools and whatever LLM accounts you've actually got, and exposes a single OpenAI-compatible endpoint for all of them. Point Claude Code, Cursor, Codex, Cline, or Copilot at it once, and it handles the translation between OpenAI, Claude, and Gemini request formats underneath, so the tool never needs to know which provider actually answered.
The part that matters most day to day is the fallback chain. Connect a subscription, a cheaper pay-as-you-go option, and a free tier like Kiro AI or OpenCode Free, and 9Router works through them in that order automatically when one hits quota. There's also a built-in RTK token saver that compresses tool output before it reaches the model, cutting input tokens by roughly 20-40% depending on how verbose your workflow's tool calls are.
What Routing Through a Hosted Middleman Actually Costs
How Deployment Works
Setting this up by hand means picking a base image, installing Docker, wiring nginx to not buffer server-sent events (coding agents stream, and a default nginx config will silently break that), and scripting your own SSL renewal before a single request gets routed. Through the Marketplace, it's four steps:
- Subscribe and Launch from AWS Marketplace Open the Meetrix 9Router listing, subscribe, and launch the CloudFormation stack. t3a.small is the recommended instance size for a single user or small team.
- SSL and the Streaming Proxy Are Already Configured nginx ships tuned for Server-Sent Events, no buffering, long timeouts, so streaming responses don't cut off mid-answer. SSL issues automatically through Let's Encrypt if your domain sits on a Route53 hosted zone.
- Wait for Boot, Then Log In Give the instance a few minutes, then open the dashboard URL from the stack's Outputs tab and log in with the InitialPassword you set as a stack parameter. There's no separate username.
- Connect a Provider and Point Your Tools at the Endpoint Add a provider from the dashboard, free tier or your own key, then copy your API key from the Endpoint page and set your coding tool's base URL to your domain's /v1 path.
What Meetrix Brings to This Deployment
- No Manual Docker or nginx Tuning - 9Router v0.5.59 ships pre-pulled on Ubuntu 26.04, with nginx already configured for streaming instead of a config you'd otherwise have to debug after your first cut-off response.
- SSL That Handles the DNS-01 Challenge For You - Automatic Let's Encrypt certificates through Route53, not a manual certbot dance every renewal cycle.
- Data on a Persistent Volume, With a Backup Script Ready to Go - SQLite state lives on a persistent gp3 EBS volume that survives a stop and restart, plus a one-command script to push a backup to S3 whenever you run it.
- Hardened by Default - ufw, unattended-upgrades, and the SSM agent are already active, not something you configure after the fact once you remember to.
- Flat Pricing Regardless of Routing Volume - The software fee doesn't move whether you route ten requests a day or ten thousand. Only your chosen EC2 instance size changes the bill.
- People Who Actually Run This Stack - Support goes to aws@meetrix.io with a response inside 12 hours, from engineers who deploy this AMI regularly, not a queue reading from a script.
Who Is 9Router on AWS Right For?
This fits anyone whose AI coding setup has outgrown a single provider and a single API key. More specifically, it's a strong match if you're:
- A developer running Claude Code, Cursor, or Codex who's tired of a rate limit stopping work mid-task
- A team stacking a subscription, a cheap provider, and a free tier, and wants the fallback between them handled automatically instead of by hand
- Someone who priced out OpenRouter's 5.5% fee against a real month of usage and wants to know what self-hosting the same routing looks like instead
- A developer who wants tool output compressed before it hits the model, since input tokens add up fast on long agent sessions
- A compliance-conscious team that needs provider API keys and request history to stay inside its own AWS account, not routed through a third party's servers
- Anyone standardizing several coding tools on one endpoint instead of maintaining separate provider configs per tool
9Router on AWS by Meetrix vs Alternatives
| Feature | 9Router on AWS by Meetrix | OpenRouter | LiteLLM (Self-Hosted Manual) | No Gateway (Direct API Keys) |
|---|---|---|---|---|
| Hosting | Your own AWS account, fully self-hosted | OpenRouter's cloud, no self-host option | Your own server, set up by you | No gateway, each tool talks to its provider directly |
| License | Open source, self-hosted | Proprietary | Open source core, enterprise tier from roughly $250/month | Not applicable |
| Pricing Model | Flat AWS instance rate from $0.001/hr, no per-request fee | 5.5% fee on every credit purchase (5% on crypto), on top of provider cost | Free core proxy, but you carry compute, database, and ops cost | No extra fee, but no fallback or format translation either |
| Automatic Fallback | Yes, subscription to cheap to free, configured out of the box | No automatic multi-tier fallback between your own accounts | Possible, but you configure and maintain the routing rules yourself | None, a dead provider means a dead tool |
| Format Translation | OpenAI, Claude, and Gemini formats, one endpoint | OpenAI-compatible endpoint, hosted | Yes, once you've configured it | None, each tool needs its provider's native format |
| Deployment Time | Minutes via CloudFormation | Instant signup | Hours, Docker, database, nginx, SSL by hand | None, but no benefits either |
| Data Location | Your own AWS account | OpenRouter's infrastructure | Your server | Each provider's infrastructure separately |
| Support | Meetrix engineers, response inside 12 hours | Support tiers, gated by plan | Community forums, or a paid enterprise contract | Whatever each provider offers |
Resources
The full walkthrough, launching the stack, configuring DNS and SSL, connecting a provider, and pointing your first CLI tool at the endpoint, is in the Meetrix 9Router Developer Guide.
Under the Hood
Here's what's actually running once the stack finishes deploying.
9Router v0.5.59 in Docker
Runs as the decolua/9router:0.5.59 container on Ubuntu 26.04 LTS, pre-pulled so the first boot doesn't spend its first few minutes downloading images.
nginx Tuned for Streaming
Configured specifically for Server-Sent Events, no response buffering and long timeouts, since coding agents depend on a stream that doesn't get cut off mid-response.
SSL via Route53 DNS-01
Let's Encrypt certificates issue automatically through the Route53 DNS-01 challenge when your domain's hosted zone lives there.
SQLite on Persistent EBS
State lives in the 9router-data Docker volume at /app/data/db/data.sqlite, on a persistent gp3 volume that survives a stop and restart on its own.
A Script, Not a Schedule
/opt/scripts/dbbackup.sh pushes a gzipped copy of the database to your S3 bucket, but nothing runs it automatically. Add a cron entry if you want regular backups.
ufw, Unattended Upgrades, and SSM
The base image ships with a firewall active, automatic security patching enabled, and the SSM agent running for console access without opening SSH wider than you need to.
One Thing 9Router Won't Do For You
It won't back itself up on a schedule. The database survives a stop and restart because it lives on a persistent EBS volume, but the S3 backup script only runs when you or a cron job tells it to. Skip that step and a bad instance replacement could cost you routing history and provider configuration you'd rather not rebuild from memory. It's a five-minute cron entry, worth setting up before you need it rather than after.
Frequently Asked Questions
What does 9Router actually do?
It sits between your AI coding tools and whatever model providers you've connected, exposing one OpenAI-compatible endpoint. Point Claude Code, Cursor, Codex, Cline, or Copilot at that single endpoint instead of juggling separate configs per tool, and it translates request formats between OpenAI, Claude, and Gemini behind the scenes.
Do I need my own provider accounts?
You need at least one connected provider, but it doesn't have to be a paid one. 9Router supports 40+ providers, including free tiers like Kiro AI and OpenCode Free, alongside paid subscriptions or your own API keys for Anthropic, OpenAI, or Google. It routes across whatever you've connected.
What happens when a provider hits its rate limit mid-task?
That's the actual reason to run this. 9Router falls back automatically, subscription first, then a low-cost option, then a free one, so a quota wall on one provider doesn't stop your coding tool cold. You keep working while it quietly reroutes.
What does this cost to run on AWS?
The software fee is flat regardless of usage. What changes is the EC2 instance price: $0.001/hour on a t2.micro up to $0.024/hour on a t2.medium, t3.large, or c5.large. t3a.small at $0.019/hour is the recommended size for a single user or small team. On top of that you pay whatever your connected providers charge, same as you would without a router.
How much does the RTK token saver actually save?
Roughly 20-40% off input tokens, by compressing tool output before it gets sent to the model. It's not a universal number, exact savings depend on how verbose the tool output your workflow generates is, but it's a real reduction on the token bill you're already paying, not a marketing rounding error.
How do I point Claude Code or Cursor at it?
Open the Endpoint page in the dashboard, copy your API key, then set your tool's base URL to https://your-domain/v1 and pick a model in the form provider/model, for example kr/claude-sonnet-4.5. Works the same way for any tool that speaks the OpenAI API format.
Is my data backed up automatically?
Not by default, and it's worth knowing before you assume otherwise. State lives in SQLite on a persistent EBS volume, so it survives a stop and restart on its own. A backup script at /opt/scripts/dbbackup.sh pushes a gzipped copy to your S3 bucket, but nothing schedules it for you. Run it by hand or add a cron entry.
Where does everything actually run?
On the EC2 instance inside your own AWS account. Your provider API keys, routing rules, and request history stay there behind nginx with SSL, not on Meetrix's infrastructure or routed through a third party's billing layer.
Run Your Own AI Router on AWS
Stop paying a per-request fee to route your own API calls. Deploy 9Router on AWS in minutes, set up by a team that runs this stack every day.
Deploy on AWS Marketplace