The Earth acts as though it contains a magnet, due to the circular currents inside its core. Also, the Earth produces a magnetic field, with the field lines being most concentrated at the poles.
If Earth had a big bar magnet, the south pole of the magnet would be near the geographic north and the north pole of the magnet will be near the geographic south.
Earth’s magnetic field is useful for navigation. A compass, for example, contains a dial to show direction and a magnetic needle to help with pivoting.
Opposite poles attract; therefore, the north pole of the compass is attracted to Earth’s magnetic South pole. Earth’s magnetic south pole is near its geographic North pole. This means that the north pole of a magnetic compass will always point towards Earth’s geographic north pole.