Lots of things can mess with your compass. Rocks containing significant amounts of iron, like many volcanics. I have seen needles 45 degrees off from local lava flows.

I always like to check the compass against the North Star just to be sure everything is OK.
_________________________
Geezer in Chief