A magnet is an object or material that produces a magnetic field and attracts certain metals, especially iron, nickel, cobalt, and some of their alloys. Magnets are fundamental to physics, geology, engineering, electronics, medicine, and everyday technology. From the compass needles used by ancient navigators to the superconducting magnets inside MRI scanners and particle accelerators, magnets have shaped scientific discovery and modern civilization.