Walk into any discussion about sleep tracking and the conversation starts with hardware: which watch, which ring, which headband. The assumption is that you need something strapped to your body to know how you slept.
You don't. The phone already sitting on your nightstand carries an accelerometer, a microphone, an ambient light sensor, and a clock — the same basic instruments sleep researchers used in early actigraphy studies, just miniaturized. In 2026, on-device processing is fast enough to turn those raw signals into a genuinely useful picture of your night. Here's how it works, what it can and can't tell you, and how to set it up well.
What your phone is actually measuring
Sleep tracking without a wearable is an exercise in inference. Your phone can't feel your pulse, so it watches for the conditions of sleep instead:
- Motion (accelerometer). When you're awake you move — you shift, reach for the phone, turn over with purpose. In sleep, movement drops to brief, small adjustments. Long stretches of near-stillness are the strongest signal your phone has that you're asleep.
- Sound (microphone). The mic listens for patterns, not conversations. Steady quiet suggests sleep; rustling sheets and shifting suggest restlessness; a 6 a.m. alarm followed by movement suggests the night is over. Good implementations process audio into anonymous sound-level features on the device rather than keeping recordings.
- Light and screen state. A dark room plus a screen that stays off for hours is supporting evidence. A 3 a.m. screen-on event is a pretty reliable "awake" marker.
- Time and routine. Your phone learns your patterns. If you're still every night between roughly 11 p.m. and 6:30 a.m., it gets better at recognizing the edges of your sleep window.
None of these signals is decisive alone. Together, they triangulate: still + quiet + dark + your usual hours = asleep, with reasonable confidence. Movement clusters in the middle of that window = restlessness. A hard stop to the stillness = wake time.
The honest limits
Let's be clear about what phone-only tracking cannot do, because this is where marketing usually gets ahead of physics:
- No heart rate, no HRV, no blood oxygen. Those need optical sensors pressed against skin. Your phone doesn't have them.
- No true sleep staging. Wearables estimate REM, light, and deep sleep from heart-rate variability and movement. A phone can approximate restlessness, but it cannot reliably tell REM from light sleep. Any app that claims clinical-grade staging from a phone alone is overselling.
- Partner and pet noise. If someone (or something) else moves the mattress or makes noise, the sensors pick that up too. It's a known limitation of any non-worn tracker.
What you do get is the stuff that actually drives most sleep decisions: consistent bedtimes and wake times, total time in bed versus estimated sleep, how broken the night was, and trends over weeks. For most people trying to fix an irregular schedule, that is the actionable layer.
Where HealthKit and Health Connect fit in
You don't have to choose one system. On iPhone, HealthKit already maintains a sleep analysis record; on Android, Google Health Connect does the same. These are on-device health stores that apps can read from and write to with your permission.
A well-built sleep app does both: it runs its own sensing, and it syncs the results into HealthKit or Health Connect so your sleep windows show up alongside everything else — workouts, step counts, and data from any wearable you might add later. Going the other direction, if you do wear a watch some nights, the app can read that data in and you get the best of both worlds. Your health data stays in the OS-level store on your phone either way.
The on-device AI part
Raw sensor data becomes useful when something interprets it. The newer approach — the one OpenSleep takes — is to run a small language model directly on the phone (we use Gemma 4) as a sleep coach that reads your locally stored sleep history.
The difference from a cloud chatbot is architectural, not cosmetic. Your weeks of bedtimes, wake times, and restlessness scores never leave the device, because there is no server to send them to. The model sees your patterns — the late Sundays, the 3 a.m. wake-ups on work nights — and can talk through them with you, suggest experiments, and notice when a trend changes. And because the code is open source, the "trust us, it's private" claim is checkable rather than a slogan.
To be realistic about the AI's role: it's a coach and a pattern-spotter, not a clinician. It can help you notice that you sleep worse on nights you work late, and it can help you design a wind-down routine you'll actually follow. It cannot diagnose anything, and it shouldn't try.
Setting it up well
Phone-based tracking is more sensitive to setup than a wearable, because the sensors aren't attached to you. A few things that genuinely help:
- Pick a spot and keep it. Mattress placement (near your pillow, face-down) captures movement best. Nightstand placement captures sound well and keeps the phone charging. Either works — consistency matters more than the choice, because your trends are only comparable if the setup is stable.
- Charge overnight. This removes battery anxiety entirely and keeps the phone in one place. A long cable helps if your outlet is far from the bed.
- Keep a regular schedule for a week first. The algorithms calibrate against your routine. Two weeks of consistent bedtimes will do more for accuracy than any settings tweak.
- Note the confounders. New mattress, a partner traveling, a pet joining the bed — these change the sensor picture. If your data looks odd for a few nights, check what changed in the room before concluding your sleep changed.
- Use the OS sleep schedule too. Set the bedtime schedule in iOS or Android. It won't track anything by itself, but it gives the tracking a prior to work with and silences notifications.
What to actually do with the data
The most common failure mode of sleep tracking isn't inaccuracy — it's collecting data you never act on. Keep it simple:
- Watch the edges, not the middle. Bedtime consistency and wake-time consistency predict how rested people feel far better than any single night's "score." If your bedtime drifts by two hours across the week, that's the thing to fix.
- Compare weeks, not nights. One bad night is noise. Three weeks trending later is a signal.
- Run one experiment at a time. Screens off 30 minutes earlier for two weeks, then look at the trend. The tracker is the measuring instrument for your own experiments.
- Treat restlessness as a prompt, not a verdict. A restless patch might be a warm room, late caffeine, or stress. The data tells you when; you supply the why.
And the boundary that matters: if you consistently feel exhausted despite reasonable hours, snore loudly, or gasp awake, that's a conversation for a clinician, not an app. Sleep trackers are wellness instruments. Sleep disorders are medical territory.
Why on-device matters for sleep data
Sleep data is intimate in a way step counts aren't. It reveals when you're home, when you're vulnerable, and over time, patterns about your mental health and routines. Routing that through a cloud account — subject to breaches, subpoenas, acquisitions, and "anonymized" analytics that often isn't — is a strange trade for a slightly nicer chart.
On-device processing flips the default: the data never leaves, so there's nothing to leak. It also works in airplane mode, on a plane, or anywhere else without connectivity — which, fittingly, includes the hours you're supposed to be asleep.
The bottom line
You don't need to buy hardware to start understanding your sleep. Your phone's motion and sound sensors, combined with HealthKit or Health Connect and an on-device AI coach, can map your sleep windows, surface your trends, and help you run the small experiments that actually move the needle — all without an account, a subscription, or a cloud.
Start with one week of consistent placement and schedule. Look at the trends, not the nights. And keep the phone charged — it's doing its best work while you're doing nothing at all.
OpenSleep is a free, open-source sleep tracker for Android and iOS. Everything runs on your device: sensor-based sleep tracking, HealthKit and Google Health Connect sync, and an offline Gemma 4 AI sleep coach. No accounts, no cloud, no trackers.

