Backup Workflows to Git Repository
detail.loadingPreview
Automatically backs up n8n workflows to a Git repository.
🚀Ready to Deploy This Workflow?
About This Workflow
Overview
This workflow automates the process of backing up your n8n workflows to a specified Git repository. It periodically checks for workflow changes and commits them to the repository, ensuring you have a version history of your automation setups.
Key Features
- Fetches all active workflows from your n8n instance.
- Compares workflow content with files in the Git repository.
- Creates new files for workflows not present in the repository.
- Updates existing workflow files in the repository if changes are detected.
- Commits changes with informative messages.
- Configurable Git repository owner, name, and path.
How To Use
- Trigger: Configure the
Schedule Triggerto run the workflow at your desired interval (e.g., daily, hourly). - Globals: Set the
Globalsnode with your GitHub repository owner, name, and the base path where workflows should be stored. - Credentials: Set up n8n credentials for your GitHub account (
Shashikanth | GitHub account). - n8n Node: Ensure the
n8nnode is configured to fetch workflows. - Loop Over Items: This node is used to process each workflow individually.
- GitHub (Get File): This node checks if a workflow file already exists in the Git repository.
- If Node: This node determines whether an error occurred during the file fetch or if the file does not exist.
- Code Node: Converts base64 encoded file content to a readable UTF8 string.
- If1 Node: Compares the fetched workflow content with the current workflow content from n8n.
- GitHub (Create new file): If the workflow file does not exist, this node creates it in the repository.
- GitHub (Update file content): If the workflow file exists and has changed, this node updates its content.
- Error Handling: The
Error Handlernode stops execution and reports an error if any critical step fails.
Apps Used
Workflow JSON
{
"id": "9ea82b64-25b6-438d-bbb9-baa82fdfc04c",
"name": "Backup Workflows to Git Repository",
"nodes": 0,
"category": "Backup & Version Control",
"status": "active",
"version": "1.0.0"
}Note: This is a sample preview. The full workflow JSON contains node configurations, credentials placeholders, and execution logic.
Get This Workflow
ID: 9ea82b64-25b6...
About the Author
Free n8n Workflows Official
System Admin
The official repository for verified enterprise-grade workflows.
Statistics
Verification Info
Related Workflows
Discover more workflows you might like
Backup Workflows to Gitea
This workflow automatically backs up all n8n workflows to a Gitea repository.
GitLab Workflow: Backup and Push
Automates the backup of n8n workflows and credentials to a Git repository.
Robust Concurrency Control for n8n Workflows with Redis
Prevent simultaneous execution of critical n8n workflows or tasks using a centralized, Redis-backed locking mechanism. This reusable utility workflow ensures data integrity and resource management by allowing other workflows to acquire, check, and release locks.
Automated Multi-Platform Social Media Publisher
Streamline your social media content creation and publishing with this n8n workflow. Simply fill out a web form with your caption, media (image or video), and target platforms, and let n8n automate the posting process across multiple social networks.
Telegram Profanity & Toxicity Filter
This n8n workflow automatically monitors incoming Telegram messages for profanity and toxic language. It leverages Google's Perspective API to analyze message content, and if a message is deemed inappropriate, the workflow sends an automated warning response back to the sender.
Universal CSV to JSON API Converter
Effortlessly transform CSV data into structured JSON with this versatile n8n workflow. Integrate it into any application as a custom API endpoint, supporting various input methods including file uploads and raw text.