FreeLLMAPI
FreeLLMAPI routes free LLM provider tiers and custom OpenAI-compatible endpoints through one /v1 API, adding smart routing, automatic failover, encrypted keys, and a self-updating catalog.
Visit tashfeenahmed/freellmapiOverview
FreeLLMAPI is an open-source, self-hosted, single-user router that aggregates free tiers from dozens of LLM providers and custom OpenAI-compatible endpoints behind one OpenAI-compatible /v1 API. It stores provider keys encrypted, routes across models and providers, fails over when a provider is rate-limited, and tracks per-key usage to stay within free-tier caps. The sources cite roughly 7.4 billion free tokens per month across the aggregated free tiers.
Key Features
- One OpenAI-compatible /v1 endpoint covering chat, responses, completions, images, videos, audio, embeddings, and models, with streaming and non-streaming support.
- Anthropic Messages API compatibility at /v1/messages, plus native Gemini /v1beta and opt-in Ollama emulation surfaces.
- Smart routing with six strategies, automatic failover on 429/5xx, cooldowns, key rotation, and unified model profiles with fallback chains.
- Per-key RPM/RPD/TPM/TPD rate tracking that learns provider-reported ceilings to keep requests under free-tier caps.
- Provider keys are AES-256-GCM encrypted in SQLite and decrypted in memory per request; applications see one unified bearer token.
- Self-updating signed model catalog, an admin dashboard with analytics, and an MCP server with an OpenAPI viewer.
Use Cases
- Point OpenAI-compatible SDKs and clients at a local router to use free provider tiers through one base URL and unified key.
- Run coding agents and CLIs such as Claude Code, Codex CLI, Gemini CLI, Cursor, Cline, Roo Code, OpenCode, and Aider against the aggregated pool.
- Experiment with multi-model synthesis through the virtual fusion model, which fans a prompt to diverse free models and synthesizes one answer.
- Generate images, video, and speech through supported media endpoints, including custom OpenAI-compatible media endpoints.
Getting Started
- Run the Docker-based install script, open the local dashboard on port 3001, add provider keys on the Keys page, reorder the Fallback Chain, and copy the unified API key.
- For supported coding agents, use the provided npx freellmapi setup commands with the local router URL and unified key to merge configuration automatically.
Deployment & Requirements
- Docker is required for the one-liner installer.
- The router runs anywhere Node 20+ runs, including Windows, macOS, Linux servers, or a small ARM SBC such as a Raspberry Pi.
- Desktop builds are available for macOS 12 Monterey or later and for Windows through installers from Releases.
- Provider keys are stored in a local SQLite database and encrypted at rest.
Before You Adopt
- License: MIT. Review its terms before using, modifying, or distributing the project.
- The project is intended for personal, single-user use and should not be exposed publicly.
- Free-model availability depends on provider allowances and temporary promotions, so access can vary.
- The stated scope is personal experimentation only.