Import Local Business Data From Google Maps To Google Sheets

Import Local Business Data From Google Maps To Google Sheets
Reading Time: 5 minutes

Google Maps is an indispensable tool for navigation and also for discovery of new places including–in fact, especially–local businesses. It is a minefield of data. Only if there is a way to scrape these data such as phone number, business website, address, and so on, and have them in a list, and perhaps organise them by categories.

Have you ever wished that? I have. And fortunately, there’s a solution. There’s a tool, a Google Sheets extension that allows us to retrieve data from myriad sources–Google Maps including–to Google Sheets. Amigo Data, that’s what it’s called. The installation link can be found below.

Navigate through this article to learn–discover, if you will–how to import local business data from Google Maps to Google Sheets.

Following are the steps we’ll trace to import local business data from Google Maps to Google Sheets.

  1. Install Amigo Data extension in Google Sheets
  2. Get the endpoint URL
  3. Import the data to Google Sheets

How to import local business data from Google Maps to Google Sheets

Install the Amigo Data extension in Google Sheets

Amigo Data is a lightweight Google Sheets extension that imports and automates data imports to Google Sheets from various sources. It’s easy to use and run.

Amigo Data in Google Workspace Marketplace

Click here to install.

Alternatively, you can get it from Google Sheets.

  • Open a new sheet
  • Go to Extensions→Add-ons→Get add-ons
  • Search for Amigo Data and install

Get the endpoint URL

Sign up or log in to RapidAPI.

Search for Local Business Data and click the most relevant one from the results. Or click this link to go directly to the Local Business Data API documentation page.

Select the relevant API

Click on the Subscribe to Test button and subscribe to a plan of your choice, post which you’ll be able to run the test and retrieve data from Google Maps.

Subscribing to the API

Click Endpoints to go back to the API Playground.

On the left is the list of the type of requests that can be made and the type of data that can be retrieved.

There are two ways we can search for local businesses in a given location–Search and Autocomplete. (For the first one, the method is POST, and the later GET.) We’ll start with the quicker one, ie, Autocomplete.

List of available data enpoints
The query string parameter

The Optional Parameters are, well, optional. They can be used to pin down the results so that only relevant results are returned. Specify the region (the country code), language and coordinates. The coordinates of a location can be found by right-clicking the location in Google Maps.

The optional parameters

After filling in the parameters, we can walk on to the next path to reach our destination; we can use the URL, the parameters and the headers as shown under Code Snippets to retrieve the data.

The url goes in the API URL field, the params in the “+QUERY” section under Details and the headers in “+HEADERS”. But we’ll take a shortcut instead.

Change the language from Node.js (Axios) to Shell→cURL. Copy the URL and note the headers. Be cautious and avoid the apostrophes (in the URL as well as the in the headers); they’ll misguide us.

The API URL and headers

And now for the last mile to the destination, follow the directions given below.

Import the data to Google Sheets

Open Google Sheets and launch Amigo Data from the sheet into which you want to fill the data. To connect to Amigo Data, click Extensions→Amigo Data→Connect.

Launch Amigo Data

You’ll be shown paths to various locations. Take Custom API.

Select Custom API as the source to connect

Paste the endpoint URL in the API URL field. Do not include the apostrophes. (Likewise for the headers.)

The API URL field in Amigo Data

Then expand the Details tab and enter the header. For the endpoint we’ve selected, the headers are:

Name: X-RapidAPI-Key, Value: YOUR_API_KEY

Name: X-RapidAPI-Host, Value: local-business-data.p.rapidapi.com

Preview of the data

The data will be imported into Google Sheets in a moment. Below is a snippet of the imported data.

Snippet of the data

To retrieve the details of a business such as company email, website, and location information, we can use the Business Details endpoint using the business ID–which is the value under data.google_id–obtained with the current endpoint. Likewise for reviews and photos.

Once the data have been imported into Google Sheets, they can be updated automatically at regular intervals–hourly, daily, weekly or on custom days–should you so wish, and get these data sent to your inbox. Click here to learn how set a refresh schedule and set up alerts in Amigo Data.

Visit our blog for to find out about the kinds of data that you can import to Google Sheets and and many other useful–and also cool–things you can do with Amigo Data. Click HERE to find out what adventure awaits you.

Not sure where to start? You can start with one of the articles below.

Some recommended articles:

Automate Flight Data Imports To Google Sheets

Import Eventbrite Data to Google Sheets

Import Zillow data to Google Sheets