This book provides a detailed description of how Python can be used to give insight into the flow of groundwater based on analytic solutions. Starting with simple problems to illustrate the basic principles, complexity is added step by step to show how one-dimensional and two-dimensional models of one or two aquifers can be implemented. Steady and transient flow problems are discussed in confined, semi-confined, and unconfined aquifers that may include wells, rivers, and areal recharge. Special consideration is given to coastal aquifers, including the effect of tides and the simulation of interface flow. Application of Python allows for compact and readable code, and quick visualization of the solutions. Python scripts are provided to reproduce all results. The scripts are also available online so that they can be altered to meet site-specific conditions. This book is intended both as training material for the next generation of university students and as a useful resource for practitioners. A primer is included for those who are new to Python or as a refresher for existing users.