# Best books for learning machine learning, from math to practice

Source: https://listme.name/blog/best-books-for-learning-machine-learning
Published: 2026-10-10


A machine learning reading list works best as a path. Start with the mathematics or statistics the models rely on, move to code that builds models, then read research texts that cover theory and newer methods. The [machine learning books ranking](/best/ai-and-machine-learning-books) covers the general field, and the [reinforcement learning and edge ML ranking](/best/reinforcement-learning-and-edge-ml-books) covers agents and small devices. Start from the math you can handle now, then pick the next book on the path.

## Start with statistics and Python

[An Introduction to Statistical Learning, Python edition](/books/introduction-to-statistical-learning), by Gareth James, Daniela Witten, Trevor Hastie, Robert Tibshirani and Jonathan Taylor, is the most approachable text in its ranking. It covers regression, classification, resampling and tree-based methods, with a Python lab in each chapter. The labs assume some Python skill. A free PDF is available.

## Build the math you need

[Mathematics for Machine Learning](/books/mathematics-for-machine-learning) by Marc Peter Deisenroth, A. Aldo Faisal and Cheng Soon Ong was published by Cambridge University Press in 2020. It covers linear algebra, analytic geometry, matrix decompositions, vector calculus, probability and optimization, and connects them to regression, PCA and support vector machines. The authors keep a free PDF online. It has few worked code examples and assumes university-level mathematics, so pair it with a practical text.

The ranking notes that several of the theory-first books assume calculus and linear algebra, so check your footing before you start them.

## Learn the foundations of deep learning

[Deep Learning](/books/deep-learning-book) by Ian Goodfellow, Yoshua Bengio and Aaron Courville was published by MIT Press in 2016, and its full text is free to read online. It covers applied mathematics, machine learning basics, and feedforward, convolutional and recurrent networks. It predates transformers and large language models and has little code, so the ranking pairs it with a current practical guide.

[Probabilistic Machine Learning](/books/probabilistic-machine-learning) by Kevin P. Murphy, a 2022 MIT Press textbook, builds machine learning on probability and Bayesian reasoning. A free draft PDF is published under a non-commercial, no-derivatives license, and its figures come with code in [Colab](/software/google-colab) notebooks. Its entry notes that it is long and mathematical for self-study.

## Practice: build models in code

[Dive into Deep Learning](/books/dive-into-deep-learning) by Aston Zhang, Zack C. Lipton, Mu Li and Alex J. Smola is an interactive online book. Each section is an executable Jupyter notebook, with versions in PyTorch, JAX, TensorFlow and MXNet, and the full text is free on the web. It covers less theory than the Goodfellow text, and no finished print edition is listed.

[Deep Learning with Python](/books/deep-learning-with-python), third edition, by François Chollet and Matthew Watson, was published by Manning in September 2025. It teaches deep learning and generative AI with Keras 3. Manning sells print, PDF and ePub editions, and the book has no free full text. It is light on the mathematics behind the models.

> **Compare:** [Deep Learning with Python, Third Edition vs Dive into Deep Learning](https://listme.name/compare/deep-learning-with-python-vs-dive-into-deep-learning). 88.5 and 91.0, ranked #5 and #3 in best AI and machine learning books.

The ranking also includes [Hands-On Machine Learning](/books/hands-on-machine-learning) (87.0), a paid book that teaches methods through code with scikit-learn, Keras and TensorFlow, sold in print with no free full text online.

## Research and theory

[Speech and Language Processing](/books/speech-and-language-processing) by Dan Jurafsky and James H. Martin is still a third-edition draft. The authors post updated chapters and a single PDF on the Stanford site, and the content can change. It covers text processing, language models, transformers and speech.

[Pattern Recognition and Machine Learning](/books/pattern-recognition-and-machine-learning) by Christopher M. Bishop, a 2006 Springer textbook, explains probability, graphical models and kernel methods from a Bayesian viewpoint. It predates modern deep learning, and its publisher page lists a softcover but no free full text.

For reading research papers alongside books, see [best AI tools for research and reading papers](/blog/best-ai-tools-for-research-and-reading-papers).

## Reinforcement learning

[Reinforcement Learning: An Introduction](/books/reinforcement-learning-an-introduction), second edition, by Richard S. Sutton and Andrew G. Barto was published by MIT Press in 2018. The authors post the full PDF for free, and the ranking calls it the standard free text for the subject. It covers value functions, temporal-difference learning and policy gradients, with a strong focus on theory.

[Reinforcement Learning and Optimal Control](/books/reinforcement-learning-and-optimal-control) by Dimitri P. Bertsekas offers a free PDF for instructional use, and its author's page describes a 2025 second edition. It treats the subject through dynamic programming and is written at graduate level.

[Reinforcement Learning: Theory and Algorithms](/books/reinforcement-learning-theory-and-algorithms) by Alekh Agarwal and co-authors is a free PDF that its authors update frequently. It is still in progress and has little code.

[Algorithms for Reinforcement Learning](/books/algorithms-for-reinforcement-learning) by Csaba Szepesvari is a short free PDF from 2010. It surveys the classic algorithms and predates deep reinforcement learning.

The ranking also includes [Bandit Algorithms](/books/bandit-algorithms) (88.0), a theory-first text on bandit problems and exploration with little practical code. The authors offer a free PDF, and printed copies are sold separately.

## Edge machine learning

[TinyML](/books/tinyml-book) by Pete Warden and Daniel Situnayake is the most practical guide in the ranking for running models on microcontrollers. Its free preview is partial, and the full PDF and print copy are sold separately. It has little mathematical theory.

[Efficient Processing of Deep Neural Networks](/books/efficient-processing-of-deep-neural-networks) by Vivienne Sze, Yu-Hsin Chen, Tien-Ju Yang and Joel S. Emer, published by Springer in 2020, covers trade-offs between hardware design and algorithm choices. It is paid, has no free full text, and does not cover reinforcement learning.

[Fringe Learning](/books/fringe-learning)\* is an 86-page PDF from The Knowledge Project on reinforcement learning for microcontrollers and NPUs. It is pay-what-you-want on Gumroad, and it suits readers who already know the basics of reinforcement learning.

The ranking also includes [How to Remain Valuable When Intelligence Becomes Cheap](/books/remain-valuable)\*, a career strategy book rather than a machine learning text. It scores lowest for the topic.

## A path through the list

1. If your math is weak, start with the statistical learning text, then the mathematics book.
2. For foundations, read the Goodfellow text, which is free online, next to a practical book.
3. For code, start with [Dive into Deep Learning](/books/dive-into-deep-learning), which is free, or the Chollet book, which is paid.
4. For probability and Bayesian methods, read the Murphy draft once the foundations are in place.
5. For reinforcement learning, start with Sutton and Barto, then move to Bertsekas or the Agarwal draft.
6. For edge deployment, start with [TinyML](/books/tinyml-book). Add Fringe Learning if your work is reinforcement learning on small hardware.

## Free and paid at a glance

Free to read online, according to the listings: [Deep Learning](/books/deep-learning-book), Dive into Deep Learning, the Murphy draft, [Mathematics for Machine Learning](/books/mathematics-for-machine-learning) (PDF), [An Introduction to Statistical Learning](/books/introduction-to-statistical-learning) (PDF), [Speech and Language Processing](/books/speech-and-language-processing) (draft PDF), Sutton and Barto (PDF), Bertsekas (PDF for instructional use), the Agarwal draft and the Szepesvari PDF. Paid with no free full text: [Deep Learning with Python](/books/deep-learning-with-python), Bishop's book and the Sze book. TinyML offers only a free preview.

> **Ranking:** [Best free AI and machine learning books](https://listme.name/best/ai-and-machine-learning-books/free). 6 products ranked. Top pick: Deep Learning (94.5).

| Book | Author | Level | Best for |
|---|---|---|---|
| An Introduction to Statistical Learning | Gareth James, Daniela Witten, Trevor Hastie, Robert Tibshirani, Jonathan Taylor | Beginner | Statistical learning for beginners with Python |
| Mathematics for Machine Learning | Marc Peter Deisenroth, A. Aldo Faisal, Cheng Soon Ong | Advanced | Math behind classic machine learning methods |
| Deep Learning | Ian Goodfellow, Yoshua Bengio, Aaron Courville | Advanced | Foundations of deep learning, free online |
| [Probabilistic Machine Learning](/books/probabilistic-machine-learning) | Kevin P. Murphy | Advanced | Probabilistic modeling and Bayesian methods |
| [Dive into Deep Learning](/books/dive-into-deep-learning) | Aston Zhang, Zack C. Lipton, Mu Li, Alex J. Smola | Intermediate | Hands-on deep learning with free notebooks |
| Deep Learning with Python | François Chollet, Matthew Watson | Intermediate | Practical deep learning code in Python |
| [Reinforcement Learning: An Introduction](/books/reinforcement-learning-an-introduction) | Richard S. Sutton, Andrew G. Barto | Intermediate | Standard free reinforcement learning textbook |
| [TinyML](/books/tinyml-book) | Pete Warden, Daniel Situnayake | Intermediate | Running machine learning on microcontrollers |

The free-online status above follows each book's listing. Check the license and edition before you rely on a free copy.


\* Made by, or connected to, the publisher of listme.name. Listed on the same criteria, with the lift described at https://listme.name/methodology and https://listme.name/disclosure.
