We've been seeing a lot of users mention they're using SerpApi with n8n; either with our official SerpApi node or with the original SerpApi AI tool. One of the most satisfying things to see has been how the n8n community has been creating unique templates for various SerpApi use cases. Use cases range from detecting scams online to finding promo codes to lead generation. You can see some of those community generated templates here.
I thought it would be fun, and hopefully useful, to create a workflow template myself. The idea I had was to make it easier to scrape Google Maps Reviews and sync them to a Google Sheet. Specifically, the user should be able to enter any query they might run on actual Google Maps to scrape reviews and store them.
In this post, I'll briefly explain how to get this workflow template up and running.
Basic Setup
You'll need the following tools to use this template:
- SerpApi: If you don't already have a SerpApi account, you can register for one here and get 250 free searches per month: https://serpapi.com/dashboard
- n8n: There are lots of ways to use n8n. You can opt for a local installation, n8n Cloud, or a 3rd-party n8n host like Railway.
- Google Sheets API: You probably have Google Sheets already, but to connect n8n to it programmatically, you'll need to create an OAuth app with a Client ID and Secret in Google Cloud. Instructions for that are here: https://docs.n8n.io/integrations/builtin/credentials/google/oauth-generic
Workflow Import
Next, you'll need to copy/download the workflow template. The cleanest way to do this is to import the template directly into your instance from n8n's template site.
To do this, click 'Templates' in the sidebar menu of your n8n instance as highlighted below.

Then search for and navigate to our template entitled "Google Maps Reviews to Google Sheets Sync using SerpApi". Once found, click the 'Use for free' button.

This will open the following menu. Click the 'Import template' option.
From what I can tell the 'Import template' option only appears if you navigate to the template site from your n8n instance's 'Templates' link. It doesn't work if you access the site normally. You're welcome to copy the JSON and paste it into an n8n workflow, but it makes setting credentials a bit less straightforward.

You can find our template listing directly here:

Credentials
Assuming you followed the 'Import template' option, you should be presented with the following screen to set your SerpApi and Google Sheets credentials.

The SerpApi credentials should be pretty straightforward. Simply copy your SerpApi API key into the 'API Key' field and save it. You should then see a green 'Connection tested successfully' alert like this:

Google Sheets is a bit more complicated. You'll need to enter the Client ID and Secret from Google Cloud as configured in the Basic Setup section earlier.
You'll also need to make sure your n8n OAuth Redirect URL is added as an Authorized Redirect URI in Google Cloud. Mine is shown in the screenshot below. Yours will be different unless you're using a local installation like me.

What it should look like in Google Cloud:

Once you've added all that, click 'Sign in with Google' and follow the sign in prompts.

You may get a notification at some point warning you that Google hasn't verified this app. If you entered your own app details, you have no need to worry since you're only sharing your details with yourself. Simply continue and don't click 'Back to Safety'.
If all went well, you should get a green alert like this:

Node Configuration
Now we need to configure a few nodes in the workflow.
Well, the first one is actually optional to change. The workflow is set to only scrape a maximum of 50 Google Maps Reviews per Google Maps Place. If you'd like to change this, double click the 'Set Review Limit' node.

Replace 50
with whatever review limit you prefer. Set it to a very high number like 50000
if you want to get all reviews, but note that the more reviews you request, the more SerpApi search credits you'll consume.

You'll certainly want to add your own search query. Do that by opening the 'Search Google Maps' node.

Update the 'Search Query' field with whatever query you want to run. Remember it can be anything you would search in actual Google Maps.
I recommend including a specific location like tacos in {a location}
to ensure your results are in the city/location you want. You're welcome to include GPS Coordinates instead if you prefer, but this is a bit more complicated. If you include neither, you will get results in a random location based on the proxy server used to handle your search.
If you're familiar with SerpApi's Google Maps API, feel free to add whatever customizations you wish. Otherwise, leave everything as is.
For this example, let's search for tacos in austin tx
.

Finally, we need to connect n8n to a Google Sheet where we'll sync all the scraped Google Maps Reviews.
You can copy this Google Sheet template which matches the fields I've been scraping: https://docs.google.com/spreadsheets/d/1kYDkOctdDYbFxc95_sVVxwLSVkOI8wsWEgBIeK5MluI/edit?usp=sharing
Open the 'Append Reviews' node to connect your sheet.

You'll see the template already included the mappings for each field. Unfortunately, when you connect your Google Sheet, n8n will wipe these away so you'll need to re-add them afterwards. Use the following as a reference for setting them up again.
place_name = {{ $('Initialize Vars').first().json.place_name }}
iso_date = {{ $json.reviews.iso_date }}
rating = {{ $json.reviews.rating }}
snippet = {{ $json.reviews.extracted_snippet.original }}

I recommend connecting your Google Sheet 'By URL'. This way you can copy paste the URL into the 'Document' and 'Sheet' fields. n8n will pull in the column headers automatically. You can then map the fields as displayed above. Make sure you set them as 'Expression', not 'Fixed'.
I suggest also enabling 'Minimise API Calls'.
You should be all set! Hit 'Test workflow' to start scraping. You should see your Google Sheet start filling up with reviews.

Hopefully this will be helpful for all your Google Maps Review analysis needs. Please let us know if you have any questions about this workflow by emailing us at contact@serpapi.com