Free Python books: My Top Picks
One of the most beautiful aspects of learning how to code is that most of the learning resources needed are available for free. Here I share my top picks among the Python books freely available online.
First Steps: Beginner Books
If you’re beginning to learn how to code in Python, these are the titles that will help you.
Think Python
by Allen B. Downey
Green Tea Press
—–
This is one of the first books that I read when I started learning Python, back in the day of the first edition. The third edition was published in 2024 and features plenty of interactive exercises based on Jupyter. This book is one of the best introductions to Python programming that I’ve seen, also thanks to the author’s ability to explain programming concepts in a very clear way.
Check out the other good material that Allen B. Downey has made available for free on the Green Tea Press website, including Think Bayes, Think Stats and Think Java.
Automate the Boring Stuff with Python
by Al Sweigart
No Starch Press
—–
This is a go-to book after you’ve got your hands on the basics of the language. It offers coding practice with interesting examples like sending email, web scraping, automating spreadsheets and manipulating images. There are more free Python books from the same author on: inventwithpython.com.
Python for Everybody
by Charles Severance
—–
Another good introduction to programming in Python. This book accompanies a free video course made available by freeCodeCamp, and has versions translated to other languages. An interactive version is available on Trinket.
Practice and Project Ideas
The best way to learn any programming language is by practising coding on projects. Here are some titles that will keep your typing hands busy.
Invent Your Own Computer Games with Python
by Al Sweigart
No Starch Press
—–
Again from the author of Automate the Boring Stuff, this book has reached its 4th edition: a testament of the public success achieved. It contains plenty of fun activities and games to keep your hands busy working with Python.
Invent Your Own Computer Games
Cracking Codes with Python
by Al Sweigart
No Starch Press
—–
Al is a very prolific writer and this title is no less compelling than the ones mentioned earlier. Working on cyphers and hacking programs for these cyphers can be a great preparation for coding interviews.
Intermediate Python Books
Learn More Python the Hard Way
by Zed A. Shaw
—–
This online book comes from the author of Learn Python the Hard Way, a very popular online course for beginners in Python. Unlike the course, this online version of the book is available for free.
Learn More Python the Hard Way
Beyond the Basic Stuff with Python
by Al Sweigart
No Starch Press
—–
The Invent with Python author is an inexhaustible source of great learning material: this book is packed with concepts that can bring you to a professional level as a Python coder. All explained in a very light and digestible way.
Web Development in Python
Finally, some books that will make progress with Flask and Django.
The Flask Mega Tutorial
by Miguel Grinberg
—–
This awesome tutorial will guide you through all the steps needed to install Flask, create a microblog web app, integrate it with a database and deploy it. It starts with simple initial steps, but then it goes very deep into several technical aspects that programmers face when developing a web application.
Test-Driven Development with Python
by Harry J.W. Percival
—–
This book will guide you through the process of Test-Driven Programming (TDD) by developing a web app using Django ans automating its tests using Selenium.
Test-Driven Development with Python
And more…
There are many more titles that I wish to include in this list. In particular, there’s excellent free material on Data Science and Finance using Python that is available for free. However, this is intended to be a short post: I should soon write a post about the material on those topics.