AutomationFlowsEmail & Gmail › Automatic Backup of Workflows to Github with Email/telegram Notifications

Automatic Backup of Workflows to Github with Email/telegram Notifications

ByBuilds.Cool @buildscool on n8n.io

Have you ever updated your n8n instance, or moved from one instance to the other and lost all your workflows? I suggest NOT DOING THAT! Especially if you have very complex workflows that would take days to recreate.

Event trigger★★★★☆ complexity21 nodesHTTP RequestTelegramGmail
Email & Gmail Trigger: Event Nodes: 21 Complexity: ★★★★☆ Added:

This workflow corresponds to n8n.io template #4923 — we link there as the canonical source.

This workflow follows the Gmail → HTTP Request recipe pattern — see all workflows that pair these two integrations.

The workflow JSON

Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →

Download .json
{
  "id": "CoZQfRWF6W1aefv3",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "name": "n8n BackupButler v3",
  "tags": [
    {
      "id": "GviYgVwcOV5jZvGf",
      "name": "tool agents",
      "createdAt": "2025-05-19T16:06:57.753Z",
      "updatedAt": "2025-05-19T16:06:57.753Z"
    },
    {
      "id": "8fLouiGmzDJLJsrG",
      "name": "n8n management",
      "createdAt": "2025-06-13T08:55:51.766Z",
      "updatedAt": "2025-06-13T08:55:51.766Z"
    }
  ],
  "nodes": [
    {
      "id": "89c33815-0a95-40e5-ae6c-3a53fca73ad1",
      "name": "When clicking \u2018Test workflow\u2019",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        1220,
        360
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "7b770371-ea6e-4388-a91c-6ab290473219",
      "name": "Create_Backup_Package",
      "type": "n8n-nodes-base.code",
      "position": [
        1320,
        -580
      ],
      "parameters": {},
      "typeVersion": 2
    },
    {
      "id": "1f27b64d-bdec-4701-b2a4-38b1d9cc0e5f",
      "name": "Get_Workflows",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        880,
        -580
      ],
      "parameters": {},
      "typeVersion": 4.2
    },
    {
      "id": "6e44ca90-eb57-40b2-973f-553db43e9316",
      "name": "Check_Repository_Exists",
      "type": "n8n-nodes-base.httpRequest",
      "onError": "continueRegularOutput",
      "position": [
        1540,
        -580
      ],
      "parameters": {},
      "typeVersion": 4.2
    },
    {
      "id": "5fc2401f-20ab-4bd1-a340-2d6bca4fffe2",
      "name": "If_Repo_Not_Exists",
      "type": "n8n-nodes-base.if",
      "position": [
        1760,
        -580
      ],
      "parameters": {},
      "typeVersion": 2.2
    },
    {
      "id": "aa48b4df-8a1e-404a-8ff5-66c6af85f6b4",
      "name": "Clean_Workflows",
      "type": "n8n-nodes-base.code",
      "position": [
        1100,
        -580
      ],
      "parameters": {},
      "typeVersion": 2
    },
    {
      "id": "0b59f796-e563-47f5-9c0b-e8b4741ff1f3",
      "name": "Create_Repository",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        2060,
        -520
      ],
      "parameters": {},
      "typeVersion": 4.2
    },
    {
      "id": "076fad7a-28c3-4090-93cb-3ce167a2bb49",
      "name": "Split_Workflow_Files",
      "type": "n8n-nodes-base.code",
      "position": [
        1240,
        -300
      ],
      "parameters": {},
      "typeVersion": 2
    },
    {
      "id": "225c9fbb-23a6-4c1b-ba53-3b304a1c6688",
      "name": "Backup_Complete_Summary",
      "type": "n8n-nodes-base.code",
      "position": [
        1680,
        40
      ],
      "parameters": {},
      "typeVersion": 2
    },
    {
      "id": "1994f553-a8a0-4137-8130-e33d85782afc",
      "name": "Upload_Workflow_Files",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1660,
        -240
      ],
      "parameters": {},
      "typeVersion": 4.2
    },
    {
      "id": "26625ff2-662b-47bb-99f2-9ac9e2394150",
      "name": "Upload_README",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1080,
        -300
      ],
      "parameters": {},
      "typeVersion": 4.2
    },
    {
      "id": "f10321d3-ce4b-4a54-b661-3d2cc396822c",
      "name": "Upload_Manifest",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        920,
        -300
      ],
      "parameters": {},
      "typeVersion": 4.2
    },
    {
      "id": "99d76a2d-1756-4912-bf67-75c71d1a3900",
      "name": "Loop_Workflow_Uploads",
      "type": "n8n-nodes-base.splitInBatches",
      "position": [
        1460,
        -300
      ],
      "parameters": {},
      "typeVersion": 3
    },
    {
      "id": "57cd3b4a-0f1a-4f8d-928c-fb2d39a9932c",
      "name": "Send_Backup_Notification",
      "type": "n8n-nodes-base.telegram",
      "position": [
        2080,
        360
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "a2392c3a-e96d-49c4-a397-97154fd6ff37",
      "name": "Backup_Config",
      "type": "n8n-nodes-base.code",
      "position": [
        200,
        -40
      ],
      "parameters": {},
      "typeVersion": 2
    },
    {
      "id": "1ede5cc3-6b2e-4eb9-80ba-ff5ea269d7b8",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -540,
        -620
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "637a98e0-1c84-4e58-a0e9-cdc6c6a1e3b2",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        780,
        260
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "31c3c069-ab0a-45a1-94e6-a9aaa664dfa0",
      "name": "Daily",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        1220,
        580
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "fd4e9a4c-37bc-4cc4-b159-947f7697aea2",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1580,
        260
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "b65879f5-b95c-4035-a7d3-7dea9892fca8",
      "name": "Gmail - Notification",
      "type": "n8n-nodes-base.gmail",
      "position": [
        2080,
        580
      ],
      "parameters": {},
      "typeVersion": 2.1
    },
    {
      "id": "431ebde2-1a24-419a-8e1a-008d6053f43c",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        560,
        -620
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "5a871447-511e-4710-aea7-a40656ca7947",
  "connections": {
    "Backup_Config": {
      "main": [
        [
          {
            "node": "Get_Workflows",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get_Workflows": {
      "main": [
        [
          {
            "node": "Clean_Workflows",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Upload_README": {
      "main": [
        [
          {
            "node": "Split_Workflow_Files",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Clean_Workflows": {
      "main": [
        [
          {
            "node": "Create_Backup_Package",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Upload_Manifest": {
      "main": [
        [
          {
            "node": "Upload_README",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create_Repository": {
      "main": [
        [
          {
            "node": "Upload_Manifest",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "If_Repo_Not_Exists": {
      "main": [
        [
          {
            "node": "Create_Repository",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Upload_Manifest",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split_Workflow_Files": {
      "main": [
        [
          {
            "node": "Loop_Workflow_Uploads",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create_Backup_Package": {
      "main": [
        [
          {
            "node": "Check_Repository_Exists",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Loop_Workflow_Uploads": {
      "main": [
        [
          {
            "node": "Backup_Complete_Summary",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Upload_Workflow_Files",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Upload_Workflow_Files": {
      "main": [
        [
          {
            "node": "Loop_Workflow_Uploads",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Backup_Complete_Summary": {
      "main": [
        [
          {
            "node": "Gmail - Notification",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Check_Repository_Exists": {
      "main": [
        [
          {
            "node": "If_Repo_Not_Exists",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "When clicking \u2018Test workflow\u2019": {
      "main": [
        [
          {
            "node": "Backup_Config",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
Pro

For the full experience including quality scoring and batch install features for each workflow upgrade to Pro

About this workflow

Have you ever updated your n8n instance, or moved from one instance to the other and lost all your workflows? I suggest NOT DOING THAT! Especially if you have very complex workflows that would take days to recreate.

Source: https://n8n.io/workflows/4923/ — original creator credit. Request a take-down →

More Email & Gmail workflows → · Browse all categories →

Related workflows

Workflows that share integrations, category, or trigger type with this one. All free to copy and import.

Email & Gmail

Create viral TikTok videos effortlessly — no editing skills required!

HTTP Request, OpenAI, Form Trigger +6
Email & Gmail

🎦💌Advanced YouTube RSS Feed Buddy for Your Favorite Channels. Uses formTrigger, httpRequest, stickyNote, lmChatOpenAi. Event-driven trigger; 41 nodes.

Form Trigger, HTTP Request, OpenAI Chat +4
Email & Gmail

Telegram Code. Uses stickyNote, gmail, lmChatOpenAi, gmailTrigger. Event-driven trigger; 14 nodes.

Gmail, OpenAI Chat, Gmail Trigger +3
Email & Gmail

Splitout Code. Uses manualTrigger, httpRequest, stickyNote, splitOut. Event-driven trigger; 46 nodes.

HTTP Request, Execute Workflow Trigger, Gmail +1
Email & Gmail

Automate CSV imports into HubSpot without the mess. Powered by n8n. Supercharged by Pollup AI.

HTTP Request, Execute Workflow Trigger, Gmail +1