Self-hosted finance tools promise a clear picture of where money goes, but the most useful one is the one you will keep using. Firefly III is an open-source personal finance manager that tracks accounts, budgets, bills, and transactions without sending your bank data to a third party. Running it in Docker keeps the data on your own disk while still giving you a web interface and APIs for imports. This guide walks through a production-ready deployment, account setup, import workflow, backups, and the maintenance habits that keep a finance database trustworthy.

Why Self-Host Personal Finance

A spreadsheet starts simple and slowly becomes a burden. You forget to categorise transactions, budgets drift, and reconciling a card statement turns into a monthly chore. Firefly III gives structure to that process: accounts are explicit, categories are searchable, budgets have rules, and reports are generated from a consistent database. Because it is self-hosted, none of your transaction history leaves the machine.

The trade-off is that you own maintenance. A finance database should be backed up carefully, and access control matters more than it does for a blog or a monitoring dashboard. If that sounds acceptable, Firefly III fits a homelab well.

Prerequisites

You need Docker and Docker Compose, a Linux host with 1 GB of RAM, and a dedicated directory for persistent data. Use a domain name with HTTPS if you plan to reach the app from more than one device. A password manager is useful because the setup creates several credentials. If Docker volumes and reverse proxies are unfamiliar, the Docker basics for homelab guide explains the patterns used here.

Docker Compose Deployment

Create /opt/firefly with subdirectories data and export, then save this stack:

services:
  firefly:
    image: fireflyiii/core:version-6
    container_name: firefly
    restart: unless-stopped
    environment:
      TZ: Asia/Ho_Chi_Minh
      APP_ENV: production
      APP_DEBUG: false
      APP_URL: https://finance.example.com
      DB_CONNECTION: sqlite
      TRUSTED_PROXIES: '*'
      STATIC_CRON_TOKEN: ${STATIC_CRON_TOKEN}
    volumes:
      - ./data:/var/www/html/storage
      - ./export:/var/www/html/storage/export
    ports:
      - "127.0.0.1:8085:8080"
    healthcheck:
      test: ["CMD", "curl", "-f", "http://localhost:8080/"]
      interval: 30s
      timeout: 5s
      retries: 3
    logging:
      driver: json-file
      options:
        max-size: "10m"
        max-file: "3"

Generate a random STATIC_CRON_TOKEN into a .env file with permissions 600, then start with docker compose up -d. The SQLite database lives inside the data directory, which keeps backup simple. Open the local URL and complete the installer, choosing SQLite and setting an admin password.

Binding the port to localhost is deliberate. The interface will be reachable only through the HTTPS proxy you add next, so passwords and statements are never sent over plain HTTP on your LAN.

Setting Up Accounts and Budgets

Start with the accounts that matter most: a current account, a credit card, and one savings account. Record the current balance for each one so reports are accurate from day one. Add a currency and set a monthly budget for categories such as groceries, transport, and utilities. Firefly III can roll over unused budget if you want that behaviour, but a fresh start with simple rules is less confusing.

Categories and tags solve different problems. Categories are stable buckets for reporting, while tags describe one-off events such as a holiday. Use categories for anything you will compare month to month, and tags for context you may search later. Bills and recurring transactions should be entered as rules so you are not reminded manually.

Importing Transactions

Most people get value from Firefly III only after importing history. The app supports CSV imports from many banks and can also receive transactions through its API. Export a few months of statements, map the columns to the Firefly III format, and import a small batch first. Review duplicate detection before importing everything; an accidental double import is tedious to unwind.

Keep the raw CSV files in the export directory and include them in backups. If a mapping was wrong, you can correct the file and re-import without hunting for the original statement.

Secure Access

Terminate TLS at a reverse proxy. A Caddy reverse proxy with automatic certificates and a login layer works well. If the finance app will only be used at home, a VPN plus a localhost bind is even safer. Do not expose port 8085 publicly, and do not use the same password anywhere else.

Set APP_DEBUG=false permanently. Debug pages reveal configuration details that should never appear in a browser, and they are easy to forget after installation.

Backups

Finance data deserves a stricter backup routine than a typical blog. Stop or pause the container before copying the data directory so SQLite writes are flushed, then archive the copy to another host. Copy the .env file separately because it contains the cron token. A nightly job is reasonable; a weekly off-site copy protects against a failed disk or a compromised host.

The Docker volume backup guide describes the consistent snapshot pattern, and the Restic backup guide adds encryption before archives leave your network. Test restoration into a throwaway container every few months and confirm that balances and categories are intact.

Monitoring and Upgrades

Check the health endpoint with Uptime Kuma so you know if the container stops. Watch disk growth slowly; a finance database is small, but imported CSV archives accumulate. Keep log rotation enabled to avoid filling the partition with request logs.

Upgrades are image tag changes, but take a database backup first. Read release notes for migration steps, especially across major versions. Roll back by restoring the snapshot and pinning the previous tag if an update behaves badly.

Common Mistakes

Importing years of transactions before setting categories is a common mistake, because you then face a wall of uncategorised entries. Another is exposing the app without TLS or reusing a password. Assuming that object storage or erasure coding replaces a backup is a third; a single deleted account needs a real restore path. Finally, do not ignore duplicate detection during imports.

FAQ

Can I connect my bank directly? Not by default. Most self-hosted setups import downloaded CSV files, which avoids giving credentials to a third-party aggregator.

Is SQLite safe for one person? Yes, with regular backups. Move to PostgreSQL only if you have multiple heavy users.

Can I use it on my phone? Yes, through the responsive web interface once HTTPS is configured.

How do I correct a bad import? Delete the affected journal or import batch, fix the CSV mapping, and import again.

Does it support multiple currencies? Yes. Set a default currency and convert transactions when reports need a single view.

Firefly III in Docker turns scattered statements into a private, searchable finance history. Keep access tight, back up the data directory, and it will quietly replace a paid finance app.