web scraping tool

Is Google Sheets an effective Web Scraper Tool?

Marketing Deep Dive Published on 21 Feb 2022

How much do you use Google Sheets?

If you are one who ends up creating a lot of reports or somebody who is playing with data, scratching it and finding out insights from it - you must have used Google sheets. 

There are some mind blowing functionalities in Google sheets that can make your work easy and understandable. Do you know you can copy paste a table from a webpage into google sheet or even fetch a title from a webpage using google sheets?

Doesn’t it sound wow? A simple tool like Google sheet can be an effective web scraper tool. 

Formula 

Before going to other aspects, let’s start with a bit of technicalities. The formulas that you can use for basic web scraping -

  • Import XML Formula - A formula that can scrape structured data from HTML, XML file Formula - IMPORTXML(url, xpath_query)
  • IMPORTHTML Formula - It is generally used to fetch data from website table     Formula - IMPORTHTML(url, query, index)

There are many more but these two are the basic ones. If you got lost? Don’t worry. It will be clear with examples. 

Example 1 - Scrape a table from website -

Suppose you want to fetch below table from wikipedia to your google sheet

List of high grossing films

Formula used - 

=IMPORTHTML("https://en.wikipedia.org/wiki/List_of_highest-grossing_films","table",1)

Result - 

 

Result of Example 1

Example 2 - How to scrape an Article Title? 

Some might feel that fetching an article title is not a tough task. Why use a formula? It's true that it's not a big task. But think of a situation when you want to fetch a title for 100 articles. 

This formula can make your work in minutes. 

Let me take 2 different articles -

B2B marketing skills
Metaverse blog

Find out the H1 HTML tag 

 

HTML Code

Formula - =IMPORTXML(A2,"//*[@class='main-head single-view-head’]")

Result  :-

 

Result example 2

Example 3 - How to scrape data from Amazon?

Isn’t it amazing that you can even fetch amazon product title, rating and reviews. 

For example, let me use the following product - https://www.amazon.com/Microsoft-Ergonomic-Keyboard-Business-5KV-00001/dp/B00CYX26BC/

Formula - =IMPORTXML(A2,"//*[@id='productTitle']")

Result

Result example 3

If you want to find a price or rating, the formula will be changed a bit. 

To be honest, Web scraping via Google sheets is quite impressive. It can make big monotonous tasks easy. 

So, next time don’t engage in a boring job. Apply a formula and scrape your data easily. 

Hope you enjoyed reading it!!

 



Related Post

Clubhouse Welcome to an Exclusive Social Club - Clubhouse

Are you part of the Clubhouse? If not, you need to up your s...

Published On:20 Feb 2021
Read
QR Code Rebirth of the QR Code post Covid-19

The contactless world has given a fresh lease of life to the...

Published On:10 Nov 2020
Read
social media stories Are Stories the Future of Online Marketing?

Read this blog to understand how story feature in social med...

Published On:24 Aug 2020
Read
audio or video Audio or Video: Who is the King in MENA?

There are two major ways one can consume content either audi...

Published On:10 Aug 2020
Read
voice search in marketing How Voice Search will Influence the Future of Marketing

Voice search refers to the recognition of voice technology t...

Published On:23 Aug 2021
Read
Facebook ads vs Google ads Facebook Ads vs Google Ads - Which is better?

Google Ads and Facebook Ads are often the go-to places for a...

Published On:06 Oct 2021
Read
content marketing strategy Shifting Your Brand's Content Strategy During COVID-19

With covid-19 crises, learn to shift your content marketing...

Published On:25 Aug 2020
Read
Digital marketing trends 7 Digital Marketing Trends to watch out in 2022

The market trends, strategies, decisions are always on the v...

Published On:04 Feb 2022
Read
Death of Big Idea Death of the Big Idea in the Data Driven world

What do you think about role of big idea in data driven wor...

Published On:03 Apr 2021
Read
Brand Storytelling Brand Storytelling - How it Helps to Build a Brand?

Personal brand storytelling connects to emotional psychology...

Published On:16 Nov 2020
Read