Google Maps Business Data Extraction and Reporting - n8n Workflow

Automate lead generation by scraping Google Maps results via the SerpAPI n8n node. Export structured business data to Google Sheets and XLSX files using this comprehensive n8n workflow.

Workflow Preview

Ready to automate?

Download this n8n workflow template and start using it instantly.

Who is this best for?


  • Sales and Marketing Teams: Seeking automated lead generation lists scraped directly from Google Maps.

  • Data Analysts: Needing structured, location-based business data for market research.

  • n8n Automation Specialists: Looking for advanced n8n templates that combine conversational triggers, external APIs (SerpAPI), and multi-format data export.

  • Users of n8n: Those who need to convert raw API JSON output into clean tabular data for reporting.

Overview

This powerful n8n workflow automates the demanding process of scraping business data from Google Maps. Instead of manually searching, this solution uses the SerpAPI n8n node to programmatically retrieve detailed listings (such as location, name, and rating) based on an initial search query provided through a conversational interface (the n8n trigger). This specific n8n workflow is perfect for generating high-quality lead lists or conducting local market analysis efficiently. The automation ensures that the raw data is cleaned and standardized using multiple Set n8n node instances before being exported. The final, structured output is then simultaneously recorded in Google Sheets for dynamic access and converted into a standard XLSX file, providing maximum flexibility for data consumption.

How it Works

This efficient n8n workflow initiates execution whenever the designated n8n trigger, 'When chat message received', receives input. This allows dynamic search parameters to be fed into the system via a chat interface.


  1. Trigger & Variables: The workflow starts with the chat message n8n trigger. Subsequent 'Variables Chat' and 'Initialization' Set n8n node instances prepare the dynamic search query for the core scraping action.

  2. SerpAPI Extraction: The 'Extract SerpAPI Map' n8n node utilizes the SerpAPI service to execute a Google Maps search based on the prepared query, returning a large JSON payload containing numerous business results.

  3. Data Iteration: The 'Split Out SerpAPI' n8n node takes the array of search results and processes each business listing individually, ensuring that downstream cleaning nodes handle one item at a time.

  4. Cleaning and Standardization: The 'Extract Data' and 'Prepare Data' Set n8n node operations perform crucial transformation steps. They select the necessary fields (like address, name, phone) and remap them to standard column names, making the data highly usable.

  5. Multi-Format Export: The cleaned data proceeds down two separate export paths. One path uses the 'Upsert Data in Sheets' Google Sheets n8n node to append or update the data in a specified spreadsheet. The parallel path utilizes the 'Get Data in XLSX' Convert To File n8n node to package the entire dataset into a downloadable spreadsheet file, completing the automated data delivery of this sophisticated n8n workflow.

Installation Guide

To deploy this n8n template, follow these steps:


  1. Import: Copy the provided JSON data and import it directly into your n8n instance as a new workflow.

  2. Credentials Setup:

SerpAPI: You must configure credentials for the 'Extract SerpAPI Map' n8n node. This requires a SerpAPI API key.
Google Sheets: Set up Google Sheets OAuth2 credentials for the 'Upsert Data in Sheets' n8n node. Ensure the service account (or authorized user) has write access to the target spreadsheet.

  1. Trigger Activation: The 'When chat message received' n8n trigger needs to be associated with an active Chat agent/interface (likely Langchain based). You will need to note the displayed Webhook ID.

  2. Configuration: In the 'Upsert Data in Sheets' n8n node, specify the ID of your target Google Sheet and the sheet name where the scraped business data should be written.

  3. Activation: Save the n8n workflow and toggle it to 'Active' to start listening for the chat trigger events.

Node Details

When chat message received (n8n trigger): Serves as the starting point of the n8n workflow, accepting dynamic search queries via an integrated chat interface. This unique n8n trigger is what allows for highly flexible execution.
Extract SerpAPI Map (SerpApi n8n node): The core scraping action. Configured to query Google Maps for businesses matching the input criteria. Requires SerpAPI authentication to run this essential n8n node.
Split Out SerpAPI (Split Out n8n node): Splits the array of map results returned by the SerpAPI n8n node into individual items, allowing subsequent n8n node steps to process each business record independently.
Extract Data / Prepare Data (Set n8n node): Multiple Set n8n node instances responsible for mapping, cleaning, and filtering the large dataset. They ensure only relevant fields (Name, Address, Rating, etc.) are passed to the final export steps.
Upsert Data in Sheets (Google Sheets n8n node): Handles the structured persistence layer. Configured to append or update the extracted business data into a designated row/column structure within a Google Sheet, making this n8n workflow highly valuable for lead management.
Get Data in XLSX (Convert To File n8n node): Converts the processed JSON data into a binary XLSX file format, providing a robust, static export option for the output of the n8n workflow.

Related n8n Workflows

Paid

Nodes: 7 Nodes
Updated: December 26 2025
View all
Created by
Andrew
Andrew

Analyst-Developer

Featured*