How scientists through the ages have conducted thought experiments using imaginary entities—demons—to test the laws of nature and push the frontiers of what is possible Science may be known for banishing the demons of superstition from the modern world. Yet just as the demon-haunted world was being exorcized by the enlightening power of reason, a new kind of demon mischievously materialized in the scientific imagination itself. Scientists began to employ hypothetical beings to perform certain roles in thought experiments—experiments that can only be done in the imagination—and these impish assistants helped scientists achieve major breakthroughs that pushed forward the frontiers of science and technology. Spanning four centuries of discovery—from René Descartes, whose demon could hijack sensorial reality, to James Clerk Maxwell, whose molecular-sized demon deftly broke the second law of thermodynamics, to Darwin, Einstein, Feynman, and beyond—Jimena Canales tells a shadow history of science and the demons that bedevil it. She reveals how the greatest scientific thinkers used demons to explore problems, test the limits of what is possible, and better understand nature. Their imaginary familiars helped unlock the secrets of entropy, heredity, relativity, quantum mechanics, and other scientific wonders—and continue to inspire breakthroughs in the realms of computer science, artificial intelligence, and economics today. The world may no longer be haunted as it once was, but the demons of the scientific imagination are alive and well, continuing to play a vital role in scientists' efforts to explore the unknown and make the impossible real.