# UniFi Protect Backup

UniFi Protect Backup is a Python-based tool that automatically backs up UniFi Protect event clips, including motion and smart-detection footage, to local disk or offsite cloud storage as they are recorded. It is open source and self-hosted, installable on Unraid and TrueNAS.

Canonical page: https://ourlocalhost.com/app/3432/unifi-protect-backup

## Description

UniFi Protect Backup is a Python-based tool that automatically backs up UniFi Protect event clips, including motion and smart-detection footage, to local disk or offsite cloud storage as they are recorded. Built on rclone, it supports a wide range of cloud destinations and configurable retention, giving UniFi Protect users a resilient copy of their camera footage that survives hardware failure, theft, or disaster.

## Platform availability

Available on 2 of 10 platforms: Unraid, TrueNAS.

## Health score

52/100 (Fair), based on 4 of 5 factors.
- Maintained: 68 (last commit 76 days ago)
- Popular: 59 (882 GitHub stars)
- Easy to install: 45 (2 install platforms, install notes, Docker image)
- Security check: 20 (1 serious finding, 4 minor, CI, tests, OpenSSF Scorecard 3.9/10)

## Security check

1 serious finding: Uses certifi 2025.6.15, which has a known critical vulnerability.
Automated checks on commit 6af04ed, 28 Oct 2026. Not an audit.

## Links

- Unraid: https://ca.unraid.net/apps/unifi-protect-backup-1vdc1yg0iqy5i4?q=UniFi-Protect-Backup
- TrueNAS: https://apps.truenas.com/catalog/unifi-protect-backup/
- GitHub: https://github.com/ep1cman/unifi-protect-backup

## Common questions

### What UniFi Protect account setup does the container need?

Create a local-access-only user with a role that has Full Management permissions for Protect, and assign that user to all cameras. Use that user for the container's UFP_USERNAME and UFP_PASSWORD environment variables.

### Does it back up raw UVB files or rely on the NVR to create video?

It calls the Protect API to generate MP4 files between two timestamps and never touches UVB files. The NVR does most of the transcoding, and the first backup may contain a very large number of clips.

### Which container paths should be persisted?

Persist the event database under /config/database/ and, when storing clips locally, mount a host directory to /data. The event database must be persisted for the tool to work from version 0.8.0 onward.

### How do I configure backup to cloud storage?

Provide an rclone.conf to the container and set RCLONE_DESTINATION to the rclone remote name and path. If no rclone configuration is supplied, clips are saved locally to /data.

---
Source: Our Local Host (https://ourlocalhost.com/app/3432/unifi-protect-backup), the self-hosted and open-source app directory.
