Auto-backup n8n workflows to OneDrive with cleanup & email notifications
Ready for 3.0What this workflow does
This workflow has 14 nodes and runs on a schedule (every day at 01:00). Along the way it connects Microsoft OneDrive and Microsoft Outlook.
How it runs
Trigger: On a schedule (every day at 01:00).
- Create new backup folder (Microsoft OneDrive): create (folder)
- Retrieve workflows (n8n): uses n8n
- Convert to JSON file (Convert to File): converts data to a file (to json)
- Upload JSON to folder (Microsoft OneDrive): uses Microsoft OneDrive
- Get backupfolders (Microsoft OneDrive): work with folder
- Filter backup folder (Code): runs custom JavaScript code
- Switch: routes items into 2 branches
- Merge: merges the data from its input branches
- Loop Over Items (Loop Over Items (Split in Batches)): loops over the items in batches
- Prepare HTML Email (Code): runs custom JavaScript code
…plus 3 more steps. See the full node list below.
Services it uses
Other Microsoft OneDrive + Microsoft Outlook templates (9)
Before you upgrade to n8n 3.0
Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.
- Code node: the task timeout drops from 300s to 60s. Test with a realistic data volume.
Nodes used (9)
- n8n
n8n-nodes-base.n8n - Microsoft OneDrive
n8n-nodes-base.microsoftOneDrive - Code
n8n-nodes-base.code - Schedule Trigger
n8n-nodes-base.scheduleTrigger - Microsoft Outlook
n8n-nodes-base.microsoftOutlook - Switch
n8n-nodes-base.switch - Loop Over Items (Split in Batches)
n8n-nodes-base.splitInBatches - Merge
n8n-nodes-base.merge - Convert to File
n8n-nodes-base.convertToFile
From the author
Automatically BackUp Your n8n Workflows to OneDrive This workflow automates the backup of your self-hosted n8n instance by exporting all workflows and saving them as individual .json files to a designated OneDrive folder. Each file is timestamped for easy…