Door and Window Sensor Automation Ideas - Using Contact Sensors in Home Automation

In this blog post I show you my favourite contact sensor automations that I use around my house.

Which Contact Sensors?

I use a combination of Aqara and Sonoff door and window sensors in my house. These are connected to Home Assistant using Zigbee.

Aqara and Sonoff contact sensors side by side

Aqara and Sonoff contact sensors side by side

Both these sensors are affordable and have been rock solid in my environment. The Sonoff sensor is slightly physically larger than the Aqara, and like most of their Home Automation devices, the Aqara door sensor feels like it has been built to a high quality.

For that reason I would recommend buying the Aqara contact sensor if you're looking to start out from scratch. Regardless of which sensor you choose, you will need to pair them directly with Home Assistant using a Zigbee Dongle.

Contact Sensors in Home Assistant

Both devices provide relatively similar information into Home Assistant as entities. These are:

  • Door Open/Closed

  • Battery Level & Voltage

  • Zigbee Link Quality

Sonoff and Aqara Contact Sensor Entities in Home Assistant

Sonoff and Aqara Contact Sensor Entities in Home Assistant

The Aqara also seems to provide a temperature reading of the device. I have not found it to be at all accurate, and do not recommend using this reading. If you want to measure the temperature, then use a dedicated Aqara Temperature Sensor.

Contact Sensor Automations

Here is a list of the automations that I use in my house that rely on Door and Window Contact Sensors. The links below will take you to detailed instructions for how to set up that automation in your own Home Assistant setup.

Previous
Previous

Get notified if a door or window is opened whilst you’re away

Next
Next

How to make lights flash around the house when a sensor is triggered