The pole of the magnet is on the end, so the magnetic force is concentrated there. However, if you bring any ferrous metal toward the magnet, even from the side, there will be some attraction.