tashfeenahmed/freellmapi
An open-source router that stitches 34 free LLM tiers into one API key so your app never hits a rate limit
FreeLLMAPI is a self-hosted TypeScript server that combines the free tiers of 34 AI providers (Google, Groq, Mistral, OpenRouter, HuggingFace and more) into a single OpenAI-compatible endpoint. It routes each request to whichever free model is available, automatically switches providers when one is rate-limited, and encrypts your provider keys in a local database. The project reports 474 model families and 635 free endpoints, adding up to roughly 7.4 billion free tokens per month across all providers combined.
What it does
- What it does: exposes one unified API (/v1/chat/completions and similar OpenAI-style routes) that sits in front of 34 separate free-tier AI providers plus any custom OpenAI-compatible server.
- How it works: a router scores available models on speed/reliability, tries the best one first, falls back to the next provider automatically on rate-limit or server errors, and tracks usage per key so you never exceed a provider's free quota.
- Setup: a one-line install script runs a Docker container locally; you add provider keys through a web dashboard, then point any OpenAI SDK or coding assistant (Claude Code, Codex CLI, Cursor, etc.) at your local server.
- Security model: provider API keys are AES-256-GCM encrypted in a local SQLite database and decrypted only in memory per request; your apps only ever see one unified token.
- Scope and caution: the README explicitly labels this a personal-experimentation project, not a production service, since free tiers can change or disappear without notice.
Why it matters
For hobbyists and developers testing AI features, this removes the tedious work of juggling dozens of provider SDKs, keys, and rate limits by hand. It's a useful reference for anyone building request-routing or failover logic for LLM APIs, though the maintainers themselves warn against relying on it for real production traffic.
Terms in this repo
- OpenAI-compatible endpoint · A server that accepts requests in the same format as OpenAI's API, so existing OpenAI client libraries work without modification
- Rate limit / 429 · A cap providers put on how many requests or tokens you can send in a given time; exceeding it returns an error
- Failover · Automatically switching to a backup provider or model when the first one fails or is unavailable
- AES-256-GCM · An encryption method used to protect stored data, in this case the saved provider API keys
- MCP server · A protocol interface that lets AI agents query and interact with a tool or service programmatically
Repository description (English)
plus any custom OpenAI-compatible endpoint. Smart routing, automatic failover, encrypted keys. Personal experimentation only.
Open on GitHubTrending repos
- vorssaint/vorssaint-utilsOne free menu bar app replaces a dozen paid Mac utilities
- MadsLorentzen/ai-job-searchAn open-source framework that runs your entire job search through Claude Code, built by someone who actually got hired using it
- rohitg00/ai-engineering-from-scratchA free hands-on curriculum that teaches AI by having you build every piece from scratch, from math to shippable agents
- AgriciDaniel/claude-obsidianAn open-source second brain that lets Claude Code file your notes into Obsidian while you keep full ownership of the files
- openclaw/openclawA personal AI assistant that lives on your own devices and talks to you through the messaging apps you already use
- Alishahryar1/free-claude-codeA local proxy that lets coding AI agents run on 49 free or cheap model providers instead of one paid service
- freestylefly/awesome-gpt-image-2A library of 532 reverse-engineered prompts that turn GPT-Image2 into a predictable image-making tool
- block/buzzAn open-source workspace where humans and AI agents chat, code, and review in the same rooms
Latest from METAL LAB
- ChatGPT Work now turns spoken thoughts into finished documents
- 100-Rally Match Against World No. 15... The Robot on Court Was Unveiled Three Days Earlier
- Robot 100m in 9.32 Seconds Beats Bolt in Heats, But Foam Pads Wait at the Finish Line
- NVIDIA in talks to invest in Perplexity at $30 billion-plus valuation
- Inside Sakana AI — the $2.7 billion company a Transformer author built in Tokyo