AutomationFlowsEmail & Gmail › Generate and Email PDF Payslips From Google Sheets with Gmail

Generate and Email PDF Payslips From Google Sheets with Gmail

ByKhairul Muhtadin @khmuhtadin on n8n.io

This workflow automates the entire payslip process by pulling payroll data directly from Google Sheets, generating a professional and secure PDF for each employee, and emailing it to them instantly. Save hours of manual HR administration, eliminate human error, and ensure…

Event trigger★★★★☆ complexity18 nodesGoogle SheetsN8N Nodes PuppeteerGmail
Email & Gmail Trigger: Event Nodes: 18 Complexity: ★★★★☆ Added:

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

This workflow follows the Gmail → Google Sheets 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": "a6j2K4btAzegz8SD",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "name": "Automate Generate and Deliver Payslip",
  "tags": [],
  "nodes": [
    {
      "id": "c4cfd869-eec5-49c9-b866-48fa3bd39119",
      "name": "Manual Trigger",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        -2560,
        368
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "e326b4a7-be63-4ad9-ac69-96068c8db253",
      "name": "Company Configuration",
      "type": "n8n-nodes-base.set",
      "position": [
        -2352,
        368
      ],
      "parameters": {},
      "typeVersion": 3.4
    },
    {
      "id": "a8a21d06-1edc-400f-9c26-7373fb8da0c1",
      "name": "Fetch Payroll Data",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        -2128,
        368
      ],
      "parameters": {},
      "typeVersion": 4.7
    },
    {
      "id": "da81de85-ad5b-499b-9334-c4368dcd8c28",
      "name": "Iterate Payslip Rows",
      "type": "n8n-nodes-base.splitInBatches",
      "position": [
        -1680,
        304
      ],
      "parameters": {},
      "typeVersion": 3
    },
    {
      "id": "750961aa-cf88-4c19-b510-cfac9769be1f",
      "name": "Prepare Payslip Data",
      "type": "n8n-nodes-base.code",
      "position": [
        -1456,
        288
      ],
      "parameters": {},
      "typeVersion": 2
    },
    {
      "id": "2e0c5829-2360-43d4-a527-a2518d75ff22",
      "name": "Check Email Not Sent",
      "type": "n8n-nodes-base.filter",
      "position": [
        -1904,
        368
      ],
      "parameters": {},
      "typeVersion": 2.2
    },
    {
      "id": "4482e304-38a7-40e1-a826-9af818a95f67",
      "name": "Generate Payslip HTML",
      "type": "n8n-nodes-base.html",
      "position": [
        -1232,
        288
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "53df5b3b-2bb1-4db0-a051-fd4325ded35b",
      "name": "Generate Payslip PDF",
      "type": "n8n-nodes-puppeteer.puppeteer",
      "position": [
        -1008,
        288
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "2df79e27-95c0-457e-bc29-e3e97ce20aca",
      "name": "Create PDF File",
      "type": "n8n-nodes-base.convertToFile",
      "position": [
        -784,
        288
      ],
      "parameters": {},
      "typeVersion": 1.1
    },
    {
      "id": "5f081a5d-2db0-4336-a936-9982bd41f0e0",
      "name": "Send Payslip Email",
      "type": "n8n-nodes-base.gmail",
      "position": [
        -560,
        288
      ],
      "parameters": {},
      "typeVersion": 2.1
    },
    {
      "id": "42f8dc37-3f3f-4cf9-8adc-944164ed425d",
      "name": "Mark Email Sent in Sheet",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        -352,
        288
      ],
      "parameters": {},
      "typeVersion": 4.7
    },
    {
      "id": "28642d8e-dcff-4bac-be8d-79f61e49310c",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1936,
        528
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "cb040c93-1945-4be2-a9c3-13f38ae5d5dd",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -2560,
        528
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "db9843d7-7562-4554-a05c-595a4c8aeea7",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1408,
        528
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "052fe0ea-ab42-4326-8f6a-c5ada8c5d292",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -864,
        528
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "fdab71ad-e026-43e6-ade7-0ea39e2dffdd",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -320,
        528
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "79284cac-77fd-4bbc-9db8-390b26d9584f",
      "name": "Sticky Note5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -2560,
        896
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "175f2dfd-c839-48b9-8ce3-d4e705eade39",
      "name": "Sticky Note6",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -3424,
        -80
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "42dff9cd-0477-4e64-9a15-5ecbb257c8a1",
  "connections": {
    "Manual Trigger": {
      "main": [
        [
          {
            "node": "Company Configuration",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create PDF File": {
      "main": [
        [
          {
            "node": "Send Payslip Email",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Fetch Payroll Data": {
      "main": [
        [
          {
            "node": "Check Email Not Sent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Send Payslip Email": {
      "main": [
        [
          {
            "node": "Mark Email Sent in Sheet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Check Email Not Sent": {
      "main": [
        [
          {
            "node": "Iterate Payslip Rows",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Generate Payslip PDF": {
      "main": [
        [
          {
            "node": "Create PDF File",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Iterate Payslip Rows": {
      "main": [
        [],
        [
          {
            "node": "Prepare Payslip Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Prepare Payslip Data": {
      "main": [
        [
          {
            "node": "Generate Payslip HTML",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Company Configuration": {
      "main": [
        [
          {
            "node": "Fetch Payroll Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Generate Payslip HTML": {
      "main": [
        [
          {
            "node": "Generate Payslip PDF",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Mark Email Sent in Sheet": {
      "main": [
        [
          {
            "node": "Iterate Payslip Rows",
            "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

This workflow automates the entire payslip process by pulling payroll data directly from Google Sheets, generating a professional and secure PDF for each employee, and emailing it to them instantly. Save hours of manual HR administration, eliminate human error, and ensure…

Source: https://n8n.io/workflows/10650/ — 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

Loan eligibility workflow. Uses formTrigger, googleSheets, gmail. Event-driven trigger; 53 nodes.

Form Trigger, Google Sheets, Gmail
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
Email & Gmail

Telegram Code. Uses stickyNote, telegramTrigger, telegram, googleDrive. Event-driven trigger; 37 nodes.

Telegram Trigger, Telegram, Google Drive +2
Email & Gmail

Categories: Payments, Project Operations, Client Onboarding

Stripe Trigger, Google Drive, ClickUp +4