The Aqara H1 Zigbee switch with open software – a smart home test with ZHA and Zigbee2MQTT
Smart lightbulbs are great but they get quite dumb really quickly when you toggle the light switch. The Aqara H1 switch can fix this issue. It works with Zigbee in Home Assistant, either with ZHA or Zigbee2MQTT and has a special decoupled mode for usage with smart lights.
The Aqara H1 switch
I am already using many Aqara components like motion sensors for my smart light system and some of their battery powered switches. The water leak sensor saved my kitchen once and I even repurposed a door sensor to make a doorbell smart. Obviously when I saw their new light switches I wanted to give them a try too.
If you a looking to by this switch consider using my affiliate link to support the blog
No neutral Aqara H1 switch
Neutral Aqara H1 switch
Sonoff Zigbee dongle plus for ZHA/Z2M
In tried the one rocker EU version with no neutral wire needed. Installation has should be done by a professional but is quite simple: just connect the line in and out to the screw terminals at the back of the switch. Whats great about it is that you can remove the front part of the switch from the back. You can first install that and then just plug the front into the socket.
The switches dimensions are ~86x86x38mm so it should fit in most wall boxes. It needs to be screwed in place though which might be a problem in some cases! I know that in my apartment most switches are using clamps to stay in place.
The packaging itself is quite well done, as expected from Aqara and includes the switch itself, some screws and a manual. It is not super cheap at a price of ~38€-42€ depending on the version but many alternatives are even more expensive and it comes with some great features, more on that in a second.
Of course the switch is using Zigbee 3 to communicate but keep in mind that the non neutral version is an end device, no router (so it will not extend your Zigbee network). It also needs a minimal load of ~3W, which is important, more on that at the end of this article. I have not tried it but the version with a neutral wire should act as a router/repeater and also include power measuring.
I really like the hardware of the switch. While it does not look super futuristic or special it has a very clean look to me and the clicking is just so satisfying! It also has a small LED that indicates the current status but is small enough to not be annoying. It also comes with all the needed security certificates (according to Aqara) that are needed to actually use such a switch (most China hardware switches actually don’t…).
Finally its killer feature (in my opinion) is the so called decoupled mode. I want to use smart light bulbs in my smart light system because they can control the color and brightness of the light while switches can usually only turn light on or off. I also want a physical switch though. The problem is that once the switch turns off the power to the smart bulb it can’t really be turned on again without the switch.
This is where the decoupled mode comes in handy: it disconnects the button from the actual relay. If pressed it will only send a message via Zigbee and let the control software decide what to do (for example to toggle the actual light bulb). This can also be handy if there is (currently) no device connected to the second rocker for example: it can then be used to control some other smart device.
Using the Aqara H1 with ZHA
I am currently controlling my Zigbee network with Home Assistant and ZHA with the Sonoff dongle plus so I started there. Adding the switch to ZHA is quite easy: just use the usual Integrations – ZHA – configure – add device. Press the switch for around 5 to 10 seconds until the LED starts blinking and it should show up in Home Assistant.
Added via ZHA the switch has the basics: one on/off control that works very well. The only other datapoint exposed is the device temperature which is stuck at 0.3°C though (no it is not freezing here ;)). I created a GitHub ticket to hopefully fix this.
Unfortunately it also does not support setting the switch to decoupled mode even via the cluster configuration. It is enough for simple automations though where you are just looking to turn on or off some load. To experiment some more I then switched to Zigbee2MQTT.
Using the Aqara H1 with Zigbee2MQTT (and Home Assistant)
While I do run my network mainly via ZHA I still have my old Sonoff Zbridge with I now use to test devices via Zigbee2MQTT. After adding the device there via the permit join button at the top it showed up correctly and supports way more options.
Not only can you turn the switch on or off, you can also control the LED (turn it on/off or flip its status), enable or disable power outage memory and most importantly change the switch modes. There is an anti flimmer mode and a quick mode (made no difference in my case) and the normal vs decoupled mode. Putting the switch in decoupled mode makes it just send an action on click and not actually turn on/off the relay.
Of course through MQTT this switch also shows up automatically in Home Assistant where it looks like this. It includes control over most of the configurations and receives actions from Zigbee2MQTT on click that can be used in automations.
I created a very simple automation that makes the switch work as any normal switch would by switching the smart light bulb instead of the relay. Of course you can also add any other effect like a time based condition or controlling multiple lights.
alias: Bathroom manual lightswitch description: '' trigger: - platform: device domain: mqtt device_id: aqaraswitchid123 type: action subtype: single discovery_id: 0x54ef4410003671af action_single condition:  action: - type: toggle device_id: lightbulbid123 entity_id: light.bulb_bath_level_on_off domain: light mode: single
The problem with the minimal load
Do you remember the 3W minimal load I mentioned earlier? The switch is only connected to one power line so if it turns off it breaks the circuit and terminates its own power supply. These smart switches get around that by using some minimal flow to siphon off some power.
If you use a low power smart devices like the smart LEDs you might run into problems. For me the setup works well if I just use the Aqara H1’s relay to turn on or off the bulb but if I use the decoupled mode the switch loses power at some point during when turning on/off the LED quickly. I could not get that to work reliably.
Using the switch with a separate test setup and a big old light bulb it works 100% reliable. There are small devices like the shelly bypass that create an artificial load to fix this issue but that costs money and produces heat – too much of a security issue for me. So keep this in mind when planning your smart light setup.
Possible workaround (affiliate link):
If you have a neutral wire all of this is not a problem anymore, the “with neutral” version has no minimal power requirement.