
Immich is an open source, high-performance photo and video management solution that enables you to securely create, back up, and manage media files on a server. Immich is a self-hosted alternative to Google Photos, offering a user-friendly web-based interface for uploading and managing photos and videos. You can extend Immich with external storage solutions, such as Vultr Block Storage, making it a privacy-first solution for storing photos and videos using albums on your server.
This article explains how to install and configure Immich using Docker.
Before you begin, you need to:
immich.example.com, to point to your server’s public IP address.This section prepares the project directory and environment variables file for deploying Immich.
Create a new project directory in your home directory, such as immich, to store your Immich project files.
Switch to the project directory.
Download the latest .env file for Immich.
Edit the .env configuration for Immich using a text editor like nano.
Uncomment the #TZ directive and specify the timezone to use with Immich. For example, Europe/London.
Save and close the file.
Within the .env file:
UPLOAD_LOCATION: Specifies the default path to store all uploaded images and videos in Immich. The default library value creates a new directory in your Immich project directory to store the uploaded files.DB_DATA_LOCATION: Specifies a storage path for all PostgreSQL database files.TZ: Specifies the timezone to use with Immich. See the list of tz database time zones for the supported formats.IMMICH_VERSION: Specifies the Immich version to run on your server.DB_PASSWORD: The database password to authenticate with a username for the PostgreSQL container.DB_USERNAME: The username to authenticate with the PostgreSQL database.DB_DATABASE_NAME: The database name to store all Immich configurations and metadata.This section launches Immich and its required services using Docker Compose. Immich offers an official Docker Compose manifest that includes PostgreSQL for metadata storage and Valkey (a Redis-compatible in-memory datastore) for background jobs, caching, and task queues.
Download the latest Immich manifest for Docker Compose.
This file defines all required services, including:
immich-server: the main Immich applicationpostgres: stores metadata such as users, albums, and file referencesvalkey: handles background jobs, caching, and task queuesAdd your user account to the docker user group.
Apply new group membership.
Start the Immich container and the Valkey, PostgreSQL dependency containers.
List all active Docker containers and verify that the Immich, Valkey, and PostgreSQL containers are active.
The output displays three running containers with a status of Up: the Immich server, the PostgreSQL database, and Valkey.
Send a GET request to the Immich port 2283 and verify that it's active.
The command returns an HTTP response from the Immich server, confirming that the application is running and reachable on the port.
Immich runs on the host port 2283 and listens for HTTP connections, which is insecure by default. Follow the steps below to install Nginx and configure it as a reverse proxy to securely expose Immich using your immich.example.com domain.
Update the APT package index.
Install Nginx.
Enable the Nginx system service to start at boot.
Remove the default configuration from the /etc/nginx/sites-enabled directory to disable it.
Create a new immich.conf Nginx virtual host configuration in the /etc/nginx/sites-available directory.
Add the following configurations to the file. Replace immich.example.com with your actual domain.
The above Nginx configuration:
immich.example.com, and forwards them to the localhost port 2283 where Immich is active.client_max_body_size directive limits uploads to 10 MB. Increase this value if you plan to upload larger image or video files.Save and close the file.
Link the immich.conf file to the /etc/nginx/sites-enabled directory to enable it.
Test the Nginx configuration for errors.
The output confirms that the configuration syntax is valid and the test is successful.
Restart Nginx to apply the configuration changes.
Allow incoming HTTP traffic through the firewall.
Allow HTTPS traffic through the firewall for secure access.
Reload UFW to apply the firewall configuration changes.
Follow the steps below to secure incoming connections to Immich with trusted TLS certificates.
Install the Certbot Let's Encrypt plugin for Nginx.
Generate a new TLS certificate for your Immich virtual host domain. Replace immich.example.com with your actual domain and admin@example.com with your active email address.
Certbot automatically updates the Nginx configuration to enable HTTPS for your Immich domain.
Immich requires an active administrative user in order to upload and manage media on your server. Follow the steps below to access Immich using your immich.example.com domain, set up an administrative user, and configure Immich on your server.
Access your domain using a web browser such as Firefox.
Click Getting Started to begin the Immich configuration process.
Enter your administrator email, a strong password, and display name in the respective fields.
Click Sign up to save the administrator user information.
Enter your administrator email and password when prompted to log in to Immich.
Navigate through the default Immich setup steps to customize your installation:
Verify that the Immich web management dashboard loads in your web browser.
Click Upload on the top navigation bar to upload images from your workstation.
Browse any images from your workstation and click Open to upload them to your Immich server.
Verify the uploaded images in your Photos catalog.
Click the user thumbnail in the top-right corner and select Administration from the list of options.
Click Users on the left navigation menu.
Click Create user within the User Management page.
Enter the new user's email, initial password, and display name. Then, enter the user's maximum storage in gigabytes within the Quota Size field and click Create to apply the changes.
You can upload multiple images and videos from multiple devices using Immich. Follow the steps below to download the latest mobile app for your device, configure your server endpoint, and upload images using Immich.
Open your mobile device's official application store. For example, Play Store for Android or App Store for iOS.
Enter Immich as the search keyword to browse the list of available apps.
Install the official Immich application.
Open Immich and enter your Immich server domain in the Server Endpoint URL field and click Next.
Enter your user email and password in the respective fields and click Login.
Grant the Immich application access to the photos and videos library on your mobile device.
Click Backup next to your user's thumbnail.
Click Select to specify the albums on your mobile device that you want to upload to the Immich server.
Click Back and toggle Enable Backup to allow instant uploads to your Immich server.
Monitor the upload progress within your Backup statistics.
Access your Immich server from a different workstation, log in with the same user, and verify that all files uploaded from your mobile device are available.
You have installed and configured Immich to store images. Immich supports image and video uploads from multiple devices and users, limited only by the storage and resources available on your server. You can migrate existing images from Google Photos to Immich and use external storage solutions like Vultr Block Storage to increase the storage size on your server.
0 Comments
Be the first to comment and share your perspective with the community.