Immich is the closest thing to a self-hosted Google Photos: automatic phone backup, a fast timeline, albums, sharing, plus AI-powered search and face grouping. It’s heavier than something like Vaultwarden, so size the VPS accordingly.
Prerequisites
- A VPS with 4 GB RAM or more and disk to match your library (options).
- A domain, e.g.
photos.yourdomain.com(point it at the VPS). - Docker + Docker Compose, plus a reverse proxy for HTTPS.
Step 1 — Use the official Compose
Immich pins specific image versions and a special vector-enabled database, so start from their official files rather than improvising:
mkdir immich && cd immich
wget -O docker-compose.yml https://github.com/immich-app/immich/releases/latest/download/docker-compose.yml
wget -O .env https://github.com/immich-app/immich/releases/latest/download/example.env
Step 2 — Configure .env
Edit .env and set at least:
UPLOAD_LOCATION— where photos are stored on the host (e.g../library)DB_PASSWORD— a strong database password
Step 3 — Start it
docker compose up -d
The first start pulls several images and the ML model, so give it a few minutes.
Step 4 — HTTPS + mobile app
Put Nginx Proxy Manager in front, map photos.yourdomain.com to the Immich server container, and issue a Let’s Encrypt cert (guide). Then install the Immich app, point it at your URL, and enable automatic backup.
Which VPS to run it on
Immich is the case where you should not buy the cheapest box — the ML features want RAM. A 4 GB+ instance is the sweet spot. Hetzner gives the most RAM per dollar if you’ll manage it yourself; Cloudways is the managed option. Compare in Best VPS for Self-Hosting.