Self-Hosting Duplicati: Automated Encrypted Backups with a Web UI
BorgBackup and Restic are the darlings of the self-hosting community, and for good reason — they're fast, efficient, and scriptable. But they're also CLI-only tools that require writing bash scripts, cron jobs, and monitoring wrappers. If you want something your non-terminal-using household member can configure, or if you just prefer a web UI over editing cron files, Duplicati fills that niche.
Duplicati is a backup tool with a full web interface. You configure backup jobs through a browser, it encrypts everything with AES-256 before uploading, and it supports more cloud storage backends than any other open-source backup tool. It's not as fast as Restic or as space-efficient as Borg, but it's dramatically easier to set up and manage.
Why Duplicati?
- Web UI — Configure and monitor everything through a browser
- AES-256 encryption — Backups are encrypted before leaving your machine
- 20+ backends — S3, B2, Google Drive, OneDrive, SFTP, WebDAV, Dropbox, and more
- Deduplication — Only transfers changed data blocks
- Incremental forever — Every backup after the first is incremental
- Scheduling — Built-in scheduler, no cron needed
- Email notifications — Get reports on backup success or failure
The trade-offs: Duplicati is written in C#/.NET, uses more CPU during backup than Borg/Restic, and its deduplication is less efficient. It also has occasional stability issues with very large backup sets (10+ TB). For homelabs with a few TB of data, it works well.
Docker Deployment
# docker-compose.yml
services:
duplicati:
image: lscr.io/linuxserver/duplicati:latest
ports:
- "8200:8200"
volumes:
- duplicati_config:/config
- /home:/source/home:ro
- /var/lib/docker/volumes:/source/docker-volumes:ro
- /etc:/source/etc:ro
- /mnt/backup:/backups # local backup target
environment:
- PUID=0 # Run as root to read all files
- PGID=0
- TZ=America/Los_Angeles
restart: unless-stopped
volumes:
duplicati_config:
docker compose up -d
The web interface is at http://your-server:8200. No login by default — set a password immediately in Settings > Access > Interface password.
Note on PUID/PGID: Running as root (0/0) lets Duplicati read all files on the system. If you're only backing up your own user files, use your regular UID/GID instead.
Configuring Your First Backup Job
The setup wizard walks you through everything:
1. General settings
- Name: "Daily Server Backup"
- Encryption: AES-256 (built-in, default)
- Passphrase: A strong password. Store this somewhere safe — without it, your backups are unrecoverable.
2. Choose a backend
Popular choices for self-hosters:
Backblaze B2 (cheapest cloud storage):
- Backend: "B2 Cloud Storage"
- Bucket name, Account ID, Application Key
- Cost: $6/TB/month storage, $0.01/GB download
Local / NAS:
- Backend: "Local folder or drive"
- Path:
/backups/daily - Good for fast restores, but not off-site
SFTP (to another server):
- Backend: "SFTP (SSH)"
- Server, path, SSH credentials
- Good for remote backups to a VPS or friend's server
3. Source data
Select the directories mounted as volumes in your Docker Compose:
/source/home— User files/source/docker-volumes— All Docker container data/source/etc— System configuration
Add filters to exclude unnecessary files:
# Exclude patterns
*.tmp
*.cache
node_modules/
.cache/
Thumbs.db
4. Schedule
- Run daily at 3:00 AM — Pick a time when your server isn't busy
- Duplicati handles the scheduling internally, no cron needed
5. Retention
Configure how long to keep backups:
- Keep all backups for 7 days
- Keep one backup per week for 4 weeks
- Keep one backup per month for 12 months
This gives you granular recent recovery with long-term monthly snapshots.
Restoring Files
From the web UI
- Go to Restore
- Select the backup job
- Browse the file tree to find what you need
- Select files or folders to restore
- Choose a restore location (original path or custom)
Direct restore (disaster recovery)
If your Duplicati server is gone, you can restore from any machine with Duplicati installed:
- Install Duplicati on a new machine
- Add a new backup job pointing to the same backend
- Go to Restore — Duplicati reads the encrypted backup data
- Enter your encryption passphrase
- Browse and restore
This is a major advantage over Borg/Restic for disaster recovery — Duplicati's web UI makes it accessible to anyone, not just command-line users.
Advanced Configuration
Email notifications
In Settings > Options, add:
--send-mail-url=smtp://smtp.gmail.com:587/?starttls=when-available
[email protected]
[email protected]
--send-mail-username=your-email
--send-mail-password=your-app-password
--send-mail-subject=Duplicati %OPERATIONNAME% - %PARSEDRESULT%
--send-mail-level=Warning,Error,Fatal
Set --send-mail-level to All if you want confirmation of successful backups too.
Bandwidth throttling
If backups saturate your upload:
--throttle-upload=5mb
--throttle-download=10mb
Pre/post backup scripts
Run commands before or after a backup:
--run-script-before=/scripts/pre-backup.sh
--run-script-after=/scripts/post-backup.sh
Use pre-backup scripts to dump databases before the backup runs:
#!/bin/bash
# pre-backup.sh
docker exec postgres pg_dumpall -U postgres > /source/home/db-dumps/postgres.sql
docker exec mariadb mariadb-dump --all-databases -u root -p > /source/home/db-dumps/mariadb.sql
Duplicati vs BorgBackup vs Restic
| Feature | Duplicati | BorgBackup | Restic |
|---|---|---|---|
| Interface | Web UI | CLI only | CLI only |
| Encryption | AES-256 | AES-256 | AES-256 |
| Deduplication | Block-level | Content-defined | Content-defined |
| Cloud backends | 20+ native | SSH only | S3, B2, SFTP, rclone |
| Speed | Moderate | Fast | Fast |
| Storage efficiency | Good | Excellent | Very good |
| Setup difficulty | Easy | Medium | Medium |
| Monitoring | Built-in UI | Needs wrapper | Needs wrapper |
| Email alerts | Built-in | Script it yourself | Script it yourself |
| OS support | Win, Mac, Linux | Linux, Mac | Win, Mac, Linux |
When to choose Duplicati
- You want a web UI for configuration and monitoring
- You need to back up to Google Drive, OneDrive, or Dropbox
- Non-technical users need to manage or restore backups
- You want built-in email notifications without scripting
When to choose Borg or Restic
- Maximum performance and storage efficiency matter
- You're comfortable with CLI tools and scripting
- You're backing up very large datasets (10+ TB)
- You want the most battle-tested deduplication
Common Issues
Slow first backup: The initial backup transfers everything. Subsequent runs only transfer changes and are much faster. Be patient with the first one.
Database lock errors: Duplicati uses a local SQLite database to track backup state. If a backup is interrupted, the database can get locked. Fix with: Database > Repair.
Memory usage on large backups: For backup sets over 5 TB, Duplicati's memory usage can climb. Set --blocksize=1mb (up from the default 100KB) to reduce the number of blocks tracked.
The Bottom Line
Duplicati trades some performance and storage efficiency for accessibility. It's the backup tool you can set up for your family's NAS and know they can restore files when you're not around. The web UI, built-in scheduling, email notifications, and broad cloud storage support make it the most user-friendly self-hosted backup solution available. If you've been putting off setting up backups because you don't want to write bash scripts and cron jobs, Duplicati removes that excuse.