Compass and level
Your phone as a compass — magnetic or true north, with the declination worked out for where you are by the World Magnetic Model — and a spirit level: a bullseye for flat surfaces, a tube for edges, two-sided calibration, a target angle that beeps, and the slope in degrees, percent, inches per foot and mm per metre.
Added
How to use it
The page reads your phone’s orientation and motion sensors. On iPhone and iPad tap Enable sensors and allow motion and orientation access (Safari asks every time the page is loaded); on Android they start by themselves. Keep screen awake stops the screen dimming while you work. A laptop or desktop has no compass or level sensor: the page says so, and Demo mode replaces the sensors with sliders so you can still try everything.
Compass
The big number is the direction the top of the phone points when it lies flat, or the back camera points when you hold it upright, with its 16-point name (N, NNE, NE…). The dial turns so north on the card points north.
-
Magnetic or true north — a compass points to magnetic north, which is east or west of true (map) north by the declination. From location works it out on the phone with the World Magnetic Model (WMM2025, valid 2025–2030, the model NOAA and the British Geological Survey publish): tap Use my location or type a latitude and longitude. Or choose Type it and enter it yourself (
15.2 E,3.5 W,-3.5) — NOAA’s declination calculator gives it for any place. The dial marks the other north in green. -
Hold a bearing — Lock current bearing keeps the direction you face now (or type one and tap Hold this bearing). A blue mark shows it on the dial, and the line under the reading says which way to turn and by how much.
-
Smoothing averages readings as directions — 359° and 1° average to 0°, not 180° — so the dial is steadier; turn it down for a quicker response.
Accuracy. iPhones report how good the heading is (±°); if it is poor, or the heading looks wrong on any phone, move the phone through a slow figure-8 a few times to recalibrate it. Keep away from steel, magnets, speakers, laptops and car dashboards — and phone cases or wallets with magnetic clasps or MagSafe rings, which can pull the reading tens of degrees.
Level
-
Surface — lay the phone flat. The bubble goes to the high side; the rings are 1°, 2° and 5°, and the edge of the vial is 10°. The big number is the total tilt; pitch (top high is positive) and roll (right side high is positive) are shown too.
-
Edge — stand the phone on one of its edges against the thing you are checking (a shelf, a door frame, a saw blade). The tube shows the angle of that edge from level. It works on any of the four edges and says which one is down; if the phone leans out of upright it warns you.
Every reading is shown in degrees, percent slope, rise in inches per foot (with the nearest 1/16″), millimetres per metre, and 1 in N.
Calibrate. Phones are rarely exactly square to their own sensor, and cases and camera bumps add more. Two-sided calibration removes it without needing a known-level surface: put the phone down and tap Record, turn it 180° on the same spot (flat: top where the bottom was; edge: end for end, the same edge down) and tap Record again. The offset is the average of the two readings and is subtracted from now on; the toast also tells you how far off level that spot really was. Zero here simply treats the current position as level. Calibration is kept per mode on this phone.
Target angle. Set an angle (or type a slope such as 2%; ¼″/ft is a common drain fall) and
a tolerance, and the reading turns green — with a beep and a short vibration — when you are
within it. In edge mode an angle counts from either edge, so 30° also finds 60°. Hold freezes
the display so you can take the phone away and read it. ⛶ Big fills the screen with a
high-contrast readout.
Smoothing steadies the reading; turn it down for a quicker response.
Limits
-
A phone compass is good to a few degrees at best, and only away from magnetic interference. Near the magnetic poles it is unreliable.
-
On iPhone the heading comes from iOS (
webkitCompassHeading); on Android from the absolute orientation sensor. Browsers that only give relative rotation cannot show a real heading — the page says so. -
The level is good to about 0.1–0.2° after calibration, depending on the phone. Calibrate on the surface you are measuring, with the phone’s case on or off as you will use it.
-
Vibration needs Android (iPhones ignore it); the beep needs one tap on the page first.
-
The declination model covers 2025–2030 and does not include local anomalies (ore bodies, buildings), which can add a degree or more.
Sharing
Share link copies a URL with your settings — magnetic or true north, a typed declination, the
held bearing, the level mode, target and tolerance — but never your location or calibration.
?tab=level opens the level and ?demo=1 starts the demo. By hand: ?bearing=45 holds a
bearing; ?mode=edge&target=45&tol=0.5 sets up the level.
For example: compass-level/?tab=level&mode=edge&target=45.
Feedback is a gift. Something to improve, a feature to add, or a bug? Tell me.
Runs entirely in your browser; nothing you type leaves this page.