Skip to content
Home About Services Portfolio Blog Contact Get Started
AI & Automation

Free LLM API Aggregator: Inside FreeLLMAPI, the Open-Source Router Stacking 34 Free Providers

Written by

MTD Technologies

Published
Read Time 9 min
Free LLM API aggregator routing many free providers through one endpoint

A free LLM API aggregator sounds like a contradiction. Free tiers from AI providers are famously small: a few million tokens here, a few thousand requests there, each behind its own SDK, rate limit, and way of failing. FreeLLMAPI, an open-source project with more than 42,000 GitHub stars, stacks those free tiers together behind a single OpenAI-compatible endpoint. In this deep-dive you will learn what it does, how its routing and failover work, what it costs, where it breaks down, and whether it belongs in your team’s workflow.

This is written for developers, founders, and small teams wondering whether free inference can carry real work. For an agency or product team, the question matters at scale: every unpaid token is margin, but only if the free route is reliable enough to build on.

What FreeLLMAPI is

FreeLLMAPI is a self-hosted router. Install it on your own machine or server — via Docker, a desktop app for macOS and Windows, or from source on any system running Node 20 or newer — add the free API keys you hold from providers such as Google, Groq, Cerebras, Mistral, OpenRouter, Cloudflare, Cohere, Z.ai, NVIDIA, and HuggingFace, and point any OpenAI-compatible client at one local address: http://localhost:3001/v1. Your applications only ever see a single unified key. Behind it, the router decides which provider serves each request.

The headline numbers, from the project’s own GitHub repository and official site in October 2026, are striking: 34 free providers, 474 model families, and 635 free endpoints, totalling roughly 7.4 billion tokens per month of listed free-tier capacity — 584 chat, 41 embedding, 7 transcription, 3 video. Treat that total as a ceiling, not a promise: it sums every provider’s allowance, and no single user will use all of it. But it explains the project’s appeal — individually, free tiers are toys; stacked, they start to look like infrastructure.

The project is MIT-licensed, written in TypeScript, and actively maintained: at the time of writing it holds around 42,609 stars and 5,756 forks, and it was updated within the last day. It is local-first and single-user by design. Provider keys are encrypted with AES-256-GCM in a local SQLite database and decrypted in memory per request, and requests travel from your machine to the upstream providers you enabled — the router’s own catalog server never sees your prompts, completions, or keys.

Free LLM API aggregator routing many free providers through one endpoint

What it can do

FreeLLMAPI covers far more than plain chat completions. It exposes the OpenAI-style surfaces most tools expect — chat completions, the responses endpoint Codex CLI needs, legacy completions for editor ghost-text, image and video generation, speech and transcription, embeddings, and a models list — streaming and non-streaming. It also speaks Anthropic’s Messages API, so Claude Code runs against the same free pool, plus native Gemini and Ollama surfaces for Gemini CLI, Zed, and JetBrains AI.

  • Smart routing, six strategies: live speed, capability, and reliability scores rank your chain; failover retries the next model on 429 or 5xx errors, with cooldowns and key rotation.
  • Unified models and profiles: the same model on several providers collapses into one entry, and named fallback-chain profiles — a coding chain, a vision chain — switch from the dashboard or per request.
  • Fusion: request the virtual fusion model and the router fans your prompt out to a panel of free models in parallel, then a judge model synthesises one answer.
  • Per-key rate tracking: counters per provider, model, and key learn each provider’s ceilings, so routing stays under every cap.
  • Tool calling and structured outputs: OpenAI-style tools round-trip across providers, with plain-text tool calls rescued into real tool calls.
  • Sticky sessions: conversations stay on one model for 30 minutes, with an optional handoff note if a mid-chat switch happens.
  • Opt-in prompt compression: a fail-open pipeline deduplicates prompts, filters tool output, and trims stale context before routing.
  • Dashboard and analytics: a React UI manages keys, reorders the chain, runs a playground, and shows latency percentiles over 24-hour to 90-day windows, in 60 languages.
  • MCP server: ChatGPT and other MCP clients can call inference, list usable models, and inspect provider health and routing metadata over /mcp.

One-command setup generators exist for Claude Code, Codex CLI, Gemini CLI, Cursor, Cline, OpenCode, Aider, and many more. For Claude Code, the command reads your live catalog, backs up the existing config, and merges into it:

npx freellmapi setup-claude --url http://localhost:3001 --api-key <unified-key>

How it works under the hood

The architecture is deliberately narrow. FreeLLMAPI is not a model host or a proxy reselling inference. It is a routing layer you run yourself, roughly 40 MB of memory at idle, that translates each request into the right upstream call and learns from the result. Three design choices do most of the work.

First, the model catalog is signed and self-updating. The router pulls it from freellmapi.co twice a day — new models, quota changes, quirk fixes — with every download verified against a pinned Ed25519 key. Free installs track the monthly snapshot, so a model reaches them about 30 days after joining the live feed; a premium feed — 19 dollars a year or 49 dollars once — delivers it the same day. Your enable and disable choices are never overwritten. That matters because free tiers shift weekly: providers launch, retire, and re-quota models without notice.

Second, routing is score-driven, not round-robin. Live speed, capability, and reliability scores set the chain order. When a provider rate-limits you, the router cools that model down and moves on instead of retrying the same failing key.

Third, custom providers close the gap between free and local. From the Keys page you can point chat, embedding, image, or audio models at any OpenAI-compatible endpoint — llama.cpp, LM Studio, vLLM, a local Ollama instance, or a remote gateway. One front door then serves free cloud models and your own local models alike.

Free LLM API aggregator automatic failover routing illustration

FreeLLMAPI’s surge reflects a larger shift. Coding agents are everyday tools now, and their token appetite is enormous: one agent session can burn thousands of tokens per task. Every major lab also maintains a free tier as a funnel — generous enough to hook developers, too small to run a business on alone. A router aggregating those tiers is the obvious arbitrage, and open source is the obvious delivery: developers will hand API keys to a tool they can read, self-host, and audit far more readily than to a black-box middleman.

The timing helps too. Agent harnesses have standardised on OpenAI-compatible endpoints, so one router serves dozens of tools without per-tool integration work. And the project’s scope — a router, a dashboard, a catalog — is small enough to trust and large enough to be useful. Unlike general gateways such as OpenRouter, LiteLLM, or Portkey, it is free, local, and aimed squarely at squeezing free tiers.

From our experience: where free inference helps, and where it does not

At MTD Technologies, we have spent nine-plus years shipping web, mobile, and AI systems across more than 300 projects. The pattern with free tiers is consistent: excellent for learning and prototyping, dangerous as the sole foundation of a paying product. Three lessons apply directly here.

First, measure quality per task, not per model. A free model that writes decent boilerplate may fail at precise tool calls or long-context reasoning. Run your actual prompts across two or three candidate models and score the outputs first: the router’s analytics measure latency and availability, not whether the answer was right.

Second, design for provider churn. Free tiers change without notice: a model is retired, a quota halves, a rate limit tightens. FreeLLMAPI’s catalog and failover soften that, but do not remove it. Any workflow that must not fail — a customer-facing chatbot, a nightly report — needs a paid fallback in the chain or a graceful degradation path, such as queueing and retrying later. Free-only is fine for experiments; it is not a service-level agreement.

Third, keep key hygiene boring. The router encrypts keys at rest, but you still own the upstream accounts: use separate keys per environment, rotate them when a team member leaves, and never paste a key into a shared chat or repository. The project’s own description sets a boundary — personal experimentation only — so review each provider’s terms before routing client or sensitive data.

Getting started with FreeLLMAPI

The fastest path is Docker. The one-liner below sets up a ~/freellmapi directory, generates an encryption key, pulls the image, and starts the container; re-running it is safe, since your configuration and key are preserved. Read the install script before piping it to bash, as the project itself recommends.

curl -fsSL https://freellmapi.co/install.sh | bash

  1. Install and open the dashboard at http://localhost:3001.
  2. Add your provider keys on the Keys page — start with two or three providers you already use, not all 34 at once.
  3. Reorder the fallback chain, putting the models you trust for your main task first.
  4. Copy your unified API key from the Keys page header.
  5. Point an OpenAI-compatible client at http://localhost:3001/v1 with that key, or run a setup generator such as the Claude Code command above.
  6. Send a test request, check the X-Routed-Via response header to see which provider actually served it, and watch the dashboard’s usage counters before scaling up.

A minimal Python test, adapted from the project’s own docs, shows how little changes in client code:

from openai import OpenAI
client = OpenAI(base_url="http://localhost:3001/v1", api_key="YOUR-UNIFIED-KEY")
resp = client.chat.completions.create(model="auto", messages=[{"role": "user", "content": "Summarise the fall of Rome in one sentence."}])

From there, run a small pilot: one internal tool, one week, with usage and quality logged. If the free pool carries it, expand to a second workflow; if not, you have learned something cheap — and you still have a working router for paid and local models. For related tooling, see our AI Tools Directory, or talk to us about an AI integration scoped to real usage.

Free LLM API aggregator dashboard illustration for developers

Frequently asked questions

Is FreeLLMAPI really free?

Yes, the router is MIT-licensed and free forever. You still need your own free keys from each upstream provider, under their limits. An optional premium feed — 19 dollars a year or 49 dollars once — only speeds up catalog updates.

What happens when a free provider rate-limits me?

The router retries the next model in your chain, with cooldowns and key rotation, and per-key counters help it stay under each cap. One rate limit should slow a request, not fail it — but if every provider in a chain is exhausted, it will fail, which is why paid or local fallbacks matter for critical work.

Can I use FreeLLMAPI with Claude Code, Cursor, and Codex?

Yes. Setup generators exist for Claude Code, Codex CLI, Gemini CLI, Cursor, Cline, OpenCode, Aider, and more, and any OpenAI-compatible client works by pointing at the local endpoint. The router also speaks Anthropic’s Messages API, which Claude Code needs.

Is my data private when using a free LLM API aggregator?

Partly. Keys are encrypted at rest and the catalog server never sees your prompts, but each request still goes to the upstream provider that serves it, under that provider’s terms. Keep sensitive data on local models or paid APIs with proper agreements; use free tiers for experiments and public data.

Should a business run production workloads on free tiers?

Not as the sole foundation. Free tiers change without notice and carry no service-level agreement. Use them for prototyping, internal tools, and batch work with a paid or local fallback — and measure quality per task before anything customer-facing depends on them.

FreeLLMAPI is worth trying because the trial is cheap: an afternoon, a Docker container, and keys you already have. It will not turn free tiers into a paid API, but it does turn a scattered pile of small allowances into one usable, observable endpoint. Start small, watch the dashboard, and let measured results — not the 7.4-billion-token headline — decide how far free inference goes in your stack.