{
  "name": "Contact Form to Google Sheets + Email",
  "nodes": [
    {
      "parameters": {
        "content": "## Contact Form to Google Sheets + Email Notification\n\nCapture every website contact form submission, log it to a spreadsheet, and get notified instantly - without paying for form SaaS.\n\n**Setup time:** 10 minutes  ·  **Level:** Beginner\n\n**You'll need accounts/credentials for:** Webhook, Google Sheets, Gmail\n\n**Replace these before running:**\n- `REPLACE_WITH_YOUR_SPREADSHEET`\n\n**Setup steps:**\n1. Open the Webhook node and copy your production webhook URL.\n2. Point your website form's action attribute (or fetch call) at that URL with fields: name, email, message.\n3. Connect your Google account in the Google Sheets node and select a spreadsheet with columns: Timestamp, Name, Email, Message.\n4. Connect Gmail (or swap for SMTP/Outlook) and set your notification address.\n5. Activate the workflow and submit a test form.\n\nFree templates and updates: navkhan103.github.io",
        "height": 618,
        "width": 400,
        "color": 4
      },
      "id": "sticky-setup",
      "name": "Setup — read me first",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        -440,
        -40
      ]
    },
    {
      "parameters": {
        "content": "### How it runs\n\nStarts from **Webhook**.\n\n1. A Webhook node gives you a URL. Point your website form's POST action at it.\n2. The workflow extracts name, email, and message fields from the submission.\n3. A Google Sheets node appends the submission as a new row with a timestamp.\n4. A Gmail node sends you a formatted notification so you can reply while the lead is hot.",
        "height": 348,
        "width": 400,
        "color": 7
      },
      "id": "sticky-how",
      "name": "How it runs",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        -440,
        618
      ]
    },
    {
      "parameters": {
        "content": "### If something breaks\n\nThe read and AI nodes here **retry 3× automatically** (5s apart), which absorbs rate limits and brief timeouts.\n\nNodes that **send or write deliberately do not retry** — a send that reached the far end but lost its response would otherwise fire twice, so you'd get duplicate messages or duplicate rows.\n\nTo be told when one of those fails, build a workflow starting with an **Error Trigger** node that posts to Slack or email, then set it under **three-dot menu > Settings > Error Workflow**. Do it once and point every workflow at it.",
        "height": 400,
        "width": 400,
        "color": 3
      },
      "id": "sticky-fail",
      "name": "If something breaks",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        -440,
        1006
      ]
    },
    {
      "parameters": {
        "httpMethod": "POST",
        "path": "contact-form",
        "responseMode": "onReceived",
        "responseData": "allEntries"
      },
      "id": "a1b2c3d4-0001-4000-8000-000000000001",
      "name": "Webhook",
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 2,
      "position": [
        0,
        0
      ],
      "webhookId": "contact-form"
    },
    {
      "parameters": {
        "assignments": {
          "assignments": [
            {
              "id": "s1",
              "name": "name",
              "value": "={{ $json.body.name }}",
              "type": "string"
            },
            {
              "id": "s2",
              "name": "email",
              "value": "={{ $json.body.email }}",
              "type": "string"
            },
            {
              "id": "s3",
              "name": "message",
              "value": "={{ $json.body.message }}",
              "type": "string"
            },
            {
              "id": "s4",
              "name": "timestamp",
              "value": "={{ $now.toISO() }}",
              "type": "string"
            }
          ]
        }
      },
      "id": "a1b2c3d4-0002-4000-8000-000000000002",
      "name": "Extract Fields",
      "type": "n8n-nodes-base.set",
      "typeVersion": 3.4,
      "position": [
        220,
        0
      ]
    },
    {
      "parameters": {
        "operation": "append",
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "REPLACE_WITH_YOUR_SPREADSHEET"
        },
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "Sheet1"
        },
        "columns": {
          "mappingMode": "autoMapInputData"
        }
      },
      "id": "a1b2c3d4-0003-4000-8000-000000000003",
      "name": "Append to Google Sheets",
      "type": "n8n-nodes-base.googleSheets",
      "typeVersion": 4.5,
      "position": [
        440,
        0
      ]
    },
    {
      "parameters": {
        "sendTo": "you@example.com",
        "subject": "=New contact form lead: {{ $json.name }}",
        "message": "=Name: {{ $json.name }}<br>Email: {{ $json.email }}<br><br>{{ $json.message }}",
        "options": {}
      },
      "id": "a1b2c3d4-0004-4000-8000-000000000004",
      "name": "Email Notification",
      "type": "n8n-nodes-base.gmail",
      "typeVersion": 2.1,
      "position": [
        660,
        0
      ]
    }
  ],
  "connections": {
    "Webhook": {
      "main": [
        [
          {
            "node": "Extract Fields",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract Fields": {
      "main": [
        [
          {
            "node": "Append to Google Sheets",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Append to Google Sheets": {
      "main": [
        [
          {
            "node": "Email Notification",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "settings": {
    "executionOrder": "v1"
  }
}