Setting Up Immich on the Raspberry Pi

In this project, we will explore how to install and run Immich on the Raspberry Pi.

Raspberry Pi Immich

Immich is a self-hosted photo and video backup software with a great web interface and useful mobile application.

Using this software, you can very easily back up your photos and videos directly from your Mobile phone to Immich. People often use this software as an alternative to Google Photos or iCloud. This software allows you to retain control over your images and saves you a monthly subscription.

Immich even has some of the fancier features of iCloud and Google Photos, with it able to automatically process your images with facial recognition, geolocation, and more.

This software is also a solid alternative to the self-hosted photo app called PhotoPrism.

Setting up Immich on your Raspberry Pi is a very simple process. The reason for this is that it is available as a Docker container that has support for ARM.

One thing to warn you is that when you first sync all your photos into Immich, your Raspberry Pi will be pushed pretty hard. The reason for this is that it needs to process all of the images. However, after the initial sync it uses minimal resources outside of processing new images.

For the best performance, we recommend using at least a Raspberry Pi 4. However, the faster the Pi, the faster Immich can process your images.

Additionally, Immich requires you to be running the 64-bit version of Raspberry Pi OS. 32-bit operating systems will not work.

Equipment

Below, you can find the list of equipment we used when installing Immich on our Raspberry Pi.

Recommended

Optional

This tutorial was last tested on a Raspberry Pi 400 running Raspberry Pi OS Bookworm 64-bit.

Installing Immich on the Raspberry Pi

Over the following sections, we will be showing you how to install Immich on your Raspberry Pi.

Thanks to us being able to use Docker, this process is relatively straightforward. All we need to do is install Docker, pull some configuration files, and adjust some settings slightly.

For most of the following steps we will be using the terminal. If you are using the desktop variant of Raspberry Pi OS, you can open the terminal by pressing CTRL + ALT + T.

Preparing your Raspberry Pi for Immich

1. Before we install Immich on our Raspberry Pi, we should ensure our current system is up to date.

We can update the package list and then upgrade any out-of-date packages by using the following command.

sudo apt update
sudo apt upgrade

2. Our next step is to ensure that the wget package is installed on our system by using the command below.

We will use wget later to grab the Docker compose file and the environment configuration file.

sudo apt install wget

3. We now need to install Docker so that we can easily run Immich on our device.

Please follow our guide on installing Docker to the Raspberry Pi to get this set up correctly.

4. After installing Docker, we can now create some directories where we will store the configuration files for Immich.

Create a directory called immich in your home directory using the mkdir command.

mkdir ~/immich

5. With the directory now created, we can change into it by using the cd command.

cd ~/immich

Setting up the Docker Compose File

6. Luckily, the Immich team provided the Docker Compose file for us. All we need to do is download the file from their GitHub.

You can use wget to save this Docker compose file by running the command below.

wget https://github.com/immich-app/immich/releases/latest/download/docker-compose.yml

Writing the Environment File for Immich

7. Now that we have the Docker compose file for Immich saved to our Raspberry Pi, we can move on to its environment file.

Immich’s Docker container uses this environment file to set itself up. Download the placeholder version of this file to your Pi by using the command below.

wget -O .env https://github.com/immich-app/immich/releases/latest/download/example.env

We use the “-O” option so we can save this file as “.env” rather than “.example.env“.

8. Our next step is to begin editing this environment file to suit our needs better. The default settings will work but can be insecure and might save your images to a location you don’t want to use.

nano .env

a. The first setting you will likely want to change is the upload location. This setting tells Immich where it should save files on your Raspberry Pi.

As images can very quickly take up a large amount of space, you will likely want to set this location to an external drive with ample space.

UPLOAD_LOCATION=./library

b. Next, you must change the “TYPESENSE_API_KEY“. This API key Immich will use to interact with the Typesense search internally.

Set this value to a long, secure, random string.

TYPESENSE_API_KEY=some-random-text

c. The final value you need to set is the password Immich will use to interact with the Postgres database.

Like with the Typesnse API key, you will want to replace “postgres” with a secure long password.

DB_PASSWORD=postgres

9. After making these changes to the environment file, you can save and quit by pressing CTRL + X, followed by Y, and then the ENTER key.

Starting Immich on your Raspberry Pi

10. We can now finally start up Immich on our Raspberry Pi by using the following command.

After running this, Immich will be downloaded to your Pi alongside the various services that it relies on. Depending on your internet connection, this may take a few minutes to complete.

docker compose up -d

By using the “-d” option, we are telling Docker to detach from the current terminal after it has started.

Accessing the Immich Web Interface

11. With Immich now up and running on your Raspberry Pi, we can access its web interface.

Ensure you replace “<YOURIPADDRESS>” with the IP of your Raspberry Pi. If you are unsure what your IP is, you can use the “hostname -I” command.

http://YOURIPADDRESS:2283

12. When you first access Immich, you will be greeted with the following screen.

To proceed, you must click the “Getting Started” button.

Click Getting Started Button

13. Next, you will be asked to create your admin account for Immich. Use the boxes to fill in the details for your admin account (1.).

After filling out your information, click the “Sign up” button (2.).

Sign up to Immich on your Raspberry Pi

14. At this point, you can now log in to your new admin account by using the email and password you just set (1.).

After filling out your information, click the “Login” button (2.).

Log in to Immich

15. You now have access to Immich running on your Raspberry Pi.

You can start uploading your images, create new accounts, and more.

Immich running on the Raspberry Pi

Updating Immich on your Pi

Immich is a software that gets updated fairly often, so you will want to know how to update it.

Luckily, since we are running it as a Docker container, updating Immich on your Raspberry Pi is a really simple process.

1. First, you need to ensure you are in the Immich directory we created earlier on in this guide.

Change to this directory by running the command below.

cd ~/immich

2. Once we are in the correct directory, we can use Docker compose to pull the new Immich container to your Raspberry Pi.

All we need to do to pull the new images is to use the following command.

docker compose pull

3. After pulling a new version of the container, you need to restart Immich by using the command below in your terminal.

docker compose up -d

Conclusion

Hopefully, at this point in the tutorial, you will now have Immich up and running on your Raspberry Pi.

Immich is a great solution for storing your photos and videos in one central location. It even has additional function such as grouping photos based on facial recognition or location they were taken.

Please feel free to leave a comment below if you have any questions about getting this software running on your Pi.

If you found this tutorial to be useful, be sure to check out our many other Raspberry Pi projects.

4 Comments

    1. Avatar for Emmet
      Emmet on
      Editor

      Hi David,

      Just wondering is that an issue with using Immich? Or is it an unrelated Docker container.

      If you are using a Raspberry Pi 5 with the new Pi OS, it is possible to work around the “jemalloc unsupported page size” issue by changing the kernel. I actually had to do this to use Geekbench when benchmarking my Pi 5.

      Cheers,
      Emmet

  1. Avatar for Daniel
    Daniel on

    hi!

    In step 10 I get the error message:

    “no matching manifest for linux/arm/v8”

    on a Raspi4. Any ideas?
    Thanks!

    1. Avatar for Emmet
      Emmet on
      Editor

      Hi Daniel,

      Sorry I forgot to write at the start of the tutorial that you must be running a 64-bit version of Raspberry Pi OS (ARM64).

      32-bit operating systems (ARMv8) will unfortunately not work. I have quickly added a note to the opening segment to mention this.

      Kind regards,
      Emmet

Leave a Reply

Your email address will not be published. Required fields are marked *