Skip to content
Projects

osahum/nest-secure-resurrection

View on GitHub

About

Self-hosted OpenWeave local server, native Android & iOS apps, and Apple HomeKit bridge to revive stock Nest Guard, Nest Detect & Nest Tag hardware with zero firmware modification.

Web & App Development

How these counts are measured

7 stars1 Forks +1 in 24h

What you can do

  • 100% Stock Firmware — works with unmodified Nest Guard, Nest Detect, and Nest Tag hardware.
  • 1-Command Easy Setup & Pre-Built Multi-Arch Docker Image — curl ... | sudo bash (or sudo ./install.sh) pulls ghcr.io/osahum/nest-secure-resurrection:latest (amd64 + Raspberry Pi arm64), auto-configures ufw / firewalld LAN rules, optionally enables Apple HomeKit, and prints a scannable terminal QR code to open the Setup Portal on your phone.
  • Chrome / Edge Web Bluetooth inside Step 1 of the browser wizard,
  • Native Android app (Put factory-reset Guard on Wi-Fi), or

Measured star growth

in 24h
+1
in 7 days
Collecting history
in 15 days
Collecting history
in 1 month
Collecting history

Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.

README.md

Original

Nest Secure Resurrection

Self-hosted local server + guided browser setup wizard + native Android & iOS apps + local Apple HomeKit bridge that brings retired Nest Guard, Nest Detect, and Nest Tag hardware back to life — completely locally, with zero cloud dependency and zero firmware modification.

[!CAUTION] NO WARRANTY · NO SUPPORT · USE AT YOUR OWN RISK

This is an unofficial, experimental hobby project provided strictly "AS IS" with NO support whatsoever and NO responsibility or liability for your hardware, network, property, or personal safety. It is not a certified alarm or life-safety system, and is not affiliated with or endorsed by Google LLC or Nest Labs. Read DISCLAIMER.md in full before proceeding.


Quick Start (Recommended — 1 Command + Guided Browser Wizard)

You do not need extra LAN IPs, manual Node/Fabric ID lookups, or terminal pairing scripts. Run one command on your Linux home server (Raspberry Pi, mini-PC, old laptop, or Linux VM):

curl -fsSL https://raw.githubusercontent.com/osahum/nest-secure-resurrection/main/install.sh | sudo bash

(Or clone first if you prefer to inspect the script before running it:)

git clone https://github.com/osahum/nest-secure-resurrection.git
cd nest-secure-resurrection
sudo ./install.sh

What happens next:

  1. install.sh handles the server automatically: checks/installs Docker, pulls the pre-built multi-arch image (ghcr.io/osahum/nest-secure-resurrection:latest for amd64 and Raspberry Pi arm64), optionally enables the Apple HomeKit Bridge (docker-compose.homekit.yml), offers to open the required LAN ports in ufw / firewalld, starts the stack, and prints a link + scannable terminal QR code for the Setup Portal.
  2. Finish everything in the Guided 4-Step Browser Wizard (from any computer or phone on your Wi-Fi):
    • Step 1 — Find & Pair Nest Guard: Auto-discovers your Guard on the LAN, reads its Node ID & Fabric ID, and pairs it using its 6-character Entry Key. Factory-reset Guard pulsing blue? Click "My Guard is pulsing blue (not on Wi-Fi yet)" to put it onto your home Wi-Fi directly over Chrome/Edge Web Bluetooth (or use the native Bluetooth Wi-Fi Setup inside the Android or iOS app — zero terminal needed!).
    • Step 2 — Passcode & Timezone: Auto-detects your browser's timezone with 1-click Save and lets you set your 4–8 digit keypad Master Passcode.
    • Step 3 — Add Nest Detect Sensors (Optional): Pair Door, Window, and Wall sensors right from the browser.
    • Step 4 — Connect Your Phone & Apple Home: Scan the 1-Scan App Pairing QR from the Android or iOS app — and scan the Apple HomeKit QR / 8-digit code straight into Apple Home!

Full walkthrough: docs/EASY_SETUP.md

Prefer the Classic install or a Direct Cloud VPS?

  • Classic Linux install (sudo ./server/setup.sh, 3 static LAN IPs + systemd): Still fully supported — see docs/SETUP.md.
  • Direct Cloud VPS (zero home server hardware, ~$3–$5/mo): Nest Guard connects outbound to your VPS over the internet — see docs/REMOTE_ACCESS.md.

Download v1.1.1 Releases

[!NOTE] iPhone sideloading heads-up: Unlike Android APKs, Apple requires sideloaded .ipa apps to be signed with an Apple ID (free works), trusted in Settings → General → VPN & Device Management, have Developer Mode enabled (Settings → Privacy & Security → Developer Mode, requires a quick reboot), and re-signed every 7 days on free Apple IDs (automated by SideStore / Sideloadly Wi-Fi refresh). If you'd rather avoid sideloading altogether, enable the built-in Apple HomeKit Bridge right inside install.sh (or see docs/IOS_AND_HOMEKIT.md)!


Screenshots

Guided Browser Setup Wizard & Live Dashboard

Step 1: Find & Pair Guard (+ Web Bluetooth) Step 2: Auto-Timezone & Master Passcode
Setup Wizard Step 1 Setup Wizard Step 2
Step 4: Phone App QR & Apple HomeKit Completed Live Home Dashboard
Setup Wizard Phone QR & HomeKit Live Home Dashboard

Native iOS App & Apple HomeKit

iOS Home & Guarding iOS 1-Scan QR & Bluetooth Wi-Fi Setup iOS Apple HomeKit Bridge
iOS Home Light iOS Setup QR & BLE iOS Apple HomeKit

Native Android App

Home & Guarding (Light) Away & Guarding (Dark) Nest Guard Device
Home Light Home Dark Guard Device
Nest Detect Sensor Disarm Passcode Sheet Settings & Device Management
Detect Sensor Disarm Keypad Settings

How It Works (Not a Hack — 100% Stock Firmware)

This project does NOT jailbreak, root, flash, or alter the firmware of Nest Guard or Nest Detect. Your devices stay on their original, untouched stock firmware.

Here is why that is possible:

  1. Nest Guard and Nest Detect were built on OpenWeave, Nest's open-source IoT protocol stack (the direct predecessor to Matter), published by Google under Apache-2.0 at openweave/openweave-core.
  2. During normal setup, Nest Guard accepts a signed Service Config (telling it which Directory, Pairing, and Tunnel endpoints to talk to) over an authenticated PASE session using the 6-character Entry Key printed on the bottom of your own device.
  3. This project simply runs a private, self-hosted OpenWeave server stack on your own home Linux server:
    • Owner Directory (TCP/UDP 11096 in Easy Setup Compose, or 11095 on a dedicated LAN IP in Classic mode) — tells Nest Guard where your local Pairing and Tunnel/Gateway services live.
    • Owner Pairing (TCP/UDP 11097, or 11095 on a dedicated LAN IP in Classic mode) — authenticates your Nest Guard's factory device certificate and commits your local account binding to SQLite.
    • Owner Gateway / WDM Engine (TCP/UDP 11095 + IPv6 Weave Tunnel) — maintains a persistent encrypted tunnel with Nest Guard and your Thread-connected Nest Detects, handles real-time WDM (Weave Data Management) state subscriptions, arm/disarm commands, passcode/NFC Tag sync, and sensor settings.
    • Local REST + SSE API & Guided Setup Portal (HTTP :8420, Bearer-token authenticated) — bridges your local OpenWeave state to the Guided Browser Wizard, Android & iOS apps, local Apple HomeKit (Apple Home) bridge (:51826), and optional Google Home bridge.
    • Native Android & iOS Apps (Kotlin + Jetpack Compose / Swift + SwiftUI) — connect to your home server over LAN or your own remote tunnel for live control, built-in Bluetooth Wi-Fi setup for factory-reset Guards, instant alarm alerts via SSE, sensor management, user passcodes & schedules, Nest Tag NFC scanning, Apple HomeKit QR pairing, and event history.
[Nest Detect (Thread)] ──▶ [Nest Guard (Stock Firmware, Wi-Fi)]
                                    │
                  Standard OpenWeave PASE / CASE / WDM Tunnel
                                    ▼
             [Your Home Linux Server (same LAN as Nest Guard)]
             └── Docker Compose (install.sh / ghcr.io image):
                 ├── directory + pairing (OpenWeave)
                 └── app: Gateway + REST/SSE API + Guided Setup Wizard (:8420)
                          + Optional Apple HomeKit Bridge (docker-compose.homekit.yml, :51826)
                                    │
                  Your Choice of Secure Remote Access
             (Tailscale VPN / Cloudflare Tunnel / Reverse Proxy / VPS)
                                    ▼
             [Android App · iOS App · Apple Home (HomeKit)]

Features

  • 100% Stock Firmware — works with unmodified Nest Guard, Nest Detect, and Nest Tag hardware.
  • 1-Command Easy Setup & Pre-Built Multi-Arch Docker Image — curl ... | sudo bash (or sudo ./install.sh) pulls ghcr.io/osahum/nest-secure-resurrection:latest (amd64 + Raspberry Pi arm64), auto-configures ufw / firewalld LAN rules, optionally enables Apple HomeKit, and prints a scannable terminal QR code to open the Setup Portal on your phone.
  • Guided 4-Step Browser Wizard & Live Home Dashboard — discovers your Nest Guard on the LAN, reads its Node & Fabric IDs automatically, auto-detects your timezone, creates your Master Passcode, pairs Nest Detect sensors, generates 1-scan Phone & HomeKit QR codes, and includes a Troubleshooting & Diagnostics Drawer with sanitized live logs (no SSH or docker compose logs needed).
  • Zero-Terminal Bluetooth Wi-Fi Setup (Factory-Reset Guard) — put a pulsing-blue, factory-reset Nest Guard onto your home Wi-Fi directly from:
    1. Chrome / Edge Web Bluetooth inside Step 1 of the browser wizard,
    2. Native Android app (Put factory-reset Guard on Wi-Fi), or
    3. Native iOS app (Put Guard on Wi-Fi (Bluetooth)) — plus guard_ble_provision.py CLI fallback.
  • Apple HomeKit Bridge in Docker Compose & Classic — 100% local HAP bridge (docker-compose.homekit.yml or Classic systemd) exposing Nest Guard and every Nest Detect natively in Apple Home, Siri, Apple Watch, and HomeKit automations — zero sideloading required! See docs/IOS_AND_HOMEKIT.md.
  • Full Alarm Control — Off / Home & Guarding / Away & Guarding, entry/exit countdowns, silent/siren alerts, tamper alerts, AC power loss & backup battery status, and on-device Glass Break detection (runs locally on Nest Guard's microphone).
  • Nest Detect Support — Door, Window, and Wall placement, live open/close & motion status, Pathlight brightness, Open Chime, Quiet Open, sensor test mode, and per-mode arming rules.
  • CR123A Battery Degradation Detection — decodes Nest Detect's internal BatteryAlgoLogTrait (0x235a0240) voltage and internal resistance (ESR) telemetry to catch aging high-resistance cells (which can cause phantom motion triggers) before Nest's own low-battery threshold fires, and clears stale readings automatically upon battery swap.
  • Multi-User Passcodes & Schedules — create/edit keypad PINs and active time schedules synced directly to Nest Guard.
  • Nest Tag (NFC) Enrollment — tap physical Nest Tags directly to your Android phone's NFC reader to enroll and assign them to users.
  • Live Activity Timeline — SQLite-backed event history with category & device filters.

Known Limitation: Built-In Google Assistant Did NOT Work

Many people remember that Nest Guard also had a built-in Google Assistant speaker/microphone. That feature does NOT work in this project and cannot be redirected locally without modifying Guard's firmware.

Here is why we could revive the security system cleanly, but hit a hard wall on Guard's onboard Google Assistant (nlassistant / libassistant.so):

  1. Why Weave (Security) worked: During standard setup, Nest Guard's OpenWeave stack intentionally accepts a custom service-config.weave specifying your own Directory/Gateway IPs and your own local CA certificate.
  2. Why onboard Google Assistant failed:
    • Guard's nlassistant daemon opens no local listening ports and exposes no Weave settings for custom server URLs, OAuth tokens, or custom CA certificates (its entire voiceassistant Weave trait only has enable/available/setup booleans).
    • Both pairing and voice traffic go outbound over TLS directly to hardcoded Google servers (mtalk.google.com:5228).
    • Even when we enabled GoogleAssistantSettingsTrait (0x235a0802) and got nlassistant to wake up, register with Google's HDS backend, and broadcast GADevice._gasetup._udp.local. on LAN mDNS, pairing fails at Google's cloud handshake: Google's setup flow queries the shut-down Nest Secure cloud to match the device's obfuscated_device_id, and current Google Home / Assistant apps no longer pair legacy _gasetup._udp Libassistant devices.
    • Because this project intentionally does not root or flash custom firmware onto Nest Guard, the onboard mic/speaker cannot be repurposed into a custom local voice assistant either.
  3. What DOES still work with Guard's mic & speaker:
    • All built-in spoken voice prompts, door open chimes, entry/exit countdown beeps, and the full alarm siren work 100% locally.
    • On-device Glass Break detection uses Nest Guard's microphone locally and feeds directly into Guard's IntrusionDetector with zero cloud required.
    • (Note: An experimental, optional Google Home Cloud-to-Cloud bridge server/owner-service/wyse_ghome.py is included in the repo and disabled by default — set NSR_GHOME_ENABLED=1 only if you want to link your server to your own Google Home Developer Console project, though Google Home's app itself imposes strict UI/voice guardrails on SECURITYSYSTEM devices.)

Prerequisites & Deployment Modes

1. Hardware You Need

  • Nest Guard (and optionally Nest Detect sensors and Nest Tags) that you own, along with each device's printed 6-character Entry Key.
  • A Linux server running Docker (~1 GB RAM, ~2 GB disk) — pick ONE:
    • Easy Setup — Local Home Linux Server (Recommended, $0/mo, 1 LAN IP):
      • Raspberry Pi 3/4/5, used Dell Wyse thin client (~$20–$40), mini-PC, old laptop, NAS, or Linux VM on Proxmox/TrueNAS/Unraid on your home LAN.
      • Uses 1 static/DHCP-reserved LAN IPv4 address on ports 11095–11097 (plus optional Apple HomeKit on 51826/tcp + 5353/udp), keeping Weave completely off the public internet.
    • Classic Mode A — Local Home Linux Server (server/setup.sh, 3 LAN IPs + systemd):
      • Uses 3 static LAN IPv4 addresses on the same NIC (all on standard Weave port 11095) + host systemd API service. See docs/SETUP.md.
    • Mode B — Direct Cloud VPS (Zero home server hardware required!):
      • Any $3–$5/month Linux VPS with 1 public IPv4 address (runs Directory/Gateway/Pairing on ports 11095, 11096, 11097 + Caddy HTTPS on port 443).
      • Works just like Google's original Nest cloud: once you send service-config.weave over BLE from a laptop at home once (guard_ble_provision.py --register-service), Nest Guard connects outbound to your VPS on its own — no Raspberry Pi or home router port-forwarding required!
  • An Android phone (Android 8.0 / API 26+) or iPhone / iPad (iOS 17+ for the native SwiftUI app, or any iOS device for Apple HomeKit).

2. Choosing Your Install Mode

Easy Setup (Home LAN, Recommended) Classic Home Server (server/setup.sh) Mode B: Direct Cloud VPS
Home server hardware Pi / Wyse / mini-PC / NAS Pi / Wyse / mini-PC / NAS None
LAN IPs needed 1 (ports 11095–11097) 3 (all on port 11095) 1 public IP (ports 11095–11097)
Setup experience 1 command + Guided Browser Wizard Interactive terminal scripts Interactive terminal + 1-time BLE
Apple HomeKit Bridge Built-in (docker-compose.homekit.yml) Built-in (host HAP-python) Not applicable (needs local LAN mDNS)
Monthly cost $0 $0 ~$3–$5/month
Works if home internet drops? Yes (LAN app + Guard stay live) Yes (LAN app + Guard stay live) App offline until ISP returns (Guard + Detects still alarm locally)

3. Remote Phone Access (Home Server Users)

On your home Wi-Fi, the Android and iOS apps connect directly to http://<HOME_SERVER_IP>:8420. To reach a Home Server while away from home, pick one of these methods (full step-by-step configs in docs/REMOTE_ACCESS.md):

Option Cost Works behind CGNAT? Open Router Ports? Difficulty
1. Tailscale VPN (Recommended) Free Yes None Easiest (~5 min)
2. Cloudflare Tunnel Free (+ domain) Yes None Easy (~10 min)
3. DDNS + Reverse Proxy (Caddy/Traefik) + Let's Encrypt Free No (needs public IP) Port 443 Medium
4. VPS WireGuard Reverse Tunnel (if keeping Weave local) ~$3–$5/mo Yes None at home Medium-Advanced

[!WARNING] Never expose raw HTTP port 8420 directly to the public internet. Always wrap remote access in a VPN (Tailscale/WireGuard) or HTTPS (TLS) reverse proxy.


Documentation

  • DISCLAIMER.md — Safety, liability, and no-support notice (read first).
  • docs/EASY_SETUP.md — Start here! 1-command install.sh, firewall helper, Apple HomeKit in Docker Compose, Guided 4-Step Browser Wizard, and zero-terminal Bluetooth Wi-Fi Setup.
  • docs/SETUP.md — Classic server/setup.sh installation (3 static LAN IPs + systemd), Direct Cloud VPS enrollment, CLI tools, and building mobile apps from source.
  • docs/IOS_AND_HOMEKIT.md — Installing the native iOS app (SideStore, Sideloadly, AltStore, Xcode), iOS Bluetooth Wi-Fi Setup, and setting up the local Apple HomeKit (Apple Home & Siri) bridge in Docker Compose or Classic mode.
  • docs/REMOTE_ACCESS.md — Detailed setup guides for Tailscale, Cloudflare Tunnel, Caddy/Traefik DDNS + HTTPS, Direct Cloud VPS, and WireGuard relay.
  • docs/ARCHITECTURE.md — Technical deep-dive into OpenWeave protocols, WDM traits, battery ESR telemetry, and container architecture.

Repository Structure

nest-secure-resurrection/
├── install.sh                     # 1-command Linux easy installer (Docker Compose + firewall + QR + HomeKit prompt)
├── docker-compose.yml             # Easy Setup stack (directory, pairing, gateway + REST API + Guided Wizard)
├── docker-compose.homekit.yml     # Optional Apple HomeKit Bridge overlay (host network mDNS/HAP)
├── docker-compose.build.yml       # Local image build overlay (fallback when ghcr.io image unavailable)
├── server/
│   ├── Dockerfile                 # Multi-arch image: upstream OpenWeave + owner-service-v2 + HAP-python
│   ├── setup.sh                   # Classic interactive Linux / Cloud VPS installer (3 LAN IPs + systemd)
│   ├── env.example                # Classic configuration template (no secrets)
│   ├── patches/                   # Clean patches against openweave-core @ e3c8ca3d
│   ├── owner-service/             # C++ OpenWeave owner service, Python REST/SSE API, Guided Setup Wizard, HomeKit bridge
│   ├── enrollment/                # Guard & Detect enrollment, BLE Wi-Fi provisioning, and status CLI tools
│   ├── systemd/                   # Classic systemd unit file template
│   └── tests/                     # Python unit tests (unittest / pytest)
├── android/                       # Native Kotlin + Jetpack Compose Android app (with native BLE Wi-Fi Setup)
├── ios/                           # Native SwiftUI iOS app + NestGuardCore Swift package (with native BLE Wi-Fi Setup)
├── docs/                          # Easy Setup, Classic Setup, iOS/HomeKit, Remote Access, Architecture & screenshots
├── DISCLAIMER.md
└── LICENSE                        # Apache License 2.0

License & Attribution

  • Licensed under the Apache License 2.0.
  • Built on top of OpenWeave Core (Apache-2.0, Nest Labs / Google).
  • "Nest", "Nest Secure", "Nest Guard", "Nest Detect", "Nest Tag", and "Google Home" are trademarks of Google LLC. This independent open-source project is not affiliated with, sponsored by, or endorsed by Google LLC.

Explore related projects

Loading…