This workflow corresponds to n8n.io template #5020 — we link there as the canonical source.
This workflow follows the Form Trigger → Gmail 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 →
{
"id": "LFP3MXxMct1PkZeO",
"meta": {
"templateCredsSetupCompleted": true
},
"name": "Google Map Scraper",
"tags": [
{
"id": "1Ub6auawM61rJ4PA",
"name": "tutorials",
"createdAt": "2025-04-26T03:07:52.593Z",
"updatedAt": "2025-04-26T03:07:52.593Z"
}
],
"nodes": [
{
"id": "2ec7af37-3960-49d3-8401-7a2ee1a55d3e",
"name": "Call APIFY Actor",
"type": "n8n-nodes-base.httpRequest",
"position": [
-320,
-40
],
"parameters": {
"url": "https://api.apify.com/v2/acts/compass~crawler-google-places/run-sync-get-dataset-items",
"method": "POST",
"options": {},
"jsonBody": "={\n \"includeWebResults\": false,\n \"language\": \"en\",\n \"locationQuery\": \"{{ $json.City }},{{ $json.Country }} \",\n \"maxCrawledPlacesPerSearch\": 25,\n \"maxImages\": 0,\n \"maximumLeadsEnrichmentRecords\": 0,\n \"scrapeContacts\": true,\n \"scrapeDirectories\": false,\n \"scrapeImageAuthors\": false,\n \"scrapePlaceDetailPage\": false,\n \"scrapeReviewsPersonalData\": true,\n \"scrapeTableReservationProvider\": false,\n \"searchStringsArray\": [\n \"{{ $json['Search Query'] }}\"\n ],\n \"skipClosedPlaces\": false,\n \"website\": \"withWebsite\"\n} ",
"sendBody": true,
"specifyBody": "json",
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth"
},
"credentials": {
"httpHeaderAuth": {
"name": "<your credential>"
}
},
"typeVersion": 4.2
},
{
"id": "368d2b5c-01b0-4bf6-b188-e03139804716",
"name": "Filter Entries With Emails",
"type": "n8n-nodes-base.filter",
"position": [
-100,
-40
],
"parameters": {
"options": {},
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "ddb43b31-a96f-4415-8ad3-373a12271ba0",
"operator": {
"type": "array",
"operation": "notEmpty",
"singleValue": true
},
"leftValue": "={{ $json.emails }}",
"rightValue": ""
}
]
}
},
"typeVersion": 2.2
},
{
"id": "85117f2d-9169-4d73-b501-9797d7e967b4",
"name": "Convert to File",
"type": "n8n-nodes-base.convertToFile",
"position": [
120,
-40
],
"parameters": {
"options": {
"fileName": "contacts.csv",
"delimiter": ",",
"headerRow": true
},
"binaryPropertyName": "contacts"
},
"typeVersion": 1.1
},
{
"id": "34ad4761-dbd5-4a12-9e12-abb82aaa35f5",
"name": "On form submission",
"type": "n8n-nodes-base.formTrigger",
"position": [
-540,
-40
],
"parameters": {
"options": {},
"formTitle": "Google Maps Scraper",
"formFields": {
"values": [
{
"fieldLabel": "Search Query",
"requiredField": true
},
{
"fieldLabel": "City",
"requiredField": true
},
{
"fieldLabel": "Country",
"requiredField": true
},
{
"fieldLabel": "Your Email"
}
]
}
},
"typeVersion": 2.2
},
{
"id": "92109cc0-6d94-4c67-8f4a-ebe1c1134d53",
"name": "Sticky Note",
"type": "n8n-nodes-base.stickyNote",
"position": [
-840,
-400
],
"parameters": {
"width": 720,
"height": 180,
"content": "Google Maps Lead Scraper\n\nThis workflow collects business leads from Google Maps using APIFY, filters businesses with email addresses, and emails the results as CSV.\nRequired: APIFY API Key, Gmail Account\nAPIFY Documentation: https://apify.com/\nHere is a video tutorial on how this automation works: [https://www.youtube.com/watch?v=Kz_Gfx7OH6o](Build Google Maps Scraper with n8n to Auto-Collect Business Leads via Email)"
},
"typeVersion": 1
},
{
"id": "169fef09-8f71-40a2-a615-f6c709f33bcd",
"name": "Send Email",
"type": "n8n-nodes-base.gmail",
"position": [
340,
-40
],
"parameters": {
"sendTo": "={{ $node['On form submission'].json['Your Email'] }}",
"message": "Please find the attached leads",
"options": {
"attachmentsUi": {
"attachmentsBinary": [
{
"property": "contacts"
}
]
},
"appendAttribution": false
},
"subject": "Your Google Maps Leads Are Here"
},
"credentials": {
"gmailOAuth2": {
"name": "<your credential>"
}
},
"typeVersion": 2.1
}
],
"active": true,
"settings": {
"executionOrder": "v1"
},
"versionId": "e4606ba6-a497-43d4-9499-9a3296e67485",
"connections": {
"Convert to File": {
"main": [
[
{
"node": "Send Email",
"type": "main",
"index": 0
}
]
]
},
"Call APIFY Actor": {
"main": [
[
{
"node": "Filter Entries With Emails",
"type": "main",
"index": 0
}
]
]
},
"On form submission": {
"main": [
[
{
"node": "Call APIFY Actor",
"type": "main",
"index": 0
}
]
]
},
"Filter Entries With Emails": {
"main": [
[
{
"node": "Convert to File",
"type": "main",
"index": 0
}
]
]
}
}
}
Credentials you'll need
Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.
gmailOAuth2httpHeaderAuth
For the full experience including quality scoring and batch install features for each workflow upgrade to Pro
About this workflow
Marketers, lead generation agencies, freelancers, consultants, and sales teams who need to collect business leads from Google Maps. Small business owners looking to build targeted local business lists. Anyone interested in automating web scraping without coding skills. What…
Source: https://n8n.io/workflows/5020/ — original creator credit. Request a take-down →
Related workflows
Workflows that share integrations, category, or trigger type with this one. All free to copy and import.
📚 Learners and educators who want a fast overview of a creator’s entire catalog. 🧩 Research, SEO, and content ops teams building an intelligence layer on top of YouTube channels.
A customized n8n workflow inspired by the Lead Generation Agent template. It automates B2B lead scraping via Apify, extracts contact emails with AI, sends cold emails via Gmail, and logs every interac
This workflow uses the Zyte API to automatically detect and extract structured data from E-commerce sites, Articles, Job Boards, and Search Engine Results (SERP) - no custom CSS selectors required.
Automate LinkedIn lead generation by scraping comments from targeted posts and enriching profiles with detailed data
This n8n workflow collects leads from Google Maps, scrapes their websites via direct HTTP requests, and extracts valid email addresses — all while mimicking real user behavior to improve scraping reli