Tuberculosis is an ancient human disease, estimated to have originated and evolved over thousands of years alongside modern human populations. Despite considerable advances in disease control, tuberculosis remains one of the world’s deadliest communicable diseases with 10 million incident cases and 1·8 million deaths in 2015 alone based on the annual WHO report, due to inadequate health service resources in less-developed regions of the world, and exacerbated by the HIV/AIDS pandemic and emergence of multidrug-resistant strains of Mycobacterium tuberculosis. Recent findings from studies of tuberculosis infection and of patients with Mendelian predisposition to severe tuberculosis have started to reveal human loci influencing tuberculosis outcomes. In this Review, we assess the current understanding of the contribution of host genetics to disease susceptibility and to drug treatment. Despite remarkable progress in technology, only a few associated genetic variants have so far been identified, strongly indicating the need for larger global studies that investigate both common and under-represented rare variants to develop new approaches to combat the disease. Pharmacogenomic discoveries are also likely to lead to more efficient drug design and development, and ultimately safer and more effective therapies for tuberculosis.