How accurate is a browser compass?
On a recent Android phone in open space, expect ±2-5° accuracy after a figure-8 calibration. Indoors near steel framing, electrical wiring, or laptops, error can grow to ±30° or worse. iOS is generally tighter because Apple fuses gyro + accel + mag into a single 'webkitCompassHeading' value. The browser exposes whatever the OS computes — we don't re-process the raw magnetometer.
How do I calibrate the compass?
Wave the phone in a figure-8 pattern for 5-10 seconds away from metal and electronics. Most modern Android phones do this transparently; older ones surface a 'calibrate' notification. iOS recalibrates automatically when it detects drift. If the needle is clearly wrong (off by 45° or more), move outside, away from buildings and cars, and repeat the figure-8.
Why does iOS use a different heading value?
Apple exposes `webkitCompassHeading` (0 = North, increasing clockwise), already corrected for true magnetic north as known by the OS. Android exposes raw `alpha` (0 = device's initial orientation, increasing counterclockwise) unless the page reads `DeviceOrientationEvent.absolute === true`. We detect platform and use the right field — but it's why the same code on the two OSes can disagree without care.
What is magnetic interference?
Anything ferrous (steel, iron) or anything carrying current (USB cable, monitor, motor) creates a local magnetic field that overwhelms the Earth's. Common offenders: laptop hinges, car dashboards, refrigerators, speakers, MagSafe cases. We flag sudden jumps over 30° between samples as likely interference — move the phone and the warning should clear.
Can I use this for hiking or navigation?
For casual orientation — 'roughly which way is south?' — yes. For serious hiking, marine navigation, or anything where being off by 10° matters over a kilometre, use a dedicated compass app with map declination correction, or a real magnetic compass. Our tool shows magnetic north, not true north — the difference (declination) ranges from 0° in parts of central Europe to 20°+ in northern Canada or Alaska.
Why does the heading not update on desktop?
Laptops and desktops almost never have a magnetometer. The DeviceOrientation event may fire (some 2-in-1s expose accelerometer-derived tilt) but the alpha value will be missing or stuck at 0. This tool is a phone tool — open it on a phone over HTTPS, and on iOS tap Enable to grant permission.