William Gilbert was the first person who studied the movement of compass needles and correctly concluded that Earth was a magnetic planet with its magnetic poles corresponding to its geographic North and South Poles. He published a book titled "De Magnete, Magneticisque Corporibus, et de Magno Magnete Tellure" which compiled all known information about magnetism based on his work and the work of scientists before him.
William Gilbert disproved several theories on how compass needles were thought to work. One theory suggested that the needle pointed towards the pole star. Another theory suggested that the mountains in the Arctic region were magnetic and attracted the compass needle.
Gilbert correctly concluded that Earth must have an iron core which generates a magnetic field around the entire planet. He postulated that Earth's magnetic poles corresponded to its geographic poles, which was why compass needles pointed to Earth's North Pole. He showed that it was possible to create magnets from metals by rubbing a magnet against them. He studied the factors that affected the strength of magnets and observed that magnetic field strength weakened when the magnets were heated to high temperatures.
Gilbert published "De Magnete" which summarized not just his findings on magnetism, but also the findings of scientists before him. For 200 years after its publication, his book was considered to be the most important treatise on magnetism. He was the first person to use several terms that are still in common use in the modern scientific community, such as, "magnetic pole," "electric attraction" and "electric force."