A Beginner’s Guide to Web Scraping Using Python

Sean LaFlam
2 min readNov 26, 2022

--

Learn what web scraping is and see some of the best tutorials for Python web scraping

Python is a versatile language that can be used for a variety of purposes, one of which is known as web scraping. In this blog post, we will explore some of the best tutorials on web scraping using Python.

Web scraping is the process of extracting data from websites, whether it be costs of various products for price comparison, or email addresses for employees at a company, or even scraping social media for sentiment analysis on a certain topic. This can all be done manually, but more often than not, it is automated using tools like Python which are able to aggregate data on a much larger scale and do it near instantaneously.

There are many different ways to extract data from websites with Python, so we will look at tutorials for both beginners and more experienced users. Whether you are just getting started with web scraping or you are looking for more advanced techniques, we have something for you in this blog post!

How Does Web Scraping Work Exactly?

Scraping is the act of extracting data from a webpage for some other purpose

When you run the code for web scraping, a request is sent to the URL that you have mentioned. As a response to the request, the server sends the data and allows you to read the HTML or XML page. The code then, parses the HTML or XML page, finds the data and extracts it.

To extract data using web scraping with python, you need to follow these basic steps:

  1. Find the URL that you want to scrape
  2. Inspecting the Page
  3. Find the data you want to extract
  4. Write the code
  5. Run the code and extract the data
  6. Store the data in the required format

Beginner’s Guide

Check out the video above from Tinkernut and you can write a basic scraper in under 10 minutes of work. I highly recommend going through the process if you’re a beginner or even a more experienced programmer who is a little rusty.

Moderate Experience

Once you’re a little big more familiar with scraping you can start adding more specific skills such as scraping from multiple pages. The tutorial Below will walk you through that

Another really neat trick is using Python to scrape a PDF instead of a website. The tutorial below will walk you through that.

Advanced Web Scraping

Finally, once you’ve mastered everything above, try to seek out more niche skills such as scraping a very specific format of website that may behave different than a standard HTML/CSS website you’re used to. A good example is a dynamically loading page. Check out the tutorial below:

I will update this blog as I find more great tutorials. Cheers!

--

--