How to Install Firefly III With Importer on Your Synology NAS

How to Install Firefly III With Importer on Your Synology NAS

Firefly III is a self-hosted manager for your personal finances. It can help you keep track of your expenses and income so you can spend less and save more. Firefly III supports the use of budgets, categories and tags. Using a bunch of external tools, you can import data. It also has many neat financial reports available. Firefly III should give you insight into and control over your finances. The Firefly III data importer does not connect to your bank directly. Instead, it uses Nordigen and SaltEdge to connect to over 6000 banks worldwide. These services are free for Firefly III users, but require registration. Keep in mind these services have their own privacy and data usage policies. The data importer can import CSV files you’ve downloaded from your bank. You can run the data importer once, for a bulk import. You can also run it regularly to keep up with new transactions. In this step by step guide I will show you how to install Firefly III with Importer on your Synology NAS using Docker & Portainer.

💡Note: This guide works perfectly with the latest Firefly III 6.1.21 release.

  • STEP 1

Please Support My work by Making a Donation.

  • STEP 2

Install Portainer using my step by step guide. If you already have Portainer installed on your Synology NAS, skip this STEP. Attention: Make sure you have installed the latest Portainer version.

  • STEP 3

Make sure you have a synology.me Wildcard Certificate. Follow my guide to get a Wildcard Certificate. If you already have a synology.me Wildcard certificate, skip this STEP.

  • STEP 4

Go to Control Panel / Login Portal / Advanced Tab / click Reverse Proxy. Follow the instructions in the image below.

Firefly III Importer Synology NAS Set up 1

  • STEP 5

Now click the “Create” button. Follow the instructions in the image below.

Firefly III Importer Synology NAS Set up 2

  • STEP 6

After you click the Create button, the window below will open. Follow the instructions in the image below.

On the General area, set the Reverse Proxy Name description: type in Firefly. After that, add the following instructions:

Source:
Protocol: HTTPS
Hostname: firefly.yourname.synology.me
Port: 443

Check Enable HSTS

Destination:
Protocol: HTTP
Hostname: localhost
Port: 6182

Firefly III Importer Synology NAS Set up 3

  • STEP 7

On the Reverse Proxy Rules click the Custom Header tab. Click Create and then, from the drop-down menu, click WebSocket. After you click on WebSocket, two Header Names and two Values will be automatically added. Click Save. Follow the instructions in the image below.

Synology Proxy WebSocket

  • STEP 8

Go to Control Panel / Network / Connectivity / Check Enable HTTP/2 then click Apply. Follow the instructions in the image below.

Firefly III Importer Synology NAS Set up 4

  • STEP 9

Go to Control Panel / Security / Advanced tab/ Check Enable HTTP Compression then click Apply. Follow the instructions in the image below.

Firefly III Importer Synology NAS Set up 5

  • STEP 10

Go to File Station and open the docker folder. Inside the docker folder, create one new folder and name it firefly. Follow the instructions in the image below.
Note: Be careful to enter only lowercase, not uppercase letters.

Firefly III Importer Synology NAS Set up 6

  • STEP 11

Now create four new folders inside the firefly folder that you created at STEP 10 and name them db, importer, redis, upload. Follow the instructions in the image below.
Note: Be careful to enter only lowercase, not uppercase letters.

Firefly III Importer Synology NAS Set up 7

  • STEP 12

Follow my step by step guide on how to activate SMTP for your Gmail account. This step is mandatory. Note: If you don’t want to use the easiest way for SMTP with Google and you already have SMTP details from your own Mail Server, you can just skip this STEP and use your personalized email SMTP details instead.

  • STEP 13

Log into Portainer using your username and password. In the left sidebar in Portainer, click on Stacks then + Add stack. Follow the instructions in the image below.

1 Synology Portainer Add Stack

  • STEP 14

In the Name field type in firefly. Follow the instructions in the image below.

Note: Copy Paste the code below in the Portainer Stacks Web editor.

services:
  redis:
    image: redis
    container_name: Firefly-REDIS
    hostname: firefly-redis
    mem_limit: 256m
    mem_reservation: 50m
    cpu_shares: 768
    security_opt:
      - no-new-privileges:true
    read_only: true
    user: 1026:100
    healthcheck:
      test: ["CMD-SHELL", "redis-cli ping || exit 1"]
    volumes:
      - /volume1/docker/firefly/redis:/data:rw
    environment:
      TZ: Europe/Bucharest
    restart: on-failure:5

  importer:
    image: fireflyiii/data-importer:latest
    container_name: Firefly-Importer
    hostname: firefly-importer
    security_opt:
      - no-new-privileges:false
    volumes:
      - /volume1/docker/firefly/importer:/var/www/html/storage/upload:rw
    ports:
      - 6192:8080
    restart: on-failure:5
    depends_on:
      firefly:
        condition: service_healthy

  db:
    image: mariadb:11.4-noble #LTS Long Time Support Until May 29, 2029.
    container_name: Firefly-DB
    hostname: firefly-db
    mem_limit: 512m
    mem_reservation: 128m
    cpu_shares: 768
    security_opt:
      - no-new-privileges:false
    volumes:
      - /volume1/docker/firefly/db:/var/lib/mysql:rw
    environment:
      TZ: Europe/Bucharest
      MYSQL_ROOT_PASSWORD: rootpass
      MYSQL_DATABASE: firefly
      MYSQL_USER: fireflyuser
      MYSQL_PASSWORD: strangepass
    restart: on-failure:5

  firefly:
    image: fireflyiii/core:latest
    container_name: Firefly
    hostname: firefly
    mem_limit: 1g
    cpu_shares: 768
    security_opt:
      - no-new-privileges:true
    healthcheck:
      test: curl -f http://localhost:8080/ || exit 1
    env_file:
      - stack.env
    volumes:
      - /volume1/docker/firefly/upload:/var/www/html/storage/upload:rw
    ports:
      - 6182:8080
    restart: on-failure:5
    depends_on:
      db:
        condition: service_started
      redis:
        condition: service_healthy

  cron:
    image: alpine:latest
    command: sh -c "echo \"0 3 * * * wget -qO- http://firefly:8080/api/v1/cron/9610001d2871a8622ea5bf5e65fe25db\" | crontab - && crond -f -L /dev/stdout"
    container_name: Firefly-Cron
    hostname: firefly-cron
    mem_limit: 64m
    cpu_shares: 256
    security_opt:
      - no-new-privileges:true
    environment:
      TZ: Europe/Bucharest
    restart: on-failure:5
    depends_on:
      firefly:
        condition: service_started

Note: Before you paste the code above in the Web editor area below, change the value numbers for user with your own UID and GID values. (Follow my step by step guide on how to do this.) 1026 is my personal UID value and 100 is my personal GID value. You have to type in your own values.
Note: Before you paste the code above in the Web editor area below, change the value for TZ. (Select your current Time Zone from this list.)
Note: The number 3 in command means cronjob gets triggered everyday at 3 o’clock in the morning so Firefly can do its recurring transactions job. You can change the number according to your preferences.

Firefly III Importer Synology NAS Set up 8

  • STEP 15

Click the Upload button after Web editor. Download the stack.env file by clicking the blue link below and then upload it from your computer in the “Load variables from .env files“. Follow the instructions in the image below. 🔒Note: Support my work to unlock the password. You can use this password to download any file on mariushosting forever!

👉🏻Download stack.env file

Environment Variables Portainer Synology

  • STEP 16

Note: On the Environment variables change the value for APP_KEY and add your own App Key. MariushostingMariushostingMari13 is an example for an APP_KEY. You should invent your own Value. Add 32 random characters, both letters and numbers. 🔵
Note: On the Environment variables change the value for APP_URL. Type in your own synology.me DDNS that you have previously created at STEP 6 with https at the beginning. 🟡
Note: On the Environment variables change the value for TZ and add your own TIMEZONE. (Select your current Time Zone from this list.) 🟢
Note: On the Environment variables change the value for DEFAULT_LANGUAGE. Examples: en_US for English, de_DE for German, fr_FR for French etc. (Select your current Default Language from this list.) 🔴

Firefly III Importer Synology NAS Set up 10

  • STEP 17

Scroll down the page a little bit, then add your own SMTP details.

Note: On the Environment variables change the value for MAIL_FROM and add your own Gmail address. 🔴 STEP 12.
Note: On the Environment variables change the value for MAIL_USERNAME and add your own Gmail address. 🔴 STEP 12.
Note: On the Environment variables change the value for MAIL_PASSWORD and add your own Gmail App password. 🔵 STEP 12.

Firefly III Importer Synology NAS Set up 11

  • STEP 18

After you make the changes, scroll up the page a little bit then click the Web editor button. Follow the instructions in the image below.

Firefly III Importer Synology NAS Set up 12

  • STEP 19

Scroll down on the page until you see a button named Deploy the stack. Click on it. Follow the instructions in the image below. The installation process can take up to a few minutes. It will depend on your Internet speed connection.

Firefly III Importer Synology NAS Set up 13

  • STEP 20

If everything goes right, you will see the following message at the top right of your screen: “Success Stack successfully deployed“.

Firefly III Importer Synology NAS Set up stack complete

  • STEP 21

Go back to STEP 1 or you will deal with karma 🙂

  • STEP 22

Please wait approximately 3-5 minutes for the installation to be completed or you will get a blank Synology page if you try to connect too soon. Now open your browser and type in your HTTPS/SSL certificate like this https://firefly.yourname.synology.me In my case it’s https://firefly.mariushosting.synology.me If everything goes right, you will see the Firefly registration page. Add your own Email and Password, confirm the Password, then click Register. Follow the instructions in the image below.
⚠️Warning: Password should be 16 characters, it’s mandatory.

Firefly III Importer Synology NAS Set up 13 new 2025

  • STEP 23

After click Register at STEP 22, you should receive a Welcome to Firefly III! email.

Firefly III Importer Synology NAS Set up 15

  • STEP 24

Add your own Bank details then click Submit. Follow the instructions in the image below.

Firefly III Importer Synology NAS Set up 16

  • STEP 25

Your Firefly dashboard at a glance!

Firefly III Importer Synology NAS Set up 17

  • STEP 26

Activate the data Importer. On the left sidebar of Firefly III, click Profile, then Create New Client. On the Name field, type in Importer. On the Redirect URL field, type in the following address:

http://192.168.1.18:6192/callback

Note: Before you paste the code above, change 192.168.1.18 with your local NAS IP. 192.168.1.18 is my local NAS IP.

Uncheck the Confidential field, then click Create. Follow the instructions in the image below.

Firefly III Importer Synology NAS Set up 18

  • STEP 27

Copy your client ID number. You will need this number on the next STEP. Follow the instructions in the image below.

Firefly III Importer Synology NAS Set up 19

  • STEP 28

Now open your browser and type in http://Synology-ip-address:6192 Type in your synology DDNS Firefly III URL address and the Client ID that you have previously copied at STEP 27,  then click Submit. Follow the instructions in the image below.

Firefly III Importer Synology NAS Set up 20

  • STEP 29

Click Authorize. Follow the instructions in the image below.

Firefly III Importer Synology NAS Set up 21

  • STEP 30

Import your data!

Firefly III Importer Synology NAS Set up 22

Enjoy Firefly III with data Importer!

🆘TROUBLESHOOTING

If you encounter issues by using this container, make sure to check out the Common Docker issues article. You can also create a Reverse Proxy for the Importer container by adding the port 6192 on the Destination area.

Note: Can I run Docker on my Synology NAS? See the supported models.
Note: How to Back Up Docker Containers on your Synology NAS.
Note: Find out how to update the Firefly III with data Importer container with the latest image.
Note: How to Free Disk Space on Your NAS if You Run Docker.
Note: How to Schedule Start & Stop For Docker Containers.
Note: How to Activate Email Notifications.
Note: How to Add Access Control Profile on Your NAS.
Note: How to Change Docker Containers Restart Policy.
Note: How to Use Docker Containers With VPN.
Note: Convert Docker Run Into Docker Compose.
Note: How to Clean Docker.
Note: How to Clean Docker Automatically.
Note: Best Practices When Using Docker and DDNS.
Note: Some Docker Containers Need WebSocket.
Note: Find out the Best NAS Models For Docker.
Note: Activate Gmail SMTP For Docker Containers.

This post was updated on Tuesday / October 1st, 2024 at 8:40 PM