Skip to main content
OpenSourceAlternatives

LLM Gateway

Open source · OSI-approvedStatus: unknownNew

Open-source, OpenAI-compatible LLM gateway with cost and latency tracking

LLM Gateway is a small open-source project that puts calls to OpenAI, Anthropic, and Gemini behind one OpenAI-compatible API. It serves developers and small engineering teams that run LLM features across more than one provider and want unified keys, spend tracking, and fallbacks without adopting a large gateway platform.[1][2]

Quick verdict

Small teams routing LLM calls across OpenAI, Anthropic, and Gemini will get the most from LLM Gateway. One OpenAI-compatible endpoint with gateway-issued keys, per-request cost and latency logging, and automatic provider fallback replaces per-provider glue code in a compact Python codebase. The constraint is maturity and breadth: it is a young single-maintainer project covering three providers, so teams needing many providers, SSO, or support SLAs should choose a larger gateway instead. If you have engineers and want a small self-hosted router on your own network, start with the free MIT-licensed build; if you need 100+ providers or enterprise controls, evaluate LiteLLM instead.[1][2]

Key features

  • One OpenAI-compatible endpoint for three providers Chat completions and models endpoints accept existing OpenAI SDK calls and route them to OpenAI, Anthropic, or Gemini, so adoption rarely means rewriting application code.[1][2]

  • Gateway-issued API keys Keys are created in the admin API and sent as bearer tokens, giving each caller its own credential instead of sharing raw provider keys.[1]

  • Per-request cost, latency, and token logging Each call records what it spent, how long it took, and how many tokens it used, which is the raw material for spend inspection.[1]

  • Retries with backoff plus automatic fallback Failed calls retry with exponential backoff and can fall over to another provider or key, so traffic keeps flowing when one backend fails.[1]

  • Streaming responses Token streams pass through the gateway, keeping interactive chat behavior intact behind the unified endpoint.[1]

  • React admin dashboard A small web UI shows usage and manages keys without editing configuration files by hand.[1][2]

  • SQLite or PostgreSQL storage Single-file SQLite covers trials and small deploys, while PostgreSQL is documented for anything larger.[1]

  • Container-first deployment A Docker Compose quickstart brings up the API, dashboard, and database together from one command.[1][2]

Who will love it

  • Small teams juggling two or three providers: one endpoint, one key format, and per-request cost logs remove the spreadsheet-and-glue-code stage of multi-provider use without new infrastructure to learn.[1]

  • Cost-watchers on a budget: per-request cost, latency, and token records plus a self-hosted footprint attack unmeasured usage directly, and the MIT licence adds no software fee.[1][2]

  • Tinkerers who read the source: a compact FastAPI and LiteLLM codebase with 44 documented tests is easy to audit, fork, and extend for teams comfortable owning their tools.[1][2]

Who should avoid it

  • Teams needing broad provider coverage: only OpenAI, Anthropic, and Gemini are documented, so anyone routing across Bedrock, Vertex, Azure, or local models will hit the boundary immediately.[1]

  • Buyers needing SSO, audit, or support: no enterprise plan, identity integration, or SLA is documented, and operation rests entirely on the adopter.[1][2]

  • Anyone wanting a proven track record: two stars, two forks, and a single-maintainer history mean the project's future depends on one person, which is a real continuity risk for production dependencies.[1]

Alternatives and compatibility

LiteLLM at /projects/litellm is the closest direct substitute, routing model calls through one OpenAI-compatible API across 100+ providers with budgets and guardrails. Choose LiteLLM when provider breadth, team controls, or enterprise support matter; choose LLM Gateway when a smaller three-provider codebase you can fully audit matters more. No catalogue edge is asserted for this comparison.[1][2]

Because LLM Gateway speaks the OpenAI API, migration in either direction is usually a base-URL change plus provider credentials, which keeps the routing decision reversible. Provider token billing stays with the underlying providers in every case.[1]

Questions worth asking

What is the best LLM Gateway alternative for non-technical users?

Neither LLM Gateway nor its closest open-source rivals fit non-technical users, since all are configured container infrastructure consumed through code. A managed hosted gateway with a console fits better, though no head-to-head evidence for a specific pick was gathered in this pass.[1][2]

Is LLM Gateway really no-code?

No. Providers, keys, fallbacks, and deployment are defined in configuration and containers, and the API is consumed through client code. Plan for engineering involvement from setup onward.[1]

How much does LLM Gateway cost per month?

The software itself is free under the MIT licence checked October 11, 2026, with no paid tier documented. Provider token bills remain separate, and hosting costs are whatever the operator's container runtime costs.[1][2]

Can you self-host LLM Gateway?

Yes. That is its only documented mode: a Docker Compose quickstart runs the API, dashboard, and database on the operator's own machine against SQLite or PostgreSQL. You still operate the deployment yourself.[1]

Sources and editorial review

Source research. Reviewed on October 11, 2026. Written by Sanjib Sah. AI assisted; reviewed by a human editor.

We have not run or tested this product.

  1. github.com vahid8/llm-gateway

    official · Observed October 11, 2026

    Repository page: product identity, MIT license, Python, 2 stars/2 forks, 22 commits, created May 2026, FastAPI plus LiteLLM plus React dashboard.

  2. vahid8/llm-gateway README

    official · Observed October 11, 2026

    README: OpenAI-compatible /v1 API, gateway-issued keys, cost/latency/token logging, retries with fallback, streaming, Docker Compose quickstart, SQLite/PostgreSQL, dashboard, MIT license.

  3. varunahuja70/LLM-Gateway (identity check)

    official · Observed October 11, 2026

    Same-named repo inspected only to disambiguate identity; not used for fact evidence.

Compared with these products

No explicit proprietary baseline is recorded.

Similar projects

Related projects with shared categories, technologies, or licensing.

LiteLLM

LiteLLMAIOpen

Open-source AI gateway unifying 100+ LLMs behind one API

Stars60.1K
Commitjust now
LicenseMIT

LiteLLM is an open-source AI gateway that calls more than 100 large language model providers through one OpenAI-compatible interface.

LocalAI

LocalAIAIOpen

Self-hosted OpenAI-compatible runtime for local AI models

Stars49.5K
Commitjust now
LicenseMIT

LocalAI is a self-hosted runtime that runs AI models locally behind OpenAI-compatible endpoints.

Bifrost

BifrostOpen

Self-hosted LLM gateway with one OpenAI-compatible API

Stars8,531
Commitjust now
LicenseApache-2.0

Bifrost is a self-hosted gateway that puts every large language model call behind one OpenAI-compatible API. An application points its existing OpenAI client at the gateway, and Bifrost routes the request to whichever provider is configured, so switching models or spreading load across providers is a configuration change rather than a rewrite.

Envoy AI Gateway

Envoy AI GatewayAIOpen

Self-hosted AI gateway routing LLM traffic through Envoy

Stars2,182
Commitjust now
LicenseApache-2.0

Envoy AI Gateway is a self-hosted gateway that routes application traffic to 17 language model providers through one OpenAI-compatible API.

Ollama

OllamaAIOpen

Run open language models locally with one command

Stars179.9K
Commit14h ago
LicenseMIT

Ollama reduced local model hosting from an afternoon of CUDA troubleshooting to a single pull command. It handles model download, quantisation selection, GPU offloading, and memory management, and exposes an OpenAI-compatible endpoint on localhost.

llama.cpp

llama.cppAIOpen

Inference engine that runs LLMs on almost any hardware

Stars126.6K
Commit8h ago
LicenseMIT

llama.cpp is the layer most local model tooling is built on. It is a C and C++ inference engine with no Python runtime, aggressive quantisation support, and hand-tuned kernels for a remarkably wide range of hardware.