Home Assistant can already tell whether someone is home, in a room, or moving around. What it usually cannot tell is whether that person has actually fallen asleep.
One of our beta testers recently connected a Sleepal AI Lamp to Home Assistant through Matter. The interesting part is not really the lamp. It is getting sleep state and in-bed state as automation triggers.
That solves an awkward problem: you cannot exactly tell Home Assistant that you are asleep once you have fallen asleep. ![]()
Disclosure: I’m part of the Sleepal team. The beta unit was provided by us, and the setup and automation examples below come from a tester’s own write-up, shared with permission.
Links: Sleepal AI Lamp on Kickstarter, Public PSG validation preprint
First, what is the Sleepal AI Lamp?
Sleepal is a contactless sleep system that sits on the bedside table. There is nothing to wear, no sensor pad to install, and nothing on your body that needs charging every day. Setup is basically: plug it in, place it beside the bed, and finish setup in the app.
It works as a sleep tracker, a bedside light & alarm & speaker, sleep-sound machine, and a smart home sensor.
The sensing stack combines 60 GHz millimeter-wave radar, a thermal sensor array, acoustic sensing, and environmental sensors. It tracks sleep/wake state, movement, breathing, posture, snoring, temperature, humidity, light, and room noise. There is no optical camera or photo/video recording.
Accuracy comes first
For home automation, accuracy is the foundation. A sleep trigger is not useful if it changes at the wrong time.
A public preprint compares Sleepal with expert-scored polysomnography, or PSG, using 1,022 synchronized overnight recordings, including data collected in clinical sleep centers. It reports 92.8% accuracy for binary sleep/wake classification. That is the result most relevant to these HA automations.
To be precise, this is a public preprint rather than a peer-reviewed journal paper. In daily use, the tester said the results felt roughly comparable to his Apple Watch, while adding sleep-posture and bedroom-environment data.
Sleepal was also named a CES 2026 Innovation Awards Honoree in three categories: Smart Home, Digital Health, and Accessibility & Longevity.
Connecting it to Home Assistant
The current Matter pairing path in the app is:
- Sleepal App > Me > My Sleepal > Matter
Enable pairing, then add it through the Home Assistant Companion app.
The beta currently exposes:
- One
lightentity with brightness and color-temperature control. RGB is not exposed yet. binary_sensorentities for sleep, in-bed, nighttime wake, sleep-aid, alarm, and snooze states.sensorentities for temperature, humidity, and illuminance.- A few reserved entities that are not defined yet.
The sleep and in-bed states used by Matter are calculated on the device and communicated locally. Once commissioned, these HA automations do not need an Internet connection or cloud round trip. Deeper app analysis is separate and may use cloud services. The Matter functionality shown here does not require a subscription.
The integration is still beta. Entity names are not final, RGB control is missing, and the vendor/device fields currently show TEST.
Why sleep state is such a useful trigger
Presence and motion sensors cannot distinguish lying in bed reading from lying awake with insomnia or actually sleeping. Here is how the tester described the problem:
My bedroom already had automations for sleep music, dim lighting, climate devices, cameras, curtains, and morning scenes. Some used buttons or schedules, but stopping sleep music after I had actually fallen asleep was difficult. I could not exactly tell HA I was asleep while I was asleep. >_<!
After falling asleep: stop sleep music and turn off the lights
I used to have a countdown to gradually lower the HomePod volume and bedroom lights. Sometimes it stopped before I fell asleep; other times it continued long enough to wake me again. Now, the sleep sensor reacts to actual sleep instead of a timer’s guess.
After falling asleep: enable cameras
My IPC cameras outside the bedroom now enter home-watch mode after I fall asleep. When I wake during the night or get up in the morning, they switch off again, so they do not record me wandering around half asleep and looking disheveled.
After getting up: stop bedroom devices and start morning lighting
My fresh-air system, humidifier, and AC used fixed shutoff timers. Now they react to my actual out-of-bed state. If the morning is overcast, HA also turns on the dining-room spotlights. Their brightness follows
sensor.sun_solar_azimuth, so the apparent direction of the light follows the real sun. A new day deserves a bright start!
Script note: I have four spotlights, one in each corner of my dining room, all aimed at the ceiling. Their brightness is adjusted independently based on the sun’s azimuth (
sensor.sun_solar_azimuth), so the indoor lighting follows the direction of the real sun and creates a more natural morning wake-up effect.variables: solar_azimuth: "{{ states('sensor.sun_solar_azimuth') | int}}" is_evening: >- {{ ( solar_azimuth >= 0 and solar_azimuth < 90 ) or ( solar_azimuth > 270 and solar_azimuth < 360 )}} light_1_brightness: "{{ ((solar_azimuth - 270)/180) | abs if is_evening else 0 }}" light_2_brightness: "{{ (1 - light_1_brightness) | abs if is_evening else 0 }}" light_3_brightness: "{{ 0 if is_evening else ((solar_azimuth - 90) / 180) | abs}}" light_4_brightness: "{{ 0 if is_evening else (1 - light_3_brightness) | abs }}"
More possibilities
A few ideas still on the tester’s list:
- Adjust AC temperature or fan speed based on time asleep, using the temperature and humidity readings beside the bed.
- Turn on a dim bathroom path light after a nighttime out-of-bed event, then reset it after the person returns to bed.
The Matter integration still needs cleanup, and I do not want to promise extra entities before they are ready. Heart rate, respiratory rate, and sleep scores are not currently confirmed as exposed HA entities.
Final Thoughts
Even in this early state, sleep and in-bed sensors answer a question that ordinary presence sensors cannot:
- Is someone here? becomes Are they actually asleep?
The Kickstarter campaign is currently live for anyone who wants the full product details. I’ll keep this thread focused on the Home Assistant and Matter side, and I’m happy to answer technical questions about the beta.
What would you automate with a reliable sleep/wake trigger, and which additional local entities would you most like to see exposed through Matter?











