{"slug": "self-host-a-litellm-ai-gateway-on-railway-one-api-for-100-llms-with-budgets-and", "title": "Self-host a LiteLLM AI gateway on Railway: one API for 100+ LLMs, with budgets and virtual keys", "summary": "A developer built and published a one-click Railway template that self-hosts LiteLLM as an AI gateway, exposing a single OpenAI-compatible endpoint for 100+ LLM providers with per-app virtual keys, budgets and spend tracking. The template pins stable image tags rather than floating ones and requires operators to back up the LITELLM_SALT_KEY, which encrypts stored provider credentials. The author notes the template is unofficial and not affiliated with BerriAI, LiteLLM's maintainer.", "body_md": "If your apps call OpenAI, Anthropic, OpenRouter and Gemini, you end up with provider keys copied everywhere and no idea who spent what. LiteLLM fixes that: one OpenAI-compatible endpoint, virtual keys per app or team, budgets and spend tracking.\n\nI made a one-click Railway template for it.\n\n`latest`, `main-stable`) for a few hours. This template never uses floating tags.` admin` with `UI_PASSWORD` from the LiteLLM service variables\nBack up `LITELLM_SALT_KEY`, since it encrypts the stored provider keys.\n\nLinks: template [https://railway.com/deploy/litellm-ai-gateway-1](https://railway.com/deploy/litellm-ai-gateway-1) · repo [https://github.com/TalhaRamzan/railway-litellm-gateway](https://github.com/TalhaRamzan/railway-litellm-gateway) · LiteLLM [https://github.com/BerriAI/litellm](https://github.com/BerriAI/litellm)\n\n*Disclosure: I built this template. Unofficial, not affiliated with BerriAI.*", "url": "https://wpnews.pro/news/self-host-a-litellm-ai-gateway-on-railway-one-api-for-100-llms-with-budgets-and", "canonical_source": "https://dev.to/talha_ramzan_3878156fea8c/self-host-a-litellm-ai-gateway-on-railway-one-api-for-100-llms-with-budgets-and-virtual-keys-4jd3", "published_at": "2026-11-27 19:32:30+00:00", "updated_at": "2026-11-27 19:44:44.922048+00:00", "lang": "en", "topics": ["ai-infrastructure", "large-language-models", "ai-tools"], "entities": ["LiteLLM", "Railway", "BerriAI", "OpenAI", "Anthropic", "OpenRouter", "Gemini"], "also_reported_by": [], "takeaway": "Self-hosting LiteLLM behind one OpenAI-compatible endpoint lets you issue per-app virtual keys with budgets and spend tracking instead of copying provider keys into every app, and the template pins stable image tags and requires backing up LITELLM_SALT_KEY to keep stored provider keys decryptable.", "recommendation": null, "alternates": {"html": "https://wpnews.pro/news/self-host-a-litellm-ai-gateway-on-railway-one-api-for-100-llms-with-budgets-and", "markdown": "https://wpnews.pro/news/self-host-a-litellm-ai-gateway-on-railway-one-api-for-100-llms-with-budgets-and.md", "text": "https://wpnews.pro/news/self-host-a-litellm-ai-gateway-on-railway-one-api-for-100-llms-with-budgets-and.txt", "jsonld": "https://wpnews.pro/news/self-host-a-litellm-ai-gateway-on-railway-one-api-for-100-llms-with-budgets-and.jsonld"}}