A Home Assistant custom integration that adds a Dropbox backup agent to the native Backup UI, allowing you to create, list, download, and delete snapshots directly from your Dropbox account.
- Full BackupAgent Support: Implements all core methods—
async_list_backups,async_upload_backup,async_download_backup,async_delete_backup—integrating deeply with Home Assistant’s Backup system. - Config Flow: Authenticate with Dropbox using OAuth 2 via Home Assistant Application Credentials.
- Pagination Handling: Correctly pages through Dropbox folder listings to show every snapshot.
- Error Logging: Provides detailed debug logs for upload, download, and metadata operations.
- Chunked Uploads: Streams backups to Dropbox in 4 MB chunks for faster uploads of large files.
- Home Assistant Core 2025.1+ (Backup Agents API introduced in 2025.1).
- A Dropbox Scoped Access app with an App key and secret, and the following scopes enabled:
files.content.writefiles.content.readfiles.metadata.read.
- HACS (Home Assistant Community Store) for easy installation (optional).
- In Home Assistant, open HACS in the sidebar.
- Click the ⋮ menu (top right) and select Custom repositories.
- Add this repository:
- URL:
https://github.com/jasonwragg/HA-Dropbox-Backup - Category: Integration
- URL:
- Back in HACS → Integrations, locate Backup to Dropbox and click Install.
- After installation, go to Settings → System → Integrations, click + Add integration, then search for Dropbox Backup.
- Clone into your HA config directory:
mkdir -p /config/custom_components/backup_dropbox git clone https://github.com/jasonwragg/HA-Dropbox-Backup.git /config/custom_components/backup_dropbox
- Restart Home Assistant.
- Navigate to Settings → System → Integrations, click + Add integration, and search for Dropbox Backup.
- Go to the Dropbox App Console.
- Click Create app, choose Scoped access, then select App folder or Full Dropbox.
- Under Permissions, enable:
files.content.writefiles.content.readfiles.metadata.read.
- Add "https://my.home-assistant.io/redirect/oauth" as a valid redirect uri.
- Note your App key and App secret from the app overview page.
- In Home Assistant, open Settings → Devices and Services → Three Dots in the top right → Application Credentials.
- Click Add Credential, select the Dropbox Backup integration, set the Name to
dropbox, and enter your App key and App secret. - Then open Settings → System → Integrations, click + Add integration, search for Dropbox Backup, and follow the OAuth sign-in flow.
- After granting Dropbox access, click Submit, then Finish.
- Create Backup: Settings → System → Backups → Create, choose Dropbox, and follow prompts.
- List Backups: Dropbox-stored snapshots appear automatically in the list.
- Restore: Select a Dropbox snapshot, click Restore, and follow the wizard.
- Delete: Use the three-dot menu on any Dropbox backup entry and choose Delete.
missing_scopeerrors: Ensure your Dropbox app has the required scopes enabled, then reauthorize the integration.- No backups listed: Verify the Folder path matches your Dropbox folder and contains
.tarsnapshots. - UI 404 errors: Avoid illegal characters in folder names and ensure IDs are URL-decoded properly.
Contributions are welcome! Please fork this repo, follow Home Assistant’s integration quality guidelines, and submit a pull request.
This project is licensed under the MIT License. See the LICENSE file for details.