Extract thousands of Google Results into your Google Sheets

Scraping, i.e. the extraction of data from websites, is one of the most widely used techniques on the web. The uses are innumerable: analysis of competitors, its SEO positioning, content generation, influencers tracking, etc.

Once the data is extracted, you have to process it, and there, nothing like our good old spreadsheet… In short, Scraper + Google Sheets is a marketers’ paradise!

One of the most coveted sites for scraping is of course our dear Google. Scraping Google allows to:

  • Know the position of your site with regard to several keywords
  • Understand your environment by analyzing the sites that rank best and follow the positions of competitors
  • Analyze the most effective content
  • Understand the keywords and sentence formulations that work best

In this tutorial, you will discover the ultimate no code solution to generating a table of thousands Google results in Google Sheets.

Introducing ImportFromWeb 

ImportFromWeb is a Google Sheet add-on that can collect any data from any website into a spreadsheet using a single function. This plugin is very easy to use and does not require any coding skills: anyone can learn to use it in less than 10 minutes! 

To collect data from Google SERPs, ImportFromWeb adds a new function to Google Sheets, named =IMPORTFROMGOOGLE( ). 

How to use =IMPORTFROMGOOGLE( ) function? 

To collect data with =IMPORTFROMGOOGLE( ) nothing more simple: 

Firstly install the add-on and then activate it through the extension menu on the Google sheet. Once the add-on is activated you will be able to access the =IMPORTFROMGOOGLE( ) function. 

The first way to use the IMPORTFROMGOOGLE function is to write a keyword or a key sentence for which you want to get the results from Google SERP. You will then need to write the “=IMPORTFROMGOOGLE( )” in another cell, insert brackets and select the cell where the keyword is written just like this

=IMPORTFROMGOOGLE(A1)

This will automatically deliver you the first 10 results from Google with the associated data ( keyword, header, body, link…). If there is no information in a cell, it means that this information was not given on Google, and you’ll get an error message #SELECTOR RETURNS NULL 

Thanks to this function, you are able to collect results for more than 1kwd, actually up to 50 keywords. For this, you just have to select all the keywords in your function. For example: =IMPORTFROMGOOGLE (B2:B7). 

The second way to use =IMPORTFROMGOOGLE( ) is if you need specific data. You have a range of selectors you can use and these selectors will give you the data you need. 

The function will be written as:

=IMPORTFROMGOOGLE(“your keyword(s)”,“selector(s)”)

For example:

=IMPORTFROMGOOGLE(A2:A3,"link”) 

Hence, you are able to use all the selectors at the same time. The available selectors are: “search_term”, “title”, “body” and  “date”. 

Then, there is one additional selector that collects the number of results for your keyword; useful right? It is named “total_results”. 

The options to empower your Google Scraping

Finally, the function comes with additional features using options. The options will allow you to collect data using criterions you impose and they must be imputed as a third argument within your formula:=IMPORTFROMGOOGLE(“your keyword(s)”,“selector(s)”,”option(s)”) 

The first useful option is called “numResults”. It allows you to extend the number of results extracted for each keyword.

In the following example, the “numResults” set this number at 30: 

=IMPORTFROMGOOGLE(A2:A3,B1:D1,G1:H1)

A2:A3 = keyword

B1:D1 = list of selectors

G1= numResults (option)

H1= number of results you desire

The second option that can be used is “compare”. If there is too much data, the spreadsheet might look disorganized and not neat. By using the option “compare”, all the data in the cells will be adapted for users to be able to read. 

The function will be written as:

=IMPORTFROMGOOGLE(“keywords”, “compare”)

The third option is “languages”. It collects the data in the language you select. For example, if you select “en” as a language, it will select data from websites written in English. By default it takes the language of the domain.

=IMPORTFROMGOOGLE(“keywords”, “selector”, “languages:en”)

The fourth option is “period”. Period allows you to filter the websites collected thanks to the date of the publishment of the website. By using this option, you can select results from the past hour, past 24 hours, past week, past month or past year based on the date posted.

The function will be written as: =IMPORTFROMGOOGLE(“keywords”, “selectors”, “period: year”).

The last option is “includeOmittedResults” and it allows you the function to collect data from omitted results (results not shown by google). If the data scraping takes more time than usual, do not worry!  

Again we can mix the options within the same function. 

As for the keyword(s)s and selector(s), you can write the option directly into the function or simply refer to cells

=IMPORTFROMGOOGLE("your keyword", "your selector", "numResults:300,compare")

Or 

=IMPORTFROMGOOGLE(A1,A3:B3,E1:F1)

Finally, we want to make your life easier and we have designed a template using =IMPORTFROMGOOGLE() to guide you through your Google SERPs extraction tasks. You just have to enter your keyword in “Your searches” section, select your desired options and define the selectors you want thanks to the drop down menu: all the data will be extracted for you in a table!

A video tutorial is as well available to guide you through IMPORTFROMGOOGLE: https://www.loom.com/share/8e148c96333d4d3fb9c0701acdd30b1a

If you have any doubts or any question about this function or about =ImportFromWeb, do not hesitate to contact us through our website page: https://nodatanobusiness.com/contact-us/.