Provided are an apparatus and a method for canceling magnetic fields. The apparatus includes a magnetic field canceling coil disposed adjacent to an inner wall of a magnetic shield room to surround the entire inner space or a portion of an inner space of the magnetic shield room and a magnetic field canceling coil driver to supply current to the magnetic field canceling coil. The magnetic field canceling coil cancels a prepolarization magnetic field established on the wall of the magnetic shield room by a prepolarization coil disposed in the center of the magnetic shield room to minimize magnetic interference caused by the magnetic shield room.