How to Extract Data from Communicating Google Maps or a Store Locator?

Anil Prajapati
4 min readMay 28, 2021

At times, the data that you need to extract from the website could be within the map.

A general scenario might include scraping data from Google Maps having different store locations.

Now, let’s understand how to utilize a web scraper for scraping data from a communicating map.

Here, we will extract store locators' Google Maps for phone numbers, addresses, as well as emails.

A Powerful Data Scraper

Here, we will use X-Byte’s powerful Google Maps web scraper, which can deal with any website. Ensure to download as well as install X-Byte’s store locator data scraper before you start.

We would also extract data from the store locator page of Long & Mcquade’s Ontario.

How to Extract Data from Locations Maps?

Now, the time has come to do the scraping.

Remember that each map is different. Anyone that you deal with may look diverse than the one that we are extracting from. Although, this guide needs to cover a general scenario.

  1. Install as well as open X-Byte Scraper. Click on the “New Project” as well as enter a URL from where you are scraping data. Here, we are extracting data from the Ontario store locator on a Long & Mcquade site. When submitted, a URL would render inside an app as well as “Select” command would be made by default.
  2. By clicking on “location pins” on a map, it will make a newer selection on the left-hand sidebar, and rename the selection to “location”. Then, click on the second pin to choose them all.
  3. After that, click on the PLUS (+) symbol next to the “location” selection and click on the Advanced option and select the “Begin New Entry” option. Then rename the command to the “map”.
  4. Utilize the icon given next to the “extract name” option to delete that.
  5. Then click on the PLUS (+) symbol next to the “map” command as well as select the “Click” option. One pop-up will come asking if it is the next page key. Then click on the “No” option and select “Continue executing the current template”
  6. After that, click on the PLUS (+) symbol next to the “map” selection as well as select the “select” option. Utilize this command for clicking on a location name, which comes on the top of a location pin on a map. You may need to press the buttons Ctrl+2 from your keyboard to choose a location name rather than the whole div. Just rename the selection with “location_name”
  7. After that, click on the PLUS (+) symbol next to the “location_name” selection as well as add the “extract” option. It will scrape the name of every location.
  8. Also, let’s scrape the phone numbers of every location. For doing this, Hold the shift button over the “location_name” choice for making its PLUS (+) symbol appear, then click on it and add the command ‘Relative Select’. Using this command, just click on the name of the location as well as then on the phone number. Once more, you may need to utilize Ctrl+2 keys for selecting a phone number rather than the entire div. One arrow will come to indicate a relationship that you are making.

X-Byte is now scraping the location names as well as phone numbers for every location.

Scrape Emails and Store Addresses from the Map

In this map, every location has a link for viewing more store details. Now, we will instruct X-Byte to click on the links as well as scrape every store’s email address and address.

Run Your Scraper

Now, it’s time to scrape all the information you have chosen for all map locations.

Just click on the green-colored button “Get Data” on the left sidebar. So that, you can run, test, or schedule the scraping job.

Here, we would run that straight away. X-Byte would now go as well as collect the data that you have chosen.

Final Thoughts

Once X-Byte has done scraping the selected data, you can download it in the JSON or Excel file.

In case, you have any queries about the project, contact us through the live chat option on our site and we will help you.

Happy scrapping!

Originally published at https://www.xbyte.io.

--

--