Chapter 2

Installation

LocalAI can be installed in multiple ways depending on your platform and preferences.

Installation Methods

Choose the installation method that best suits your needs:

  1. ContainersRecommended - Works on all platforms, supports Docker and Podman
  2. macOS - Download and install the DMG application
  3. Linux - Install on Linux using binaries
  4. Kubernetes - Deploy LocalAI on Kubernetes clusters
  5. Build from Source - Build LocalAI from source code

Quick Start

Recommended: Containers (Docker or Podman)

# With Docker
docker run -p 8080:8080 --name local-ai -ti localai/localai:latest

# Or with Podman
podman run -p 8080:8080 --name local-ai -ti localai/localai:latest

This will start LocalAI. The API will be available at http://localhost:8080. For images with pre-configured models, see All-in-One images.

For other platforms:

For detailed instructions, see the Containers installation guide.