# Install localai with Homebrew, Nix

OpenAI alternative. Version 4.6.2 via Homebrew; verified 2026-07-06.

## Install

```sh
sudo av install brew:localai
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install localai
```

  Evidence: local Homebrew formula metadata

### Linux

- Nix (92%):

```sh
nix profile install nixpkgs#local-ai
```

  Evidence: nixpkgs package indexes: pkgs/by-name/lo/local-ai/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

## Package facts

- **Package key:** brew:localai
- **Package manager:** Homebrew
- **Package manager page:** <https://formulae.brew.sh/formula/localai>
- **Version:** 4.6.2
- **Source summary:** OpenAI alternative
- **Homepage:** <https://localai.io>
- **Repository:** <https://github.com/mudler/LocalAI>
- **Upstream docs:** <https://localai.io>
- **License:** MIT
- **Source archive:** <https://github.com/mudler/LocalAI/archive/refs/tags/v4.6.2.tar.gz>
- **Last updated:** 2026-07-06T21:40:19Z
- **Generated:** 2026-07-08T07:18:31+00:00

## Executables

- local-ai (cli)
- local-ai (alias)

## Build dependencies

- go
- node
- protobuf
- protoc-gen-go
- protoc-gen-go-grpc

## Install behavior

- Post-install hook: not defined
- Bottle: available on arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux

## Freshness

- Page generated: 2026-07-08
- Package-manager version: 4.6.2
- Package-manager updated: 2026-07-06
- Local data: ok
- Upstream repository: https://github.com/mudler/LocalAI
- Upstream latest detected: v4.6.2 (current)
## Project history and usage

LocalAI is an open-source local AI inference server and CLI that exposes OpenAI-compatible APIs for self-hosted models. It began in the 2023 local-LLM wave and grew from a local OpenAI API replacement into a broader multimodal AI engine with model galleries, backend management, web UI, agents, and distributed operation.

### Project history

The mudler/LocalAI repository was created in March 2023. The README describes LocalAI as an open-source AI engine for LLMs, vision, voice, image, and video on local hardware, with no GPU required and privacy-first operation because data stays on the user's infrastructure.

In 2023, LocalAI focused on making local models usable behind OpenAI-compatible endpoints. Official news from mid-2023 records rapid support for model galleries, GPU offload, Apple Metal, Falcon-family models, Hugging Face backends, stable-diffusion, text-to-audio, and static Linux binaries. A late-2023 maintainer update described a move toward a gRPC backend structure and a C++ llama.cpp backend to track upstream more closely.

By 2025 and 2026, LocalAI had expanded into a modular backend architecture. The v3.0.0 announcement introduced a backend gallery based on OCI images, realtime WebSocket APIs, dynamic VRAM handling, multimodal upgrades, and deprecation of older extras images. The v4.0.0 announcement framed the project as a complete AI orchestration platform with agents, Agenthub, a React UI rewrite, Canvas mode, MCP support, WebRTC realtime audio, and more backends.

### Adoption history

LocalAI rode the demand for self-hosted, OpenAI-compatible inference after local LLM tooling became mainstream in 2023. Its adoption signals are unusually strong for a CLI/server package: the official repository shows tens of thousands of stars, thousands of forks, and thousands of commits, while Homebrew and Nix packaging make the binary accessible outside container workflows.

The project broadened adoption by supporting multiple install styles: container images for CPU and GPU targets, binaries for Linux and macOS, model-gallery installs, and a local-ai CLI that can run models and open chat sessions. Its compatibility story also widened from OpenAI-style APIs to Anthropic Messages, Open Responses, Ollama-related workflows, and MCP-enabled agents.

### How it is used

Users commonly run LocalAI as a local server, then point OpenAI-compatible SDKs or clients at localhost. The getting-started guide documents curl requests to /v1/chat/completions, model installation from the gallery, automatic backend detection based on GPU capabilities, built-in agents, and distributed mode for production or larger compute needs.

The Homebrew formula installs the local-ai executable, but official docs still treat containers as the fullest-feature path because some Python-based and heavy media backends are not included in all binaries. The binary reference documents direct Linux and macOS downloads and notes backend limitations for binary builds.

### Why package nerds care

LocalAI is package-nerd significant because it turns a fast-moving stack of model runtimes, backends, APIs, and hardware-specific acceleration into one installable command. It is the sort of package where the formula is only the visible tip; the real work is coordinating llama.cpp, vLLM, whisper.cpp, stable-diffusion, MLX, OCI backends, GPU variants, and API compatibility.

It also captures a packaging shift in AI tooling: instead of a single static CLI, LocalAI became a launcher and orchestrator that downloads or connects model and backend artifacts at runtime. That makes it attractive to self-hosters and developers, but also means package metadata must clearly distinguish the CLI/server from the larger optional backend ecosystem.

### Timeline

- 2023: The mudler/LocalAI repository is created and early releases focus on local OpenAI-compatible inference.
- 2023: v1.x news records model galleries, GPU offload, Apple Metal support, text-to-audio, static binaries, and backend refactoring.
- 2025: v3.0.0 introduces the backend gallery, realtime WebSocket API, dynamic VRAM handling, and a new modular backend model.
- 2026: v4.0.0 adds native agents, Agenthub, React UI, Canvas mode, MCP support, WebRTC realtime audio, and additional backends.
- 2026: Official README highlights support for 60+ backends, multiple hardware accelerators, multimodal APIs, and distributed mode.

### Related projects

- llama.cpp, vLLM, whisper.cpp, stable-diffusion, MLX, and other model runtimes are backend building blocks named by the LocalAI README.
- OpenAI-compatible SDKs and clients are primary integration targets because LocalAI exposes compatible API endpoints.
- Ollama, GPT4All, and other local-model tools sit in the same self-hosted inference ecosystem, while LocalAI differentiates itself through broad API compatibility and backend orchestration.

### Sources

- <https://api.github.com/repos/mudler/LocalAI>
- <https://github.com/mudler/LocalAI>
- <https://github.com/mudler/LocalAI/discussions/1222>
- <https://github.com/mudler/LocalAI/discussions/5689>
- <https://github.com/mudler/LocalAI/discussions/9006>
- <https://localai.io/basics/getting_started/>
- <https://localai.io/basics/news/index.html>
- <https://localai.io/reference/binaries/>


## Security Notes

No matching local secret-handling manifest was found for localai. Nucleus package metadata is still published here so future coverage has a stable package URL.


## Source Database Details

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** localai
- **Version Scheme:** 0
- **Revision:** 0
- **Head Version:** HEAD
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** head, stable

## Other Package-Manager Records

- Nix - local-ai: installed executable or alias match | nixpkgs package indexes: pkgs/by-name/lo/local-ai/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1


## Related links

- [MCP tool packages](https://www.automicvault.com/pkg/mcp-tools/) - Mentions MCP or Model Context Protocol.
- [Terminal utility packages](https://www.automicvault.com/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Text processing packages](https://www.automicvault.com/pkg/text-processing-tools/) - Matched text, document, or structured-data processing metadata.
- [Developer build packages](https://www.automicvault.com/pkg/developer-build-tools/) - Matched build, compiler, generator, or developer workflow metadata.
- [go](https://www.automicvault.com/pkg/brew/go/) - Build dependency declared by Homebrew.
- [node](https://www.automicvault.com/pkg/brew/node/) - Build dependency declared by Homebrew.
- [protobuf](https://www.automicvault.com/pkg/brew/protobuf/) - Build dependency declared by Homebrew.
- [protoc-gen-go](https://www.automicvault.com/pkg/brew/protoc-gen-go/) - Build dependency declared by Homebrew.
- [context7-mcp](https://www.automicvault.com/pkg/brew/context7-mcp/) - Shares av.db curated category or tags: ai, cli, developer-tools, llm.
- [fabric-ai](https://www.automicvault.com/pkg/brew/fabric-ai/) - Shares av.db curated category or tags: ai, cli, developer-tools, llm.
- [gollama](https://www.automicvault.com/pkg/brew/gollama/) - Shares av.db curated category or tags: ai, cli, developer-tools, llm.
- [gptme](https://www.automicvault.com/pkg/brew/gptme/) - Shares av.db curated category or tags: ai, cli, developer-tools, llm.
- [gptscript](https://www.automicvault.com/pkg/brew/gptscript/) - Shares av.db curated category or tags: ai, cli, developer-tools, llm.
- [mods](https://www.automicvault.com/pkg/brew/mods/) - Shares av.db curated category or tags: ai, cli, developer-tools, llm.
- [repomix](https://www.automicvault.com/pkg/brew/repomix/) - Shares av.db curated category or tags: ai, cli, developer-tools, llm.
- [aichat](https://www.automicvault.com/pkg/brew/aichat/) - Shares av.db curated category or tags: ai, cli, developer-tools.
- [shimmy](https://www.automicvault.com/pkg/brew/shimmy/) - Local package facts share a topical domain. Shared terms: ai, cli, compatible, developer, developer-tools.
- [ollama](https://www.automicvault.com/pkg/brew/ollama/) - Local package facts share a topical domain. Shared terms: ai, cli, developer, developer-tools, llm.

## Combined YAML source

View the package source record on GitHub. [combined/localai.yml](https://github.com/automic-vault/db/blob/main/combined/localai.yml)


## Sources

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
