Templates / Process Shopify lead emails from Gmail to HubSpot contacts and deals

Process Shopify lead emails from Gmail to HubSpot contacts and deals

Needs changes

by Shahzaib Anwar ✓ · 88 views · created 2025-09-16 · Lead Generation, CRM

Needs changes. This template uses 1 thing(s) that n8n 3.0 removes: Function (legacy). 1 breaking item(s) found. Static check, last run 2026-10-19.

What this workflow does

This workflow has 8 nodes and runs on Gmail events. Along the way it connects Gmail and HubSpot.

How it runs

Trigger: On Gmail events.

  1. Get a message (Gmail): get
  2. Extract From Email (Function): runs custom JavaScript (legacy Function node)
  3. If: checks a condition and branches into true / false
  4. Code: runs custom JavaScript code
  5. Edit Fields (Edit Fields (Set)): sets 7 fields: name, email, city…
  6. Create or update a contact (HubSpot): uses HubSpot
  7. Create a deal (HubSpot): work with deal

Services it uses

GmailHubSpot

Before you upgrade to n8n 3.0

1 thing in this workflow is removed in n8n 3.0. Fix it before you upgrade:

  • Function (legacy) in Extract From Email: replace with Code node, mode 'Run Once for All Items'.
  • Also check Gmail Trigger below v1.4 runs as v1.4 (drafts skipped, max emails per poll).

Rather not rewrite it? Many of these flows can be rebuilt in Make (free plan).

Removed in 3.0Replace with
Function (legacy)
Extract From Email
Code node, mode 'Run Once for All Items'

Nodes used (7)

From the author

📌 Overview This workflow automatically processes incoming Shopify/Gmail leads and pushes them into HubSpot as both Contacts and Deals. It helps sales and marketing teams capture leads instantly, enrich CRM data, and avoid missed opportunities. --- ⚡ How it…

Excerpt from Shahzaib Anwar's description on n8n.io.

View the original on n8n.io → Check your own copy

Get the weekly “what broke” email

New templates, newly broken ones, and n8n release changes. One short email a week.

Form not loading? Subscribe here.