Block 1 - Sticky Note
- Type / Role
- n8n-nodes-base.stickyNote - stickyNote
- Config choices
- Version 1
This workflow is provided as-is. Please review and test before using in production.
Restore workflows & credentials from FTP Remote Backup Solution This n8n template provides a safe and intelligent restore solution for self hosted n8n instances, allowing you to restore workflows a...
n8n-nodes-base.stickynote, n8n-nodes-base.emailsend, n8n-nodes-base.ftp, n8n-nodes-base.manualtrigger, n8n-nodes-base.readwritefile, n8n-nodes-base.stopanderror, n8n-nodes-base.filter, n8n-nodes-base.executecommand
This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Florent.
Original n8n.io sourcePerfect for disaster recovery or migrating between environments, this workflow automatically identifies your most recent FTP backup and provides a manual restore capability that intelligently excludes the current workflow to prevent conflicts. Works seamlessly with date-organized backup folders stored on any FTP/SFTP server.
Good to know
n8n import:workflow and n8n import:credentials)Restore Process (Manual)
Prerequisites
/ftp-backup-folder/YYYY-MM-DD/)/ftp-backup-folder/YYYY-MM-DD/n8n-credentials/N8N_ENCRYPTION_KEY from source environment (see dedicated section below)Initial Setup
Configure your environment variables:
N8N_ADMIN_EMAIL: Your email for notifications (optional)FTP_BACKUP_FOLDER: FTP path where backups are stored (e.g., /n8n-backups)N8N_PROJECTS_DIR: Projects root directory (e.g., /files/n8n-projects-data)GENERIC_TIMEZONE: Your local timezone (e.g., Europe/Paris)N8N_ENCRYPTION_KEY: Required if restoring credentials to a new environment (see dedicated section below)Create your FTP credential in n8n:
Update the Init node:
const N8N_ADMIN_EMAIL = $env.N8N_ADMIN_EMAIL || '[email protected]';PROJECT_FOLDER_NAME to "Workflow-backups" (or your preferred name)FTP_BACKUP_FOLDER to match your FTP backup path (default: /n8n-backups)credentials to "n8n-credentials" (or your backup credentials folder name)FTPName to a descriptive name for your FTP server (used in notifications)Configure FTP credentials in nodes:
Optional: Configure SMTP for email notifications:
Performing a Restore
{
"credentials": true,
"worflows": true
}
credentials: true - Restore credentials from FTPworflows: true - Restore workflows from FTP (note: typo preserved from original)true to restore everythingImportant Notes
N8N_ENCRYPTION_KEY from the source environment (see dedicated section below)2025-01-15-restore-credentials)Why this is critical: n8n generates an encryption key automatically on first launch and saves it in the ~/.n8n/config file. However, if this file is lost (for example, due to missing Docker volume persistence), n8n will generate a NEW key, making all previously encrypted credentials inaccessible.
When you need to configure N8N_ENCRYPTION_KEY:
How credentials encryption works:
/home/node/.n8n/configN8N_ENCRYPTION_KEY explicitly ensures the key remains consistentSolution: Retrieve and configure the encryption key
Step 1: Get the key from your source environment
# Check if the key is defined in environment variables
docker-compose exec n8n printenv N8N_ENCRYPTION_KEY
If this command returns nothing, the key is auto-generated and stored in n8n's data volume:
# Enter the container
docker-compose exec n8n sh
# Check configuration file
cat /home/node/.n8n/config
# Exit container
exit
Step 2: Configure the key in your target environment
Option A: Using .env file (recommended for security)
# Add to your .env file
N8N_ENCRYPTION_KEY=your_retrieved_key_here
Then reference it in docker-compose.yml:
services:
n8n:
environment:
- N8N_ENCRYPTION_KEY=${N8N_ENCRYPTION_KEY}
Option B: Directly in docker-compose.yml (less secure)
services:
n8n:
environment:
- N8N_ENCRYPTION_KEY=your_retrieved_key_here
Step 3: Restart n8n
docker-compose restart n8n
Step 4: Now restore your credentials
Only after configuring the encryption key, run the restore workflow with credentials: true.
Best practice for future backups:
N8N_ENCRYPTION_KEY in a secure location alongside your backupsFTP Server
Existing Backups on FTP
YYYY-MM-DD/n8n-credentials/Environment
n8n import:credentials and n8n import:workflow)Credentials
FTP Connection and Download Process
Smart Workflow Exclusion
Credentials Subfolder Filtering
Timezone Handling
Security
Common Issues
FTP_BACKUP_FOLDER path is correct and contains date-formatted folders (YYYY-MM-DD)N8N_PROJECTS_DIR for temporary foldersdocker-compose.yml match your project folder locationn8n-credentials subfolder with credential filesN8N_ENCRYPTION_KEY matches the source environmentError Handling
This workflow is designed for FTP/SFTP remote backup restoration. For local disk backups, see the companion workflow "n8n Restore from Disk".
Works best with backups from: "Automated n8n Workflows & Credentials Backup to Local/Server Disk & FTP"
This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.
| Workflow | Restore workflows and credentials from remote FTP backup storage |
|---|---|
| Complexity | advanced |
| Nodes | 23 |
| Categories | DevOps |
| Author | Florent |
| Published | 01 Oct 2025 |
Use the JSON export at /data/workflows/9156/9156.json as the source template for this automation.
Open n8n, import the downloaded JSON, and review each node before activating the workflow.
Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.
Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.
Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.
Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.
Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.
Restore workflows & credentials from FTP Remote Backup Solution This n8n template provides a safe and intelligent restore solution for self hosted n8n instances, allowing you to restore workflows a...
Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.
Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your DevOps use case.