AutomationFlowsCRM & Sales › Automated Lead Qualification & Nurturing with Jotform, Hubspot, Email & AI…

Automated Lead Qualification & Nurturing with Jotform, Hubspot, Email & AI…

Original n8n title: Automated Lead Qualification & Nurturing with Jotform, Hubspot, Email & AI Scoring

ByDaniel Shashko @tomax on n8n.io

This workflow automates the entire lead qualification process from form submission to personalized follow-up. When a prospect fills out your JotForm, the workflow instantly captures their information, runs it through an intelligent scoring algorithm that evaluates email domain,…

Event trigger★★★★☆ complexity12 nodesJot Form TriggerHubSpotGoogle SheetsSlackEmail Send
CRM & Sales Trigger: Event Nodes: 12 Complexity: ★★★★☆ Added:

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

This workflow follows the Emailsend → 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
{
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "nodes": [
    {
      "id": "c016b293-b976-428f-b72c-f1d287c74a4d",
      "name": "JotForm Trigger",
      "type": "n8n-nodes-base.jotFormTrigger",
      "position": [
        -560,
        576
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "ae285cb5-4ac1-4cbf-beb7-37be3e90c747",
      "name": "Extract & Format Lead Data",
      "type": "n8n-nodes-base.set",
      "position": [
        -336,
        576
      ],
      "parameters": {
        "mode": "combine",
        "options": {}
      },
      "executeOnce": false,
      "typeVersion": 3.3
    },
    {
      "id": "681c776e-6e28-4b04-96fe-ea656438b55e",
      "name": "AI Lead Scoring",
      "type": "n8n-nodes-base.code",
      "position": [
        -112,
        576
      ],
      "parameters": {
        "jsCode": "// AI-powered lead scoring algorithm\nconst items = $input.all();\nconst scoredItems = [];\n\nfor (const item of items) {\n  const data = item.json;\n  let score = 0;\n  let qualificationNotes = [];\n  \n  // Email domain scoring (business vs personal)\n  const email = data.email || '';\n  const domain = email.split('@')[1] || '';\n  const personalDomains = ['gmail.com', 'yahoo.com', 'hotmail.com', 'outlook.com'];\n  \n  if (!personalDomains.includes(domain.toLowerCase())) {\n    score += 25;\n    qualificationNotes.push('Business email domain (+25)');\n  } else {\n    qualificationNotes.push('Personal email domain (0)');\n  }\n  \n  // Company size scoring\n  const companySize = data.companySize || data.company_size || '';\n  if (companySize.includes('50+') || companySize.includes('100+') || companySize.includes('500+')) {\n    score += 30;\n    qualificationNotes.push('Large company size (+30)');\n  } else if (companySize.includes('10-50') || companySize.includes('25-99')) {\n    score += 20;\n    qualificationNotes.push('Medium company size (+20)');\n  } else {\n    score += 10;\n    qualificationNotes.push('Small company size (+10)');\n  }\n  \n  // Budget scoring\n  const budget = data.budget || data.estimatedBudget || '';\n  if (budget.includes('$10,000+') || budget.includes('$25,000+') || budget.includes('Enterprise')) {\n    score += 25;\n    qualificationNotes.push('High budget (+25)');\n  } else if (budget.includes('$5,000') || budget.includes('$10,000')) {\n    score += 15;\n    qualificationNotes.push('Medium budget (+15)');\n  } else {\n    score += 5;\n    qualificationNotes.push('Lower budget (+5)');\n  }\n  \n  // Timeline scoring (urgency)\n  const timeline = data.timeline || data.implementation_timeline || '';\n  if (timeline.includes('Immediately') || timeline.includes('Within 1 month') || timeline.includes('ASAP')) {\n    score += 20;\n    qualificationNotes.push('Urgent timeline (+20)');\n  } else if (timeline.includes('1-3 months') || timeline.includes('Next quarter')) {\n    score += 10;\n    qualificationNotes.push('Medium timeline (+10)');\n  } else {\n    score += 5;\n    qualificationNotes.push('Long timeline (+5)');\n  }\n  \n  // Determine lead tier\n  let leadTier = 'Cold';\n  if (score >= 75) {\n    leadTier = 'Hot';\n  } else if (score >= 50) {\n    leadTier = 'Warm';\n  }\n  \n  scoredItems.push({\n    json: {\n      ...data,\n      leadScore: score,\n      leadTier: leadTier,\n      qualificationNotes: qualificationNotes,\n      scoredAt: new Date().toISOString()\n    }\n  });\n}\n\nreturn scoredItems;"
      },
      "typeVersion": 2
    },
    {
      "id": "c3bf276b-f38e-47e5-87e4-b0055d6aa140",
      "name": "Route by Lead Quality",
      "type": "n8n-nodes-base.if",
      "position": [
        112,
        576
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "leftValue": "",
            "caseSensitive": false,
            "typeValidation": "strict"
          },
          "combinator": "or",
          "conditions": [
            {
              "id": "hot-lead",
              "operator": {
                "type": "string",
                "operation": "equals"
              },
              "leftValue": "={{ $json.leadTier }}",
              "rightValue": "Hot"
            },
            {
              "id": "warm-lead",
              "operator": {
                "type": "string",
                "operation": "equals"
              },
              "leftValue": "={{ $json.leadTier }}",
              "rightValue": "Warm"
            }
          ]
        }
      },
      "typeVersion": 2
    },
    {
      "id": "6ad68ea3-621f-4abd-b8c6-1b6d55c8d95e",
      "name": "Add to HubSpot CRM",
      "type": "n8n-nodes-base.hubspot",
      "position": [
        560,
        384
      ],
      "parameters": {
        "operation": "create"
      },
      "typeVersion": 2
    },
    {
      "id": "cfb3e0c8-9b5d-43e5-ab58-6a5cd542f566",
      "name": "Log to Google Sheets",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        336,
        768
      ],
      "parameters": {
        "columns": {
          "value": {
            "Name": "={{ $json.firstName }} {{ $json.lastName }}",
            "Email": "={{ $json.email }}",
            "Phone": "={{ $json.phone }}",
            "Budget": "={{ $json.budget }}",
            "Source": "JotForm",
            "Status": "New",
            "Company": "={{ $json.company }}",
            "Timeline": "={{ $json.timeline }}",
            "Lead Tier": "={{ $json.leadTier }}",
            "Timestamp": "={{ $now.toISO() }}",
            "Lead Score": "={{ $json.leadScore }}",
            "Company Size": "={{ $json.companySize }}"
          },
          "mappingMode": "defineBelow"
        },
        "options": {},
        "operation": "appendOrUpdate",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "gid=0",
          "cachedResultName": "Sheet1"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "your-spreadsheet-id",
          "cachedResultName": "Lead Tracker"
        }
      },
      "typeVersion": 4.4
    },
    {
      "id": "27c1fd07-3abf-4183-8c5f-a39c859b5652",
      "name": "Notify Sales Team (Hot Lead)",
      "type": "n8n-nodes-base.slack",
      "position": [
        336,
        240
      ],
      "parameters": {
        "text": "\ud83d\udd25 *HOT LEAD ALERT!*\n\n*{{ $json.firstName }} {{ $json.lastName }}* from *{{ $json.company }}*\n\ud83d\udce7 {{ $json.email }}\n\ud83d\udcf1 {{ $json.phone }}\n\n*Lead Score:* {{ $json.leadScore }}/100\n*Tier:* {{ $json.leadTier }}\n*Budget:* {{ $json.budget }}\n*Timeline:* {{ $json.timeline }}\n*Company Size:* {{ $json.companySize }}\n\n*Qualification Notes:*\n{{ $json.qualificationNotes.join('\\n') }}\n\n_Action Required: Follow up within 1 hour!_",
        "otherOptions": {}
      },
      "typeVersion": 2.1
    },
    {
      "id": "a02fd656-7794-45f1-9695-fcf64c51a825",
      "name": "Generate Personalized Email",
      "type": "n8n-nodes-base.code",
      "position": [
        336,
        576
      ],
      "parameters": {
        "jsCode": "// Generate personalized email content based on lead data\nconst items = $input.all();\nconst emailItems = [];\n\nfor (const item of items) {\n  const data = item.json;\n  const firstName = data.firstName || data.first_name || data.name?.split(' ')[0] || 'there';\n  const company = data.company || data.companyName || 'your company';\n  const leadTier = data.leadTier || 'Warm';\n  \n  let subject = '';\n  let body = '';\n  \n  if (leadTier === 'Hot') {\n    subject = `Quick follow-up - Let's get ${company} started!`;\n    body = `Hi ${firstName},\n\nThank you for your interest! I noticed you're looking to get started soon, and I wanted to reach out personally.\n\nBased on your requirements:\n\u2022 Budget: ${data.budget}\n\u2022 Timeline: ${data.timeline}\n\u2022 Company size: ${data.companySize}\n\nI've reserved a spot in my calendar for a demo specifically tailored to ${company}'s needs. We can show you exactly how our solution will work for you.\n\nI'm available for a quick 15-minute call tomorrow. What time works best for you?\n\nLooking forward to speaking soon!\n\nBest regards,\nSales Team`;\n  } else {\n    subject = `Great to connect, ${firstName}! Here's what you need to know`;\n    body = `Hi ${firstName},\n\nThank you for reaching out! I'm excited to learn more about ${company} and how we can help.\n\nI've put together some resources that I think you'll find valuable:\n\n\ud83d\udcca Case Study: How companies like yours improved results by 3x\n\ud83d\udcf9 Quick Demo: See our platform in action (5 min video)\n\ud83d\udcda Guide: Best practices for your industry\n\nI'll follow up in a few days to see if you have any questions. In the meantime, feel free to reply to this email or book a time on my calendar: [Calendar Link]\n\nBest regards,\nSales Team`;\n  }\n  \n  emailItems.push({\n    json: {\n      ...data,\n      emailSubject: subject,\n      emailBody: body\n    }\n  });\n}\n\nreturn emailItems;"
      },
      "typeVersion": 2
    },
    {
      "id": "fbe3c39e-0c45-42c9-a524-89448f0056b7",
      "name": "Send Personalized Email",
      "type": "n8n-nodes-base.emailSend",
      "position": [
        560,
        576
      ],
      "parameters": {
        "options": {
          "replyTo": "user@example.com",
          "allowUnauthorizedCerts": false
        },
        "subject": "={{ $json.emailSubject }}",
        "toEmail": "={{ $json.email }}",
        "fromEmail": "user@example.com"
      },
      "typeVersion": 2.1
    },
    {
      "id": "6959cd8f-3c3e-4584-ad90-382404e801d9",
      "name": "Notify Marketing (Warm/Cold)",
      "type": "n8n-nodes-base.slack",
      "position": [
        336,
        960
      ],
      "parameters": {
        "text": "\ud83d\udccb *New Lead Submission*\n\n*{{ $json.firstName }} {{ $json.lastName }}* from *{{ $json.company }}*\n\ud83d\udce7 {{ $json.email }}\n\n*Lead Score:* {{ $json.leadScore }}/100\n*Tier:* {{ $json.leadTier }}\n\n_Automated nurture sequence initiated_",
        "otherOptions": {}
      },
      "typeVersion": 2.1
    },
    {
      "id": "2a936548-a209-4577-a514-09eafb7a51d2",
      "name": "Create Daily Summary",
      "type": "n8n-nodes-base.set",
      "position": [
        784,
        480
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "summary-text",
              "name": "dailySummary",
              "type": "string",
              "value": "={{ $json.totalLeads }} new leads processed:\n\u2022 {{ $json.hotLeads }} Hot Leads\n\u2022 {{ $json.warmLeads }} Warm Leads  \n\u2022 {{ $json.coldLeads }} Cold Leads\n\nAverage Lead Score: {{ $json.avgScore }}/100"
            }
          ]
        }
      },
      "typeVersion": 3.3
    },
    {
      "id": "6552c1da-6b0d-4501-9768-587246d1b94c",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1152,
        400
      ],
      "parameters": {
        "width": 500,
        "height": 476,
        "content": "# \ud83c\udfaf Lead Qualification & Nurturing System\n\nAuto-captures JotForm leads, scores them by AI, and sends hot leads to sales, others to marketing. All leads go to HubSpot and Google Sheets, with Slack alerts and auto follow-up email.\n\n**Scoring:** Based on email, company size, budget, and timeline.\n\n**Setup:**  \n- Connect JotForm, HubSpot, Sheets, Slack, SMTP  \n- Map fields  \n- Adjust score logic and email templates\n\n**Results:**  \n- Respond faster, convert more, eliminate manual entry\n\n*Built by Daniel Shashko*  \n[Connect on LinkedIn](https://www.linkedin.com/in/daniel-shashko/)"
      },
      "typeVersion": 1
    }
  ],
  "connections": {
    "AI Lead Scoring": {
      "main": [
        [
          {
            "node": "Route by Lead Quality",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "JotForm Trigger": {
      "main": [
        [
          {
            "node": "Extract & Format Lead Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Add to HubSpot CRM": {
      "main": [
        [
          {
            "node": "Create Daily Summary",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Route by Lead Quality": {
      "main": [
        [
          {
            "node": "Add to HubSpot CRM",
            "type": "main",
            "index": 0
          },
          {
            "node": "Log to Google Sheets",
            "type": "main",
            "index": 0
          },
          {
            "node": "Notify Sales Team (Hot Lead)",
            "type": "main",
            "index": 0
          },
          {
            "node": "Generate Personalized Email",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Add to HubSpot CRM",
            "type": "main",
            "index": 0
          },
          {
            "node": "Log to Google Sheets",
            "type": "main",
            "index": 0
          },
          {
            "node": "Notify Marketing (Warm/Cold)",
            "type": "main",
            "index": 0
          },
          {
            "node": "Generate Personalized Email",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Send Personalized Email": {
      "main": [
        [
          {
            "node": "Create Daily Summary",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract & Format Lead Data": {
      "main": [
        [
          {
            "node": "AI Lead Scoring",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Generate Personalized Email": {
      "main": [
        [
          {
            "node": "Send Personalized Email",
            "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 lead qualification process from form submission to personalized follow-up. When a prospect fills out your JotForm, the workflow instantly captures their information, runs it through an intelligent scoring algorithm that evaluates email domain,…

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

More CRM & Sales workflows → · Browse all categories →

Related workflows

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

CRM & Sales

This workflow captures new leads from Typeform, instantly checks if their budget is above $5,000, and prioritizes them for faster sales follow-up. High-budget leads are enriched in HubSpot as contacts

Typeform Trigger, HubSpot, Google Sheets +1
CRM & Sales

This template is perfect for: Marketing Teams looking to automatically qualify inbound leads from campaigns Sales Teams wanting to prioritize high-value prospects instantly Agencies offering lead qual

Form Trigger, Slack, OpenAI +5
CRM & Sales

It extracts key business information using AI, scores the lead based on your ideal customer profile, creates CRM records, notifies your team on Slack, and logs all activity—including failures—to Googl

Gmail Trigger, HubSpot, Salesforce +3
CRM & Sales

This n8n workflow automates end-to-end lead generation, from scraping local businesses to qualifying and sending high-quality prospects directly into your CRM.

HTTP Request, Google Sheets, HubSpot +2
CRM & Sales

This workflow automates the transition of new Shopify customers into HubSpot, using ZeroBounce for multi-layer validation (Validation + AI Scoring).

@Zerobounce/N8N Nodes Zerobounce, Shopify Trigger, Google Sheets +1