N8N Backup Flow to Nextcloud (7-Day Retention)

Nodes

e6ae7503-2949-4cf6-8d11-9f146c34f723818211a2-bc09-427d-bfa4-d8db9fbffb5094248680-97fe-4c64-8c0e-406e7e4b5b47+2

Categories

Created by

JoJoachim Hummel

Last edited 13 days ago

This workflow automates the daily backup of all your n8n workflows to a designated folder in Nextcloud. It ensures that you always have the last 7 days of backups available while automatically deleting older ones to save space.

🔧 Features

Scheduled Trigger: Runs automatically once per day (can be executed manually as well).

Directory Management: Creates the /N8N-Backup directory in Nextcloud if it doesn't already exist.

Backup Collection: Retrieves all workflows from the n8n instance.

JSON Conversion: Converts each workflow into a JSON file.

Upload to Nextcloud: Saves each backup file into the specified backup directory.

Retention Control: Keeps only the latest 7 backups and deletes the rest from Nextcloud.

📌 Notes

Make sure to manually create the /N8N-Backup directory in your Nextcloud account before using this flow.

Update the Backup Path node if you wish to change the upload directory.

Ideal for teams using n8n with self-hosted instances and requiring offsite backup via Nextcloud.

🔒 Requirements

n8n instance with access to the Nextcloud node.

Valid credentials for your Nextcloud account with API access.

New to n8n?

Need help building new n8n workflows? Process automation for you or your company will save you time and money, and it's completely free!