Back Open WebUI with the whole catalog through one connection
Open WebUI is the most widely deployed self-hosted chat interface, and any OpenAI-compatible endpoint can sit behind it. Added as a connection, Router One is auto-discovered through the /models endpoint — GPT, Claude, Gemini, and DeepSeek family models show up in the model selector for every user on your instance, and each conversation is traced for cost on the gateway.
Configure Open WebUI to use the Router One base URL
On a running instance, open Admin Panel → Settings → Connections, add an OpenAI API connection with the gateway URL and your key, and models are discovered automatically — use the connection's model ID filter if you want to trim the list your users see. A fresh Docker deployment can seed the same connection with two environment variables:
# Open WebUI → Admin Panel → Settings → Connections → OpenAI API URL: https://api.router.one/v1 API Key: sk-your-router-one-key # Or seed the connection at first launch: docker run -d -p 3000:8080 \ -e OPENAI_API_BASE_URL=https://api.router.one/v1 \ -e OPENAI_API_KEY=sk-your-router-one-key \ ghcr.io/open-webui/open-webui:main
Which model ID should Open WebUI send?
Copy the exact model ID from the /models page — IDs are case-sensitive, and the page lists each model's context window, capabilities, and current per-token rates. Create a dedicated API key per tool with its own maxSpend cap, so one runaway tool can't affect other workloads.
Verify the Open WebUI call in your request trace
After your first request, open Dashboard → Logs to see its full trace: model, tokens, cost, latency, and status code. From here every Open WebUI call has a ledger and a trail instead of being a black box.
FAQ
I changed OPENAI_API_BASE_URL but Open WebUI ignores it — why?
Connection settings are persistent config: Open WebUI writes them to its database on first launch, and environment changes afterwards are ignored. Edit the connection under Admin Panel → Settings → Connections instead, or start over with a fresh data volume.
Which models can Open WebUI use through the gateway?
Any chat-capable model in the catalog — GPT, Claude, Gemini, Grok, DeepSeek, GLM, and Kimi families. The /models page is the source of truth for model IDs and per-token rates.
Does this work from Mainland China?
Yes. The gateway is reachable from Mainland China without a VPN, and the configuration is identical to the global setup.
How do I debug a 401/403/429?
Open Dashboard → Logs first to see whether requests reached the gateway and with what status, then walk the error-codes reference to check env vars, key status, and limits.