Web scraping with Python

4 tutorials

These four tutorials cover the main Python scraping tools. Which Movie Should I Watch using BeautifulSoup is the simplest: it fetches pages with requests and parses HTML with BeautifulSoup to pick a movie. How To Scrape With Python and Selenium WebDriver drives a real browser, which you need for pages that render content with JavaScript or require clicking and logging in.

Scrape a Website with Scrapy and MongoDB, from Real Python, builds a proper crawler with Scrapy spiders and stores the results in MongoDB. Marco Bonzanini's Mining Twitter Data with Python is a multi-part series on collecting tweets and analyzing them with text processing and term frequencies. Twitter, now X, ended free API access in 2023, so the collection steps no longer work as written, but the analysis parts still apply to any text data.

Start with BeautifulSoup, move to Selenium for dynamic pages, and use Scrapy once you need to crawl many pages. Check a site's terms and robots.txt before scraping it.

Esc

Type to search every entry. ↑↓ to move, Enter to open.