Immich: Self-Hosted Google Photos Replacement for Your Homelab
Google Photos offers 15GB free and then charges you monthly for the privilege of hosting your own memories on someone else's servers. Immich is the self-hosted alternative that gives you full control — no subscription, no data mining, no storage limits beyond your own hardware.
Photo by Shubham Dhage on Unsplash
What Immich Does
Immich is a full-featured photo and video management platform:
- Automatic mobile backup via iOS and Android apps
- Machine learning features: facial recognition, object detection, scene classification
- Timeline view with map integration
- Album organization and sharing
- RAW file support
- Partner sharing with other Immich users on your instance
- On-this-day memories feature
- Duplicate detection
It's not a clone — it's a genuinely well-designed application that happens to feel familiar to Google Photos users.
Hardware Requirements
Immich is resource-intensive compared to simpler self-hosted apps, primarily due to machine learning:
Minimum:
- 2 CPU cores
- 4GB RAM
- Storage: at least 2x your current photo library size (for originals + transcoded versions)
Recommended for ML features:
- 4+ CPU cores (ML is CPU-intensive without a GPU)
- 8GB+ RAM
- GPU (optional but dramatically speeds up facial recognition and CLIP search)
The machine learning container handles:
- CLIP embeddings (semantic search)
- Facial recognition
- Smart album classification
If your server is limited on resources, you can disable ML entirely in the config — Immich works fine without it.
Deployment with Docker Compose
Immich's official deployment method is Docker Compose. It runs multiple containers:
immich-server— the main API serverimmich-microservices— background job processingimmich-machine-learning— ML inferencepostgres— databaseredis— caching and job queues
Download the official compose files:
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
Edit .env to configure:
# Database password — change this
DB_PASSWORD=yourSecurePassword
# Where to store your photos
UPLOAD_LOCATION=/mnt/photos/immich
# Where to store the database
DB_DATA_LOCATION=/var/lib/immich/postgres
# Your local timezone
TZ=America/New_York
# Immich version (use release tags for stability)
IMMICH_VERSION=release
Start Immich:
docker compose up -d
Access the web UI at http://your-server:2283.
Like what you're reading? Subscribe to HomeLab Starter — free weekly guides in your inbox.
Initial Setup
On first launch:
- Create your admin account
- Configure external libraries (if you have existing photos on your server)
- Install the mobile app and point it to your server URL
- Enable HTTPS if exposing externally (strongly recommended)
External library setup lets Immich read photos stored elsewhere (existing Lightroom catalogs, NAS shares) without moving them. Immich indexes them but doesn't copy them.
Uploaded/backed-up photos go to the UPLOAD_LOCATION directory, organized by date.
Mobile App Configuration
Available for iOS and Android:
- Open the app
- Enter your server URL (e.g.,
https://photos.yourdomain.comorhttp://192.168.1.100:2283) - Log in with your credentials
- Enable background backup
- Choose backup settings: WiFi only, charging only, resolution, video quality
The app monitors your camera roll and automatically uploads new photos. It can optionally delete local copies after backup to free phone storage.
Reverse Proxy and HTTPS
For mobile app backup outside your home network, you need HTTPS. Using Nginx Proxy Manager or Traefik:
Nginx Proxy Manager example:
- Forward Host: your server IP
- Forward Port: 2283
- Enable "Websockets Support" (required for Immich)
- Set up SSL certificate via Let's Encrypt
Key requirement: Immich requires WebSocket support in your reverse proxy configuration. Without it, real-time features like upload progress won't work.
Machine Learning Configuration
Immich's ML container handles multiple models:
CLIP (semantic search): Find photos by description, e.g., "sunset at the beach" — even without tags. This is the most useful ML feature.
Facial recognition: Groups photos by person. You name one face, it finds all photos of that person.
Smart Search: Combines CLIP embeddings with metadata for powerful search.
To configure the ML model (lighter = faster, heavier = more accurate): Navigate to Admin → Machine Learning in the web UI.
For low-power servers, consider using the ViT-B-32 CLIP model instead of the larger default. For higher accuracy, ViT-H-14 is the top tier.
Storage Considerations
Immich stores:
- Original files: Full resolution originals, never touched
- Thumbnails: Compressed previews generated automatically
- Encoded video: H.264/H.265 re-encoded versions for streaming
Plan for roughly 1.5-2x your library size total with all derivatives.
For large libraries (100,000+ photos), consider:
- ZFS dataset for photos with compression
- Separate dataset for the database
- Regular snapshots before upgrades
Upgrades
Immich releases updates frequently. The recommended upgrade process:
cd ~/immich
docker compose pull
docker compose up -d
Check the Immich GitHub releases for any migration notes before upgrading between major versions.
Important: The project is under active development. Don't skip major versions when upgrading — breaking changes can cause data migration issues if you jump multiple versions.
Backup Strategy
The data that must be backed up:
UPLOAD_LOCATION— your photos (most important)DB_DATA_LOCATION— the PostgreSQL database- Immich also has a built-in backup export for the database
Don't rely on your original phone photos as a backup to Immich. Back up Immich independently — backup your UPLOAD_LOCATION to a second drive or offsite storage.
Alternative: Photoprism vs. Immich
PhotoPrism is the other major self-hosted Google Photos alternative. How they compare:
| Feature | Immich | PhotoPrism |
|---|---|---|
| Mobile backup app | Yes (native) | No (third-party) |
| Active development | Very active | Active |
| ML features | Strong | Strong |
| Resource usage | Higher | Moderate |
| UI feel | Modern, familiar | Different style |
| Multi-user | Yes | Limited (free) |
For most homelabbers who want automatic phone backup, Immich wins on the mobile app experience.
Getting Started
The Immich project has excellent documentation at immich.app. The Discord community is active and helpful for troubleshooting.
Self-hosting your photos means your memories stay yours — no algorithm deciding what to show you, no subscription to keep, no risk of Google changing the terms.
