Skip to content

About

Unofficial self-hosted app for heated and cooled beds (Orion Sleep, Sleepme, Eight Sleep Pod via free-sleep, BedJet, OOLER): nightly temperature rhythms, presence, Android/Wear OS, Home Assistant.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

8 stars

Watchers

0 watching

Forks

Latest commit

 

History

173 Commits

Folders and files

Repository files navigation

Ember & Tide

A calm, local-first app for heated and cooled beds. One of you sleeps cold and wants warmth (Ember), one sleeps hot (Tide), and each side follows its own temperature rhythm through the night, starting when you are actually in bed. It runs on a small server in your home and works with an Orion Sleep topper, a Sleepme Dock Pro, an Eight Sleep Pod (with free-sleep), a BedJet or an OOLER, plus a phone app, a watch, Home Assistant, a bedside dial and whatever sensors you already have. Nothing needs the cloud, and nothing updates itself.

Unofficial: an independent community project, not affiliated with or endorsed by Orion Sleep, Sleepme, Eight Sleep, BedJet, OOLER or any other maker. Their names only say which hardware it works with.

Built with AI help: most of the code is written with Claude Code (Anthropic's Claude models, currently Claude Opus 5.5), and Google's Gemini models do second-opinion reviews and some of the code. The maintainer designs it, reviews what goes in, and tests every change on a real bed, phone and watch. This covers every commit and pull request from the maintainer, so they don't repeat it. Contributors: see Using AI tools.

Found a bug, have an idea, or changed something in a fork? Please tell us. Open an issue or send a pull request, so everyone gets the fix. Questions go to Discussions. More in Contributing.

Beta testing

New here as a tester? Read TESTING.md first: safety notes, the recommended first path (the simulator, then the orion-cloud driver, no network changes), what to try this round and how to report problems.

Download: the Android app and the Wear OS app are on the latest release (which APK to pick: Download the app); the server runs from the ready-made Docker image, see Quick start below. Both can update themselves after that.

Try it in your browser first: embertide-demo.homepush.dev runs a simulated bed with two made-up sleepers. Nothing there controls a real bed, and changes reset every hour.

Works with

Bed How Ember & Tide talks to it Status
Orion Sleep topper Fully local through your own MQTT broker, or Orion's official cloud API with a personal key Used every night by the maintainer
Sleepme Dock Pro (ChiliPad) Sleepme's official developer API New: not yet tried on a real dock
Eight Sleep Pod Any Pod through the Eight Sleep Home Assistant integration (no changes to the Pod), or fully local with the community free-sleep project (Pod 3, 4 and 5) or the Eight+ Pod 3 gateway New: not yet tried on a real Pod
BedJet Home Assistant (Bluetooth through ESPHome or a community integration) New: not yet tried on a real BedJet
OOLER (ChiliPad) Home Assistant (OOLER integration, local Bluetooth) New: not yet tried on a real OOLER
Other beds in Home Assistant Any climate entity, one per side New
No bed yet The built-in simulator runs the whole app Supported, not just a test mode

Every bed gets the same app: rhythms, flashes, presence, Autopilot, sleep history, notifications and Home Assistant entities. Controls a bed can't do (lights, a water fill, heart rate from the bed) are hidden. Beds without their own in-bed sensor start the night from the presence sensors you add, or from the schedule. Setup for each bed is in Bed drivers. Have one of the new ones? Please tell us how it goes; a short report helps everyone. Another bed can be added by writing one Python class (how).

The pictures below show the simulator with two made-up sleepers, Alex and Sam.

A short tour on the phone: the Tonight screen at 63 degrees, a tap on Hot flash drops it to 55 degrees for 15 minutes, then typing too hot in Settings search finds Hot flash and jumps straight to that setting

The Tonight screen in the dark theme: Alex's side is in the Deep phase at 63 degrees, with the night's plan, the pad's temperature, and hot flash and cold flash buttons The Tonight screen in the light theme, showing the same night The Simple screen for 3 AM: one big temperature, a hot flash and a cold flash button, plus and minus

Screenshots

The rhythm editor for weeknights: bedtime, wake, pre-conditioning and phases The Sleep screen for one night: the story, sleep stages from a watch, temperature against plan, and the moments of the night
Rhythm. Bedtime, wake and phase temperatures for work nights and days off. Sleep. A night in plain words, with stages from a watch and what the bed did.
The one Settings page on the phone: a search box, group shortcuts, then You, Your nights, Notifications and Phone, watch and health First-time setup: Hi Alex, a few quick questions
Settings. One page with search, grouped, autosaved, with help on every setting. First-run setup. One decision per screen, a good answer already picked.

Studio, the power tools on a computer or tablet:

Studio Overview: both sides on one chart with the plan, live signals from the room, bed scales and radar, suggestions

Nights explorer: temperature, heart rate, sleep stages and in-bed bars for one night with every source listed Devices and calibration: watch, phone, bedside dials, radar, scales, room sensors, calendar
Nights explorer. Where every number came from. Devices. Add what you own; everything but the bed is optional.
Autopilot: mode, learning week, your normal range, right now, suggestions Insights and Ask: patterns from recent nights and questions about your sleep
Autopilot. Learns your normal, then suggests small explained changes. Insights. Patterns with one-click changes, and an optional assistant.
Notifications: where alerts go, buttons in notifications, app push, ntfy Second step of first-time setup: how do you usually sleep, Ember or Tide
Notifications. Google push, ntfy or Home Assistant, each person's choice. Setup question. Ember runs cold, Tide runs hot, or in between.

What it does

Nights and rhythms

  • A rhythm is a plan of phases (wind-down, fall asleep, deep, late night, warm wake) with temperatures, anchored to bedtime, the moment you get in bed, a clock time or your wake time. Different rhythms for work nights and days off.
  • The night starts when you are in bed on your side. Pre-conditioning waits for you; a bedtime window and a schedule fallback cover silent sensors. It copes with getting up at night.
  • Warmer or cooler for tonight (until the next phase, for the rest of the night, or every night, which edits the rhythm), pause, off tonight, start now, and turn on by hand with a timer for naps.

Flashes and quick controls

  • Hot flash and cold flash with sensible defaults (13 °C / 55 °F or 30 °C / 86 °F for 15 minutes, easing back), tunable per person.
  • A Simple screen for 3 AM: one temperature, big buttons, deep-red night colours. Optionally a Simple app for the less technical sleeper: temperature, flashes and an easy schedule, with the detail left in Studio.

Presence and sensors

  • Presence is a weighted vote of the bed's own sensor strip and anything you add: mmWave radar, bed scales, a phone charging at the bedside, a watch, room sensors. It knows about the strip's quirks (one sleeper shown on both pads, half-second false readings, a stalled clock) and sets misbehaving devices aside, with an explanation.
  • Context, not just sensors: phone at home or on the way home (pre-condition so the bed is ready), evening events and early starts from a calendar feed, bedroom lights.
  • Leak sensor safety: if a connected water leak sensor reports water, both sides switch off and stay off until someone clears it, filling and power-on are blocked meanwhile, and the household gets an urgent notification.

Autopilot and the calibration week

  • A seven-night calibration week teaches it what a normal night looks like for each person before it says anything.
  • Then it notices patterns (you tap "too warm" in the deep phase, hot flashes cluster at 3 AM, settling takes longer) and either suggests or, if you choose, acts within limits you set. Every decision shows what it saw and why. You decide how much to trust the bed, the watch and the room. An optional AI assistant (a model you run, or one you point it at) answers questions and proposes changes, never applying them without you.

Sleep history and wearables

  • A night in plain words, a Nights explorer that shows every source, sleep stages (estimated from the bed, or imported from a watch or ring), heart rate, skin temperature, and a tuning guide for bedtime and wake drift.
  • Wearables arrive from Health Connect (Android) or your own cloud account at Oura, Withings, WHOOP, Polar or Garmin, or generic webhooks and JSON pollers. Clock shifts are detected and readings from several devices are lined up.

Pets, guests and away

  • Pets on the bed are told apart from people (watch mismatch, learned heart-rate signatures) and a pet question lets you teach it. Guest mode and away keep the bed sensible when the household changes. Care reminders for the bed itself (purification tablets, water, a check of the hub and hose), with the maker's guidance as the source.

Notifications

  • Native app notifications through Google push (FCM) or UnifiedPush/ntfy with no Google at all, Web Push for the iPhone Home Screen app and browsers, ntfy topics and Home Assistant targets as fallbacks. Quiet hours, daily caps, a morning summary, one-tap actions in the notification, and a tone you pick (calm, friendly, cheeky; alerts are always plain).

Settings and updates

  • One Settings page, the same on the phone and in Studio, in seven plain groups. Search understands other words ("too hot" finds Hot flash), typos and related settings, and every page links straight to the setting it mentions.
  • Suggested for you offers the recommended settings you haven't turned on, one tap each.
  • The phone and watch apps update themselves from Settings, straight to the newest release, signed with the project's key and checked before installing. The server never updates without you.

Apps and integrations

  • Android app with a resizable home-screen widget, a Quick Settings Hot flash tile, native notifications, optional phone sources and Health Connect sync. Wear OS app, tile and complication for tonight, temperature and flashes.
  • iPhone: the web app as a Home Screen app, with notifications (iOS 16.4 or newer). A native app is planned.
  • Home Assistant over MQTT discovery: a thermostat per side, flash buttons, phase and in-bed sensors, per-phase temperatures. Voice works through Home Assistant's assistants (Siri, Google Assistant, Alexa, Assist), and through Apple Shortcuts on an iPhone (Talk to your bed).
  • ESPHome bedside dial: a rotary touch dial per side (shared package in core/embertide/dial/), also a Bluetooth beacon that helps tell the sleepers apart.
  • A simulator with scripted sleepers, a bed console, data export, and API keys for your own scripts. A demo mode runs a self-contained, resettable copy for showing it to others (Demo).
  • Phones, tablets and foldables: hinge-aware layouts, a navigation rail on big screens, a light theme that keeps text at 4.5:1 contrast.

How it works

flowchart LR
  subgraph bed[Bedroom]
    hub[Your bed<br/>Orion, Sleepme, Pod,<br/>BedJet, OOLER]
    radar[Radar, scales,<br/>room sensors]
    dial[Bedside dial<br/>ESPHome]
  end
  subgraph home[Your home server]
    broker[(MQTT broker<br/>Mosquitto)]
    srv[Ember & Tide server<br/>FastAPI + SQLite]
  end
  hub <-->|"Orion: local MQTT<br/>after a DNS record"| broker
  broker <--> srv
  hub <-.->|"other beds: their own API,<br/>free-sleep or Home Assistant"| srv
  radar --> ha[Home Assistant]
  ha <-->|MQTT discovery| srv
  dial <--> ha
  srv <-->|HTTPS or LAN| phone[Phone app<br/>widget, tile, Health Connect]
  srv <--> studio[Studio and web app]
  phone <--> watch[Wear OS app and tile]
  srv -.->|"only if you turn it on"| push[(Push: FCM, ntfy)]
  srv -.->|"only if you connect it"| cloud[(Wearable clouds:<br/>Oura, Withings, ...)]
Loading

A small driver is the only part that knows a particular bed; everything else is the same for every bed. For the Orion topper, a local DNS record makes its hub connect to your own broker instead of the maker's server. Other beds are reached through their maker's API, free-sleep on the Pod, or Home Assistant. One engine in the server owns every write to the bed, with temperature and rate limits, so every client (the app, a dial, Home Assistant, Autopilot, the assistant) goes through the same checks. Data lives in one SQLite file.

Hardware and requirements

  • Required: a machine that is always on at home with Docker, or Python 3.12. A Raspberry Pi 4, a NAS or a mini PC is plenty. And a bed from Works with, or none at all to start on the simulator.
  • For your bed: Orion, a router or DNS server where you can add one local DNS record (or a personal key for Orion's cloud API, slower and needs the internet). Sleepme, a developer token from your Sleepme account. Eight Sleep Pod, Home Assistant with the Eight Sleep integration, or free-sleep installed on it. BedJet or OOLER, Home Assistant with the bed set up. Details in Bed drivers.
  • Optional: a mmWave presence radar and a bed scale (the most reliable presence signals), room temperature and humidity sensors, Home Assistant, the bedside dial (Elecrow CrowPanel with ESP32-S3, see core/embertide/dial/, with a 3D-printable stand in hardware/dial-stand), an Android phone (app, Health Connect), a watch or ring (Pixel, Galaxy, Oura, Withings, WHOOP, Polar, Garmin through Health Connect), a Wear OS watch for the app and tile, an iPhone for the web app.

Quick start

Five steps. The install guide has the same steps with what you should see after each one, and sections for Unraid, Synology, TrueNAS, Proxmox, Raspberry Pi and Linux, Windows and Mac, Portainer, CasaOS and Home Assistant users.

  1. Pick your platform in Which way should I install?. You need an always-on computer with Docker.
  2. Get the Compose file. On a NAS (Synology, Unraid) or Windows or Mac, follow the guided steps in Which way should I install? instead of the terminal commands below. (The project folder holds it and the broker's settings; the app itself comes as a ready-made image.)
    git clone https://github.com/Ncbudd/ember-tide.git
    cd ember-tide
    cp docker-compose.example.yml docker-compose.yml     # set TZ to your time zone
  3. Start it: docker compose up -d (it pulls ghcr.io/ncbudd/ember-tide), then open http://<server-address>:8790 (details; to build the image yourself, see Advanced).
  4. Set up the app: create the owner account using the one-time setup code from the server log (docker compose logs embertide, or docker compose exec embertide python -m embertide setup-code) and follow the short setup (first-run setup). Once the owner account is created, the code is removed. It starts with the built-in simulator, so you can look around in Studio, Simulator first.
  5. Connect the bed when you are ready by setting ET_BED and a line or two for your bed in the Compose file:
    • Orion: easiest is a personal API key from docs.orionsleep.com/api-keys; fully local is one DNS record (point the bed at your server, docs/bed-cutover.md, including how to roll back).
    • Sleepme, Eight Sleep Pod, BedJet, OOLER or another bed in Home Assistant: see Bed drivers. Your people, rhythms and settings stay when you switch.

All settings are in docs/configuration.md.

Documentation

Guide
Install Step by step for Unraid, Synology, TrueNAS, Proxmox, Linux and Raspberry Pi, Windows and Mac, Portainer and CasaOS; first run, HTTPS and iPhone, Home Assistant, fixed addresses, updates and backups
Bed drivers Setting up each bed: Orion, Sleepme, Eight Sleep Pod (through Home Assistant, free-sleep or the Eight+ gateway), BedJet and OOLER through Home Assistant; writing a driver for another bed
Bed cutover Orion: the local DNS record, checking the connection, blocking the hub's internet, rolling back, firmware updates
Android Download the APK (Google push or no Google), build it yourself, your own Firebase project, Health Connect, widget and tile, Wear OS
Talk to your bed Siri, Google Assistant, Alexa and Assist through Home Assistant; Siri with Apple Shortcuts; voice on Android
Connect an AI app Ask Claude, Copilot, Cursor or any MCP app about your sleep, and let it propose small changes, through a private key per person
Demo mode A self-contained demo with a simulated household that resets every hour, safe to share
Configuration Every environment variable, the data folder, ports
Troubleshooting Hub won't connect, unknown sides, echo, push, Home Assistant, Health Connect
Notifications, Care, Cycle, Integrations, Onboarding, Settings map How the parts work
Developer handoff Architecture, layout, testing, conventions

Privacy and security

  • Local first. The server runs in your home. The bed talks to your broker, the apps talk to your server, and no account with anyone is needed. Sleep data lives in one database file in your data folder.
  • Accounts and roles. The first visit from your home network creates the owner using a one-time setup code printed on the server; setup over a tunnel or proxy is refused on purpose. Sleepers control their own side (the partner's only as far as the partner shares it); viewers can look. Scripts, Home Assistant and dials use API keys; the widget, tile and watch get their own limited device keys that sign-out revokes.
  • Bounded writes. Everyday range 12 to 35 °C, the bed's hard range 10 to 45 °C, per-side rate limits, an end time stored before any flash begins. Firmware, Wi-Fi and low-level pump and valve commands are refused.
  • What leaves the house, only if you turn it on: push messages through Google (FCM; encrypted for each phone, Google carries ciphertext) or through a ntfy server you pick; cloud wearable accounts you connect (Oura, Withings, WHOOP, Polar, Garmin); an AI model if you point the assistant at one (a local model keeps it at home). With none of these, nothing leaves.
  • Run it behind HTTPS if you reach it away from home, and keep the MQTT broker on your LAN (the bed's side has no password). See SECURITY.md.

Status and disclaimer

Early (0.x). Verified against the built-in simulator and the Orion local protocol on firmware 2.6.2. The Orion cloud driver uses Orion's official API (December 2026); reading the bed and Orion's sleep stages is checked against a real account, and changing the temperature through the cloud follows the documented examples. The Sleepme, Eight Sleep (free-sleep), BedJet, OOLER and Home Assistant drivers are built from their published APIs and tested against recorded messages, but haven't run on real hardware yet. This is an unofficial community project. It is not affiliated with, endorsed by or supported by Orion Longevity Inc., Sleepme, Eight Sleep, BedJet, OOLER or any maker of the hardware it talks to. Redirecting a bed to your own server (Orion's DNS record, free-sleep or a gateway on a Pod) is outside what the maker supports and may affect your warranty or support. Use it at your own risk, and for comfort only: it is not a medical device.

Orion firmware updates are blocked by default, for two reasons: the commands that could change a bed's firmware are not verified and could leave it unusable, and firmware changes have altered the data format before. Ember & Tide refuses those commands, and you update on your own terms by pointing the bed back at the maker's cloud for a while (how). Nothing in this project updates by itself either.

Contributing

Issues and pull requests are very welcome, small ones included: a typo, a confusing sentence, a setting that didn't make sense.

  • Something broke or looks wrong? Report a bug. Logs and what you expected help most.
  • A different bed, sensor or watch? Use the hardware support template on the same page.
  • An idea? Open a feature request. Features are agreed in the issue before work starts, so nobody's effort goes to waste.
  • Fixed or added something in your fork? Please send it back as a pull request rather than keeping it only in the fork. Read CONTRIBUTING.md first (setup, tests, style, the plain-language rule, no personal data).
  • Not sure? Ask in Discussions.

Please follow the Code of Conduct. Security issues go privately through SECURITY.md, never a public issue. Changes: CHANGELOG.md.

Credits

Built on community protocol work: tdickman's local MQTT integration for Orion, Orion's official cloud API (and borski's earlier documentation of it), firmware notes shared by the community, the free-sleep project, the Eight Sleep integration and Eight+ for the Eight Sleep Pod, and the Home Assistant integrations for BedJet and OOLER.

License

PolyForm Noncommercial 1.0.0. In plain words:

  • Free for personal and household use, and for noncommercial organisations (charities, schools, public research, hobby groups). Use it, change it, share your changes, under the same terms.
  • No commercial use. A company may not use, sell, bundle, host or ship this code or anything built from it, in a product or service, without written permission. That includes bed makers and third-party sellers.
  • Shared copies must keep the license and this notice: Required Notice: Copyright (c) 2026 Ncbudd (https://github.com/Ncbudd/ember-tide).

This makes Ember & Tide source-available, not "open source" in the OSI sense. For a commercial licence, open an issue to get in touch.

About

Unofficial self-hosted app for heated and cooled beds (Orion Sleep, Sleepme, Eight Sleep Pod via free-sleep, BedJet, OOLER): nightly temperature rhythms, presence, Android/Wear OS, Home Assistant.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

8 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages