3.0 KiB
layout | title | description | date | sidebar | comments | sharing | footer |
---|---|---|---|---|---|---|---|
page | Setting up presence detection | Instructions how to setup presence detection within Home Assistant. | 2015-10-4 12:08 | true | false | true | true |
We care about privacy. Collected data is only stored in your instance of Home Assistant.
Presence detection detects if people are home, an important input for automation. The most important piece of information is to know if anyone is home. But knowing who is home or where they are will open a whole range of other automation options:
- Send me a notification when my child arrives at school
- Turn on the AC when I leave work
Screenshot of Home Assistant showing a school, work and home zone and two people.
{% linkable_title Setting it up %}
The device tracker component offers presence detection for Home Assistant. It supports two different methods for presence detection: scan for connected devices on the local network and connect to third party service.
Scanning for connected devices is easy to setup. See the instructions for our supported routers or scan the network using nmap. This approach does have its limitations however, it will only be able to detect if a device is home. It also struggles with iPhones because they disconnect from WiFi if idle, marking them as not home when they actually are.
Home Assistant currently supports two third party services for presence detection: OwnTracks and Locative. OwnTracks is an app that you install on your iPhone or Android phone that allows you to push the location of your device to Home Assistant using an MQTT broker. An MQTT broker is an Internet of Things communication platform that you can freely host yourself or get a private instance for free in the cloud.
OwnTracks communicates directly with your MQTT broker, no data will pass through their servers.
{% linkable_title Zones %}

Home Assistant will know the location of your device if you are using OwnTracks. By setting up zones you will be able to add names to the locations of your devices. This way you can easily spot on the state page where the people in your house are and use it as triggers and conditions for automation.