📐 Spirit Level

Use your phone's built-in motion sensors to check if a surface is level. Lay the phone flat and read the tilt in real time.

This tool needs access to your device's motion sensors.

📱

Use Your Phone

This tool needs a device with a motion sensor (accelerometer). Open this page on your phone or tablet to use the spirit level.

📌 Embed This Tool

Add the Spirit Level to your website for free. Just copy and paste the code below.

📋 When to Use the Spirit Level

Reach for it on the quick, practical jobs where a phone is genuinely accurate enough: hanging a picture, mirror, or shelf straight; checking that a fridge, washing machine, or bookcase sits level so it doesn't wobble or vibrate; setting up a tripod, camera, or projector; or confirming a freshly mounted TV bracket isn't tilted. Because the tool lives in your pocket, it's there the moment you notice something looks off — no hunting for a level in the toolbox.

Use a physical bubble level instead when the work demands real precision — cabinetry, tiling, masonry, or anything where a fraction of a degree compounds over distance — or when the surface is longer than your phone. A 1-metre aluminium level bridges dips and bumps that a phone-sized footprint can't average out, and it won't jitter in a high-vibration spot the way a sensor readout does.

⚙️ How the Spirit Level Works

Your phone contains a three-axis MEMS accelerometer. At rest it doesn't measure motion — it measures the constant pull of gravity, split across its three axes according to how the phone is oriented. Lying flat on its back, almost all of that 1 g points straight down through the screen's axis and the side-to-side axes read near zero. Tilt the phone and gravity "spills" onto those axes; the size of the spill is a direct trigonometric measure of the tilt angle.

This tool reads those angles through the browser's DeviceOrientation API, which exposes two values: beta (front-to-back pitch) and gamma (left-to-right roll). The bubble is positioned from those two numbers — the further either angle strays from 0°, the further the bubble drifts from the centre ring, mimicking how fluid displaces in a real vial. Everything is computed locally in JavaScript; no readings leave your device.

What that means for accuracy. The sensor reports the tilt of the phone, which equals the tilt of the surface only if the phone lies perfectly flush — a camera bump, a thick case, or grit underneath will throw it off. Consumer MEMS sensors also carry a small fixed bias and a little electrical noise, so honest real-world accuracy is roughly ±0.5–1° rather than the hairline precision of a machined vial. And because of how Euler angles behave, the roll reading becomes unstable as the phone approaches vertical, so the tool is most trustworthy on near-horizontal surfaces.

How to Use the Spirit Level

  1. Open on your phone — Visit the spirit level page on a device with a motion sensor — virtually all modern smartphones and tablets have one.
  2. Enable sensors — On iOS, tap "Enable Sensors" to grant motion permission. Android and desktop browsers start automatically.
  3. Place your phone flat — Lay your phone on the surface you want to check. The bubble moves in real time.
  4. Read the result — When the bubble centers in the target ring and shows "✅ Level," your surface is perfectly flat. The readouts show exact tilt angles.

Frequently Asked Questions

Does this work on desktop?

Most desktops and laptops have no accelerometer, so there's nothing for the tool to read — a fallback message appears. It's built for phones and tablets, which all carry the necessary motion sensors.

How accurate is it compared to a real spirit level?

Be realistic about the gap. A decent physical level's vial resolves to roughly 0.03°, while a phone's accelerometer realistically lands within about ±0.5–1° once you've corrected for offset (see below). For hanging pictures and checking appliances that's more than enough; for tiling, joinery, or anything where a small error compounds over distance, use a physical level.

How do I correct for my phone's offset?

Use the 180° trick. Place the phone on the surface and note the reading; rotate it exactly 180° in the same spot and note the new one. The surface's true tilt is the average of the two, and half their difference is your phone's built-in zero-offset error. For example, +0.8° one way and −0.2° the other means the surface is really +0.3° off level, with a +0.5° bias baked into your device. This cancels out both the sensor's fixed error and any small wobble from the phone not sitting perfectly flush.

Why does the bubble drift or jitter?

Two reasons. MEMS sensors have slight electrical noise, so the last decimal wanders even when the phone is still — that's normal. Bigger jumps usually mean the phone isn't sitting flush (a camera bump or case is rocking it) or you're holding it near vertical, where the roll angle becomes mathematically unstable. Lay it screen-up on a flat spot and keep it close to horizontal for the steadiest reading.

Why does it ask for permission on iPhone?

Since iOS 13, Safari requires explicit permission before any website can read motion sensors. It's a privacy safeguard — and because all processing here is local, your motion data never leaves the device regardless.

Does my surface need to be perfectly clean and flat?

It helps a lot. The tool measures wherever the phone physically rests, so a crumb, a raised case edge, or a soft surface that compresses unevenly will all skew the result. Set the phone screen-up directly on a clean, rigid part of the surface, and avoid spanning a gap or a seam.

Related Tools