A Guide to Web Scraping in Python using BeautifulSoup

Today we’ll discuss how to use the BeautifulSoup library to extract content from an HTML page. After extraction, we’ll convert it to a Python list or dictionary using BeautifulSoup!

What Is Web Scraping, and Why Do I Need It?

The simple answer is this: not every website has an API to fetch content. You might want to get recipes from your favorite cooking website or photos from a travel blog. Without an API, extracting the HTML, or scraping, might be the only way to get that content. I’m going to show you how to do this in Python.