LocalAI
Self-hosted, drop-in OpenAI API replacement for local models.
Overview
LocalAI is an open-source server that exposes OpenAI-compatible endpoints for text, images, audio and embeddings using local models. It lets existing OpenAI-based apps run entirely on your own hardware.
- OpenAI-compatible API
- Text, image and audio
- Multiple backends
- P2P inference
Our verdict
What we like
- Swap out OpenAI without code changes
- Runs without GPU
Watch out for
- Configuration can be involved
Works with these providers
Keys from these providers work in this app. Usage is billed by the provider at its list price.
BYOK Key Safety Score
Key handling in LocalAI
Grade B
Your key is stored by the service (usually encrypted) and requests may route through its servers.
- Key storage18/40
Key is held by the vendor, so you rely on their security.
- Auditable code25/25
Open source: anyone can verify how keys are handled.
- Self-hosting15/15
Can run entirely on your own infrastructure.
- Offline option10/10
Supports local models, so no key is needed at all for private work.
- Provider choice2/10
1 provider option, which lets you pick the provider whose data terms you trust.
Whatever the score, give each app its own key, set a monthly spend limit with your provider, and revoke keys you no longer use. Read the key-safety checklist.
LocalAI FAQ
- Does LocalAI support bring your own key?
- Yes. LocalAI accepts your own API key from OpenAI-compatible. Usage is billed by the provider at its API rates.
- Where does LocalAI store my API key?
- On the vendor's servers, and requests may be routed through them. Its BYOK Tools Key Safety Score is 70/100.
- Is LocalAI free?
- Open source: Free & open source. API usage is billed separately by your model provider.
- Is LocalAI open source?
- Yes. The source code is at https://github.com/mudler/LocalAI. It can also be self-hosted.
- Can LocalAI run local models?
- Yes. It can connect to local runtimes such as Ollama or LM Studio, so no API key is needed for private or offline use.
- Which platforms does LocalAI support?
- Self-hosted, Linux, macOS, Windows.
Community reviews
No reviews yet.
Alternatives to LocalAI
All local ai →llama.cpp
Local AI
C and C++ LLM inference engine with a built-in server and web UI.
Text Generation WebUI
Local AI
Gradio web UI for running local LLMs with many backends.
Hollama
Local AI
Minimal web UI for Ollama and OpenAI-compatible servers.
Jan
Local AI
Open-source ChatGPT alternative that runs 100% offline.
Ollama
Local AI
The simplest way to run open LLMs locally with one command.
LM Studio
Local AI
Desktop app to discover, download and run local LLMs.