Loop & Branch: practical Python and web development tutorials

Tested answers for everyday code.

Short, tested answers to the questions developers actually search for: how to split a string, why pandas cannot decode a CSV, what NoneType object is not subscriptable means, how to send a request with urllib3.

Every tutorial is written for this site, runs on current versions of the libraries it covers, and links to the official documentation for the details.

Python tutorialsData with pandas & NumPy

Close-up of black keyboard keys for brackets, braces, colon and quote
Featured comparison

Scrapy vs Selenium: choosing a Python web scraping tool

Architecture, JavaScript rendering, speed, scaling and pipelines compared, with working code for each and a note on when scrapy-playwright is the better middle ground.

Read the comparison
A spider's web covered in dew between dry stems at dawn

Start here

The six questions readers bring most often.

Browse by section

Every tutorial on the site, grouped the way you would look for it.