---
title: "Deploy AIRI Self-Hosted AI Companion"
description: "AIRI self-hosted AI companion with avatars, local chat and voice."
category: "AI/ML"
url: https://railway.com/deploy/airi-self-hosted-ai-companion
---

# Deploy AIRI Self-Hosted AI Companion

AIRI self-hosted AI companion with avatars, local chat and voice.

**[Deploy AIRI Self-Hosted AI Companion on Railway](https://railway.com/template/airi-self-hosted-ai-companion)**

Machine-readable deploy manifest (JSON, validated by TemplateCI): https://railway.com/deploy/airi-self-hosted-ai-companion/manifest.json

- **Creator:** Xav's Projects
- **Category:** AI/ML

## Template content

### Storage https://avatars.githubusercontent.com/u/151849438?s=256&v=4

- **Image:** rustfs/rustfs:1.0.5

### Ollama https://ollama.com/public/ollama.png

- **Image:** ollama/ollama:0.13.5
- **Start command:** `/bin/bash -c '#!/usr/bin/env bash
set -euo pipefail
: "${OLLAMA_MODEL:=qwen2.5:1.5b}"
ollama serve &
pid=$!
trap '\''kill "$pid" 2>/dev/null || true'\'' EXIT
trap '\''exit 0'\'' INT TERM
# The server inherited the private-network binding. Use its loopback for CLI calls.
export OLLAMA_HOST=http://127.0.0.1:11434
until ollama list >/dev/null 2>&1; do
  kill -0 "$pid"
  sleep 2
done
if ! ollama show "$OLLAMA_MODEL" >/dev/null 2>&1; then
  ollama pull "$OLLAMA_MODEL"
fi
wait "$pid"
'`

### Redis https://raw.githubusercontent.com/devicons/devicon/v2.17.0/icons/redis/redis-original.svg

- **Image:** redis:7.4.9-alpine
- **Start command:** `/bin/sh -ec 'exec redis-server --appendonly yes --requirepass "$REDIS_PASSWORD"'`

### Voice https://avatars.githubusercontent.com/u/192631691?s=256&v=4

- **Image:** ghcr.io/speaches-ai/speaches:0.9.0-rc.3-cpu

### AIRI https://airi.moeru.ai/docs/favicon.svg

- **Source:** XavTo/airi-web-railway
- **Health check:** /healthz
- **Public domain:** Yes

### Postgres https://raw.githubusercontent.com/devicons/devicon/v2.17.0/icons/postgresql/postgresql-original.svg

- **Image:** ghcr.io/tensorchord/vchord-postgres:pg18-v1.0.0

## Documentation

# Deploy and Host AIRI on Railway

AIRI is a self-hosted AI companion for the browser, with Live2D and VRM avatars, text chat, microphone input, and spoken replies. This one-click Railway template runs the AIRI web app, its API, and all inference services in your project. No external AI API keys are required.

## About Hosting AIRI

Six services run in one Railway project. AIRI exposes a single public HTTPS endpoint. The model engines, database, session store, and object store use private networking. Models download on first boot and are cached on persistent volumes. Chat, transcription, and speech synthesis run on CPU.

## Common Use Cases

- Chat with a personal AI character using a Live2D or VRM avatar.
- Speak into your microphone and listen to AIRI reply.
- Store supported synced data and uploaded media in your own Railway project.

## Dependencies for AIRI Hosting

### Deployment Dependencies

| Service | Purpose |
| --- | --- |
| AIRI | Stage Web, local account, API, and the public HTTPS gateway |
| Ollama | Text chat with Qwen2.5 1.5B |
| Voice | Multilingual Faster Whisper transcription and Kokoro speech synthesis, with a French voice selected by default |
| PostgreSQL | Persistent account and synced AIRI data |
| Redis | Sessions and coordination |
| RustFS | Private media storage with signed upload and download links |

## First launch

1. Deploy the template and open the generated AIRI domain.
2. In the **AIRI** service variables, find **OWNER_EMAIL** and **OWNER_PASSWORD**. Use these with the email sign-in option. The template generates a new password for each installation and creates the local account on first boot.
3. Give Ollama and Voice time to download their models. Start a chat, then allow microphone access to try voice input and spoken responses.
4. Enable the AIRI sync options you want to use for supported data. PostgreSQL and RustFS use persistent volumes.

This template is designed for a personal web companion with one owner account. Microphone input uses recorded speech transcription. Desktop overlays and game integrations are outside the scope of this web deployment.

## Why Deploy AIRI on Railway?

A single deployment configures the six services, connects them over the private network, and generates instance-specific secrets. The template supplies CPU models for chat and audio, and inference requires the owner's AIRI session.

[Project AIRI](https://github.com/moeru-ai/airi) · [Deployment source and configuration](https://github.com/XavTo/airi-web-railway/tree/full-selfhost)


## Similar templates

- [Chat Chat](https://railway.com/deploy/-WWW5r) — Chat Chat, your own unified chat and search to AI platform.
- [Weaviate](https://railway.com/deploy/weaviate-1) — Vector database with hybrid search and an API key-protected API
- [Möbius Personal AI OS](https://railway.com/deploy/mobius-v01-personal-ai-os) — Self-hosted AI agent that builds and runs apps for you, with memory.

Open this page in a browser: https://railway.com/deploy/airi-self-hosted-ai-companion
