LLM Router
Sign in before creating your router.
Your login keeps the router attached to your account so it remains available across browsers and devices.
Loading secure sign-in…
One endpoint. Your provider keys.
Keep your app running when a free tier runs out.
Add keys from multiple LLM providers. The router tries them in order and automatically fails over on rate limits or outages.
New router
Create your private router key
You will see the full key once. Store it like any other secret.
Router dashboard
My router
Add providers, inspect traffic, and copy integration snippets from one place.
Next step
No providers connected yet
Add Groq, Mistral, OpenRouter, or any supported provider to start routing requests.
OpenAI Responses-compatible
OpenAI Codex
Connect Codex CLI through the Responses API.
/v1/responses
Anthropic-compatible
Claude Code
Point Claude Code at your router using the Messages API.
/v1/messages
Provider health
Quick view of your configured provider keys and their latest status.
Provider directory
Provider keys
Keys stay on this server and are never shown again after saving.
Live check
Test your router
Send a real request through your connected providers before using the endpoint in another app.
Observability
Analytics and request logs
Explore aggregated routing trends separately from individual request records and debugging details.
Routing performance at a glance
Use shared filters, then move between the overview and dedicated provider, API/model, and application dashboards.
Token usage over time
Provider-reported and estimated input/output tokens.
Requests by client
Safely detected SDK or command-line application.
Fallback paths
Provider sequences used when the first attempt did not finish the request.
Provider success rate
Successful attempts divided by all upstream attempts.
Tool and structured output
Tool-enabled traffic, generated calls, and validation results.
Requests by API format
OpenAI Chat, Responses/Codex, and Claude Messages traffic.
Request frequency (Max 24)
Requests per hour across the selected time window.
Compare provider volume, reliability, latency, tokens, and fallback behavior
Attempt metrics describe every upstream try; completed-request metrics describe the provider that ultimately returned the response.
Completed requests
Requests ultimately served by each provider.
Attempt success rate
Successful upstream attempts divided by all attempts.
Average attempt latency
Time spent inside each provider attempt.
Token consumption
Provider usage without deduplicated double counting.
Provider comparison
Use View logs to open the matching request records.
Understand traffic by compatibility format and virtual model alias
Compare demand, success, latency, streaming, tool usage, token volume, and fallback behavior across client-facing interfaces.
Requests by API
OpenAI Chat, Responses/Codex, and Claude Messages volume.
API success rate
Successful client requests by compatibility format.
Requests by alias
Traffic sent to each virtual model.
Alias fallback rate
How often each alias needed more than one provider.
API compatibility performance
Client-facing endpoint behavior after current filters.
Model alias performance
Compare stable alias behavior before changing routing rules.
Compare Codex, Claude Code, SDK, cURL, and unknown-client traffic
Only normalized client categories and safe SDK metadata are used; raw user-agent and authorization values remain excluded.
Requests by application
Traffic volume by safely detected client.
Application success rate
Successful requests divided by all client requests.
Average latency
End-to-end response time observed by each application.
Tool-enabled traffic
Requests that supplied tool definitions.
Application comparison
API mix, aliases, streaming, tokens, tools, fallbacks, latency, and reliability.
Inspect individual gateway requests
Search and filter requests, then open a record for its timeline, attempts, headers, timings, payload, and response.
Recent requests
Click any request to open the full request and response drawer.
Documentation
Connect and understand your router
Copy a working integration or explore how routing, recovery, aliases, capabilities, and analytics work.
Integration snippets
Connect OpenAI-compatible apps, Codex, or Claude Code to this gateway.
Project feature guide
Understand every part of the router—from the incoming request to provider recovery.
Your application sends one request with one private router key. The gateway resolves the requested virtual model, checks provider compatibility and health, applies the selected routing policy, retries safe failures, returns the response in the caller's API format, and records the complete decision in Analysis.
POST /v1/chat/completions
POST /v1/responses
POST /v1/messages
GET /v1/models
Request lifecycle
Every supported API format passes through the same protected decision pipeline.
flm_... key and load
only that router's provider credentials.A request for free-router first tries Groq. Groq returns 429, so the router starts
a cooldown, tries Mistral, returns Mistral's answer, and records both attempts in Analysis.
Three API surfaces, one router
The same provider pool can serve regular OpenAI clients, Codex, and Claude Code.
Use /v1/chat/completions for most OpenAI-compatible SDKs and applications.
Use /v1/responses for Codex and clients built around the Responses API.
Use /v1/messages for Claude Code and Anthropic-compatible clients.
OpenAI app → POST /v1/chat/completions → model: "free-router"
Codex → POST /v1/responses → model: "codex-free-router"
Claude Code → POST /v1/messages → model: "claude-free-router"
The router translates requests and responses when necessary, while the client continues speaking its native API format.
Back to topBring your own provider keys
Connect any of the 26 built-in providers to create one private pool of available models and quotas.
What it does
Each signed-in router stores its own provider credentials. Keys are hidden after saving and are never returned in dashboard account responses.
Available providers
The catalog includes OpenRouter, Groq, NVIDIA, Mistral, Together AI, Fireworks AI, DeepInfra, Gemini, xAI, Novita, Baseten, Cohere, Anthropic, OpenAI, DeepSeek, Perplexity, FriendliAI, and more.
Where to configure
Open Providers, choose a provider, and save its API key. The card then shows its configured and health state.
You add Groq, Gemini, Anthropic, and Together AI. Your app still uses one
flm_... key; the router chooses which upstream provider and active model receives
each request.
1. groq configured
2. mistral configured
3. openrouter configured
4. cerebras no key — ignored
Save multiple provider models with one active choice
Model availability can change without the provider itself being down. Keep replacement model IDs ready and explicitly choose which one receives production traffic.
Add any valid provider model slug, such as qwen/qwen3-coder-next, without
editing the deployment configuration.
Only the selected active model is sent upstream. Inactive saved models are never silently attempted.
Models show healthy, unavailable, unauthorized, rate-limited, error, or not-tested state without incorrectly opening the provider circuit for a model-specific 404.
Add, activate, test, edit, and delete saved models from the provider card. The active model cannot be deleted until another option is selected.
The provider remains openrouter, groq, or nvidia
regardless of which saved model is active. Model slugs never become part of provider IDs.
OpenRouter
○ qwen/qwen3-coder:free unavailable · HTTP 404
● qwen/qwen3-coder-next active · healthy
○ deepseek/deepseek-r1:free saved · not tested
New requests use only qwen/qwen3-coder-next.
If the active model later returns a provider-specific 404, the router marks that model unavailable, keeps the provider circuit healthy, and immediately moves the request to the next ranked provider.
Routing policies
Choose how healthy, compatible providers are ranked before the first upstream call.
Always follows your provider order.
Prefers the lowest learned average latency after initial exploration.
Rotates requests across the ordered provider pool.
Prefers providers with fewer recorded attempts.
Prefers the best learned success score, then lower latency.
Combines health, reliability, latency, and usage into one score.
With Fastest, Groq averages 420 ms and Mistral averages 780 ms. Groq is tried first unless it is incompatible, cooling down, or circuit-open.
Provider priority remains the tie-breaker when candidates have the same policy score.
Back to topProvider priority order
Drag providers into the exact fallback order you want for this router.
What it controls
Priority is the complete selection rule under the Priority strategy and the deterministic tie-breaker for the other five strategies.
Where to configure
Go to Settings → Router & Policies → Routing Policies.
- Groq
- Mistral
- OpenRouter
Groq → timeout → retryable
Mistral → HTTP 200 → selected
OpenRouter→ not attempted
Automatic retry and provider failover
A failed upstream attempt can move the same client request to the next eligible provider.
Rate limits, timeouts, connection failures, upstream 5xx responses, and malformed successful responses.
Client-side validation or unsupported request errors are returned without repeatedly calling every provider.
When every candidate fails, the router returns a sanitized providers_exhausted
response.
Attempt 1 · Groq → 429 rate_limit
Attempt 2 · Mistral → 503 upstream_error
Attempt 3 · OpenRouter → 200 success
Client receives OpenRouter's response.
The Analysis drawer preserves every attempt so the successful final response does not hide earlier provider failures.
Back to topPersistent rate-limit cooldowns
A provider that returns 429 is temporarily removed from routing instead of being called again immediately.
How the timer is chosen
The router honors an upstream Retry-After header. Without one, it uses
escalating fallback windows: 30 seconds, 1 minute, 2 minutes, 5 minutes, 10 minutes, then 15
minutes.
What persists
Cooldown state is stored per router and provider, so restarting the server does not immediately hammer the same rate-limited key again.
Groq returns Retry-After: 60. For the next minute, requests skip Groq before any
network call and continue with the next compatible provider.
provider: groq
state: cooldown
retry_in: 42s
network_call_made: false
Persistent circuit breaker
Repeated operational failures stop traffic to a provider until it has a controlled chance to recover.
Normal routing. Failures are counted.
After three eligible failures, traffic is blocked for 2, 5, 10, then 15 minutes.
One recovery probe is allowed after the timer expires.
Mistral times out three times. Its circuit opens for two minutes. Requests use other providers. After two minutes, one probe is allowed: success closes the circuit; failure reopens it for five minutes.
Circuit state includes failure type, consecutive failures, open count, recovery time, and probe state.
Back to topModel aliases
Create stable model names that carry their own routing intent without changing application code.
Default aliases
free-routercodex-free-routerclaude-free-router
Optional alias rules
An alias can override the router strategy, require capabilities, restrict eligible providers, and define its own provider order.
vision-router requires vision, uses Reliability, and allows only OpenRouter and
NVIDIA. Your app simply sends model: "vision-router".
{
"id": "vision-router",
"routingStrategy": "reliability",
"requiredCapabilities": ["vision"],
"eligibleProviderIds": ["openrouter", "nvidia"]
}
Use GET /v1/models to discover enabled aliases. Analysis
records both the requested alias and the actual upstream provider model.
Model-aware capability registry
Combine provider transport support with the capabilities of each user-saved model, then route using the active model's verified profile.
Provider defaults describe the API transport. Each saved model can override those values with its own supported, unsupported, or unknown capability state.
Every model value identifies whether it came from a user override, capability probe, runtime request, built-in model catalog, or provider default.
Successful real requests verify support. Only clear capability-specific rejections mark a feature unsupported; rate limits, timeouts, and generic provider failures never change it.
Flexible mode keeps unknown models as lower-confidence fallbacks. Strict mode excludes unknown support for required capabilities before any upstream call.
OpenRouter / qwen3-coder-next supported (probe) → eligible
Groq / custom-llama unsupported (user) → skipped
Mistral / brand-new-model unknown (provider) → flexible fallback
→ strict-mode skip
User override
↓
Capability probe
↓
Runtime observation
↓
Built-in model catalog
↓
Provider default
Use Detect capabilities or edit a model manually under Settings. Analysis records the active provider model, effective capability values and sources, and why each candidate was eligible or skipped. A clear capability rejection updates only that model and immediately fails over without opening the provider circuit.
Back to topFull request timeline and Analysis logs
Follow every routing decision in chronological order—from gateway receipt to the final response or error.
See authentication, alias resolution, filtering, ranking, provider starts, outcomes, retries, backoff, and final delivery with elapsed milliseconds.
Skipped-provider events preserve capability mismatches, quota exhaustion, cooldowns, open circuits, and half-open recovery probes.
Expand raw details for any event or copy the complete plain-text timeline for debugging and issue reports.
The same event format is stored for successful failover, exhausted routes, invalid provider keys, and deduplicated requests.
0 ms Request received
1 ms Router key accepted
2 ms Alias “free-router” resolved
4 ms NVIDIA skipped — vision unsupported
5 ms Groq ranked #1
6 ms Attempt 1 started — Groq
1,204 ms Groq failed — HTTP 429
1,205 ms Cooldown started for Groq
1,205 ms Retry scheduled after 500 ms
1,708 ms Attempt 2 started — Mistral
2,942 ms Mistral succeeded — HTTP 200
2,945 ms Response returned to client
Each event stores an ISO timestamp, elapsed milliseconds, event type,
provider, human-readable explanation, and expandable raw metadata. A provider
401 invalid_api_key, exhausted route, or deduplicated request remains visible with
the exact reason and original request context.
Request IDs and richer routing headers
Use one safe identifier to trace a client request through authentication, retries, provider calls, Analysis, errors, streaming, and deduplicated responses.
Send a valid x-request-id, or let the gateway create a collision-resistant
req_... value. Unsafe and oversized IDs are replaced.
Every retry forwards the same safe x-request-id to the selected provider without
exposing router keys, account IDs, or storage identifiers.
The ID appears in response headers, structured error bodies, streaming headers, request timelines, and the Analysis record.
Headers show the winning provider, provider model, requested alias, strategy, attempt count, fallback usage, latency, quota warning, circuit state, cooldowns, and retry-stop reason when applicable.
Each duplicate keeps its own request ID while x-free-llm-original-request-id
points back to the upstream operation that produced the reused response.
Paste a request ID into the Analysis search box, copy it from the drawer, inspect every returned routing header, or jump from a duplicate to its original record.
x-request-id: checkout-summary-8472
x-free-llm-request-id: checkout-summary-8472
x-free-llm-request-id-source: client
x-free-llm-provider: mistral
x-free-llm-provider-model: mistral-small-latest
x-free-llm-requested-model: free-router
x-free-llm-routing-strategy: reliability
x-free-llm-provider-attempts: 2
x-free-llm-fallback-used: true
x-free-llm-total-latency-ms: 2841
x-free-llm-deduplicated: false
{
"error": {
"type": "providers_unavailable",
"message": "No compatible provider is currently available.",
"request_id": "req_7d7f..."
}
}
Valid client IDs may contain letters, numbers, periods, underscores, colons, and hyphens up to 128 characters. The gateway never forwards private account or database identifiers.
Back to topRouter, provider, first-token, and stream timing
See exactly where request latency is spent instead of relying on one total-duration number.
Measures authentication, account loading, alias resolution, capability checks, quota checks, circuit checks, and provider ranking before the first upstream call.
Separates time to upstream headers from response-body or stream consumption and preserves an independent breakdown for every retry.
Captures time to first provider token, active stream duration, output throughput when token usage is available, and final stream-processing time.
Shows configured backoff separately from provider latency, so a slow response can be distinguished from deliberate recovery waiting.
Failed requests retain partial timing evidence, while reused responses report deduplication latency without inventing a provider call.
Performance headers provide quick client-side measurements, while the Analysis drawer adds metric cards, timing bars, per-provider details, and a copyable report.
Total request 4,280 ms
Router preparation 18 ms
Groq attempt 1,205 ms
Retry backoff 500 ms
Mistral provider time 2,430 ms
Time to first token 620 ms
Active stream duration 1,810 ms
Response processing 12 ms
x-free-llm-router-latency-ms: 30
x-free-llm-provider-latency-ms: 3635
x-free-llm-first-token-ms: 2470
x-free-llm-stream-duration-ms: 1810
x-free-llm-retry-delay-ms: 500
x-free-llm-total-latency-ms: 4280
For streaming responses, time-to-first-token is available before the first client chunk. Final stream duration and throughput are stored in Analysis and sent as HTTP trailers when the client supports them.
Back to topToken, fallback, tool-call, and client analytics
Turn individual request records into trends that explain cost, reliability, feature usage, and where traffic originates.
Compare input, output, reported, and estimated usage without double-counting deduplicated requests.
See how often the first provider fails and which provider sequence ultimately completes the request.
Track tool-enabled requests, generated calls, requested tool names, and structured-output validation.
Group traffic into Codex CLI, Claude Code, OpenAI SDKs, cURL, and unknown clients without storing sensitive headers.
Total tokens 1,240,800
Fallback rate 12.4%
Most common path Groq → Mistral
Tool-enabled requests 86
Most used client Codex CLI
Most reliable provider Mistral · 98%
Analysis is split into Analytics for aggregated cards and charts and Request Logs for individual records, timelines, headers, and payload inspection. Each tab keeps independent filters. Only normalized client labels and safe SDK metadata are stored; authorization values, IP addresses, and raw user-agent strings are not persisted as client analytics.
Back to topExpanded provider, API/model, and application dashboards
Move beyond one general chart page and inspect each operational dimension in a dedicated workspace.
Compares completed requests, upstream attempts, success rate, average and P95 latency, token consumption, fallback starts, and recovery wins for every provider.
Shows traffic, success, latency, streaming share, tool usage, token volume, attempts, and fallback rate by API compatibility format and model alias.
Compares Codex CLI, Claude Code, OpenAI SDKs, Anthropic SDKs, cURL, and unknown clients by volume, reliability, latency, tokens, tools, API mix, and aliases.
Time range, provider, API, status, alias, application, delivery mode, tools, and search apply consistently while switching dashboards.
Every comparison table includes a View logs action that opens Request Logs with the matching provider, API, alias, or client filter already applied.
Client demand still includes deduplicated responses, while provider attempts, tokens, and fallback metrics count only real upstream work.
Groq
Completed requests 842
Upstream attempts 996
Attempt success rate 84.5%
Average attempt latency 620 ms
P95 attempt latency 1,940 ms
Fallback starts 154
Fallback recoveries 8
Tokens used 1,840,200
Codex CLI 410 requests · 96% success · 72% tools · Responses API
Claude Code 288 requests · 98% success · 61% streaming · Messages API
Python SDK 172 requests · 94% success · 14% fallback · Chat Completions
OpenTelemetry export is intentionally deferred and not required for the current product scope. These dashboards use the router's own privacy-safe Analysis records.
Back to topBuilt-in Playground
Send a real request through your router before connecting an external application.
What you can test
Select an API compatibility mode, choose an enabled alias, enter a prompt, and send the request using the same routing path as production traffic.
What you learn
The result shows the endpoint, response, latency, and provider used. The same request also appears in Analysis.
- Add two provider keys.
- Choose
free-router. - Send “Return valid JSON.”
- Open Analysis to inspect the winner and fallback decisions.
Provider health and recovery controls
See live protection state and recover a provider without deleting its key.
Remove an active rate-limit cooldown when you know quota is available again.
Run a real half-open probe immediately against an open circuit.
Manually close the circuit and clear its failure state.
You replace an invalid provider key while its circuit is open. Click Test recovery; a successful probe closes the circuit and returns the provider to normal routing.
Countdowns and compact actions appear in Provider Health, provider cards, and Routing Policies.
Back to topProvider quota and usage tracking
Track request and token consumption per provider, warn before a limit is reached, and keep exhausted providers out of the route.
Configure request limits, token limits, or both from each connected provider card.
Every upstream attempt updates request counters. Successful responses add provider-reported or estimated token usage.
Providers above the warning threshold are deprioritized. Providers at a configured limit are skipped until the relevant UTC window resets.
Request details show input, output, total tokens, and whether usage was reported or estimated.
Groq quota: 1,000 requests/day
Warning at: 80%
Current usage: 812 requests
Routing result: Groq remains eligible but moves behind healthy providers
At 1,000 requests:
Groq quota-exhausted → skipped
Mistral healthy → selected
Analysis records the quota skip and reset time
A provider reports 6 input tokens and 4 output tokens. The router
stores 10 total tokens in both the daily and monthly usage windows. If the provider
omits usage, the router estimates input tokens and labels the value as estimated.
Limits are user-configured because provider plans and free-tier allowances vary. Use the values shown in your provider account.
Back to topConfigurable retry and timeout controls
Control how long each provider may run, separate immediate provider failover from transient retry backoff, and define when the router must stop.
Set the normal provider timeout, hard total-request deadline, streaming connection timeout, and shorter half-open recovery-probe timeout.
Cap upstream calls per request so a long provider list cannot create unlimited failover work.
Provider-specific 401, 403, and 404 failures move
immediately to the next provider. Configured transient statuses, network failures, and
malformed responses use retry pacing.
Configure the initial delay, maximum delay, multiplier, and randomized jitter used between retryable failures.
Give one slow provider a longer timeout or force an unreliable provider to fail fast without changing every provider.
Specialized aliases can override provider timeout, total deadline, and maximum attempts while inheriting every other router setting.
Settings:
provider timeout: 8 seconds
total deadline: 30 seconds
maximum attempts: 3
backoff: 250ms → 500ms, jitter enabled
Attempt 1 — OpenRouter
HTTP 404 model unavailable → immediate failover → no delay
Attempt 2 — Groq
HTTP 503 after 420ms → transient retry → wait 250ms
Attempt 3 — Mistral
HTTP 200 after 1.2s → response returned
Analysis records each timeout, delay, and decision.
fast-router can use a 4-second provider timeout, 12-second total deadline, and
only two attempts, while free-router continues using the router-wide defaults.
Immediate provider failover and transient retries both obey the attempt
limit and total deadline. Invalid client requests such as an unconfigured 400 still
stop instead of being sent to every provider. Analysis shows the exact recovery action.
Request deduplication and idempotency
Avoid repeated upstream calls when clients submit the same safe operation at nearly the same time.
Two identical requests arriving together share one provider operation. Both clients receive the same completed response.
Successful non-streaming responses may be replayed during the configured one-to-300-second window.
Fingerprints include the router identity and endpoint, so different accounts can never share cached work.
The alias, messages or input, temperature, token limits, tool definitions, and structured-output settings all affect the match.
Clients can explicitly identify one logical operation. The key takes precedence over automatic request fingerprinting.
Streaming is always excluded. Tools, multimodal inputs, and explicitly non-deterministic settings are bypassed by default.
Client A → POST /v1/chat/completions → provider call starts
Client B → identical request → joins Client A in flight
Provider → HTTP 200 → both clients receive the response
Client C → identical request 5s later → completed response is reused
Provider requests charged: 1
Router responses returned: 3
Quota request units saved: 2
Idempotency-Key: document-summary-job-8472
Authorization: Bearer flm_your_router_key
x-free-llm-deduplicated: true
x-free-llm-original-request-id: req_...
x-free-llm-deduplication-source: in-flight | completed
The duplicate record points to the original request ID, reports whether it joined an in-flight call or reused a completed response, and estimates the requests and tokens protected. Provider usage counters increase only for the real upstream call.
Failed responses are shared only with callers already waiting for that same in-flight operation and are never stored for later reuse. The current response cache is process-local and intentionally ephemeral; horizontally scaled deployments should use sticky routing until a shared deduplication coordinator is added.
Back to topAccount isolation, private router keys, and storage
Authentication separates router data while the gateway key authorizes API traffic.
Signed-in users load only their own router settings, aliases, provider keys, and analytics.
The full flm_... key is shown once and should be treated like any production
secret.
Run with local JSON for development or Redis/KV for persistent deployment state.
Provider credentials can be encrypted at rest with AES-256-GCM when the encryption secret is configured.
Authorization: Bearer flm_your_private_router_key
Content-Type: application/json
Provider keys are used only server-side and are not exposed to Codex, Claude Code, browser clients, or Analysis responses.
Back to topSettings
Manage your router
Update your account, routing behavior, and stored request data.
Signed-in user
Email unavailable
- Login method
- Unknown
- User ID
- Unavailable
- Account created
- Unavailable
- Last sign in
- Unavailable
Signed in
Your router remains connected to this account across supported browsers and devices.
Encrypted
Provider credentials are encrypted before they are written to hosted storage.
API keys hidden
Actual provider-key values are never shown in the dashboard or analytics logs.
Detailed analysis
The router keeps up to 250 recent request records for debugging and analytics.
Stored data
Manage request history without affecting your router or provider keys.
Delete all stored request and response records for this router. Provider keys are not affected.