How to...

Setting up an Arm/Disarm Alarm Automation with the Aqara Hub

IMPORTANT NOTE: It’s come to our attention that this alarm automation is not working for some people, and is for others. This seems to be down to an issue with Aqara’s Cloud servers, so it’s best to not rely on this method until these issues are fixed – and ultimately, if you shouldn’t rely on this as your only alarm setup if it’s something you need for security, as it’s not currently as reliable as a fully professional alarm system.

Our website has had a few people writing in, asking how they can set up an alarm with the Aqara Hub, using a door sensor detecting that the door opens, which in turn triggers the alarm on the Aqara Hub, which is easy enough in the Aqara app (the alarm/speaker can only be accessed via the Aqara app). However, to create an alarm that can be armed and disarmed remotely is stumping some people, so we thought we’d present a short ‘how To’ to explain how it’s done, but in order to do this, you will need the following devices;

  • Aqara Hub
  • Aqara or Mijia Door & window Sensor
  • Aqara or Mijia wireless mini switch

(1) So, click on the Automation tab and click the ‘plus’ symbol at the top to create your first of two automations. (2) Then, clicking on ‘add’ in the ‘IF’ section, you choose the device that you want to trigger the alarm, in my case the Aqara Door. (3) Once selected, you need to choose which action will trigger the alarm, in my case, when the door opens.

(4) Once you’ve completed these steps, you’ll be taken back to the ‘IF-THEN’ page. Click ‘Add’ in the ‘THEN’ section. (5) Select the Aqara Hub as the device to be triggered. (6) Select ‘Play alarm sound’.

(7) Then on the next screen, choose the relevant sound you want for your alarm, and the desired volume level. (8) Click OK at the top of the screen and you’ll return to the previous screen with a completed automation. (9) Click ‘Save’ and then name your automation – in my case ‘door opens – alarm sounds’.

Now, you’ve created an automation that will trigger the alarm every time you open the door, but that’s no good if you don’t want the alarm to trigger every time you come and go. You can of course turn off the alarm in the app, but with a carefully placed Aqara Switch, you can simply arm or disarm this action without having to go into the app at all.

(10) So the automation you’ve created will appear in the list of automations. Now for the second part. (11) Create another automation whilst in the automations list page, by clicking on the plus symbol at the top, which will bring you to the ‘IF THEN’ page, so click ‘add’ in the ‘IF’ section, then select the device to arm/disarm your alarm – I’m selecting the Mini Switch. (12) once selected, you simply choose the relevant action, in this case a ‘single press’ action is good enough.

(13) You will then return to the ‘IF THEN’ screen. (14) Click on ‘add’ on the ‘THEN’ section and then – crucially – instead of selecting a device to be triggered, scroll down and select the first automation you created – in my case ‘Door Opens – Alarm Sounds’. (15) Once you click on this, you will be offered a choice as to whether you want to have the Mini Switch action do one of the following actions;

  • Turn on
  • Turn off
  • Turn on/off

I choose, turn on/off, so that allows my switch to toggle the alarm on and off with one action.

(16) Once you’ve selected your choice, you’ll then return to the previous ‘IF THEN’ page to show your completed second automation, which in turn controls the first automation. Click on Save and name your automation. After that is all complete, you can test the Mini switch while directly in the automation page to see it (17) toggle on and (18) toggle off.

One thing to note is that there may be times when you forget whether you’ve toggled the switch to set arming or disarming, so in this case, you might want to assign two separate automations, with two separate button actions – maybe single click for ‘arm’, and a double-click for ‘disarm’. One other thing you may want to do, is add a delay to the first automation, so that when you return home from a night out, you’re not immediately greeted with a screaming alarm sound. The automation would look like the image below;

Finally, it may be a good idea to place your mini switch (or other device) in a secret location, so as to avoid having someone break into your house and immediately disable the alarm!

any questions – feel free to post.

The Editor

Editor - Musician, graphic designer and HomeKit aficionado.

11 thoughts on “Setting up an Arm/Disarm Alarm Automation with the Aqara Hub

  • Hi Michael, thanks for the comprehensive post. I’m trying to do as you explain, but when I try to add a new automation the only trigger that I have available on the IF actions is “Timer”. None of my sensors/devices appear as triggers, so I can’t select the door sensor. I have the region set to Mainland China on my profile, so I don’t understand what the problem is.

    Any ideias?

    Regards

  • There could be two reasons, but one is simple to fix, the other not so easy at present. First off all, when you create any automations, make sure that after you click add in either the IF or THEN sections, that at the top of the screen you have your home selected (on the right) and ‘All’ is on the left. If it shows a room and the device you’re looking for isn’t in that particular room, then it won’t be visible. That’s the easy fix. If it isn’t that, then it may well be that you’re having a similar issue to other people. The way to check is to see what firmware version your hub is – mine is 1.2.30, but many others are stuck on an earlier firmware number and can’t currently update. These people are usually in the EU it seems. Either way, make sure you’re server is set to Mainland China and that you’ve set up and Aqara account, which I see you’ve done regarding the server side of things.

    • Yes, I’m in the EU and the my firmware version is 1.2.26. When I try to update it says that I already have the latest version.

      How does the app know I’m in the EU? From the region set in my iPhone? I could try changing the region to another one to see if I can update the firmware. Do you think this would work?

      • I don’t know if it will work, but they may be using location services too, but I’m not sure. Worth a try though. If it does work, do let me know.

  • Good post~

    I have a quick question, do we get notification from the Apple homekit app for the setup you do in Aqara.app?

    I am moving to new home around the end of this month, I guess I will be setting up all these in mid Nov.

    • Hi Jack
      as the speaker part of the Aqara Hub isn’t exposed to HomeKit currently, there’s no way to get a notification of the alarm being triggered. However, you can set up notifications in the Apple Home app, for the door sensor being triggered, for just when you’re not at home. You do get notifications to your phone from the Aqara app, when the Aqara alarm has been triggered though, so even though that isn’t coming from the Home itself, you’re still getting notifications specifically relating to the alarm and not just the door sensor.

  • Thnx for your explanation! But it doesn’t seem to work here. The problem is that I have the alarm off button inside my house. When I open the door I have a 10 Seconds delay before the alarm goes off just like you said. When I push the button the alarm automation will be turned off! But the sequence of the automation has already started! So after 10 seconds the alarm still starts to scream! 🙁 do you have any other options?

      • Hey Simon! Thanks for your reply. I also read the new article and also tried that. It al works good only the same thing as mentioned above happens.. The button will switch the alarm off before the alarm goes off (the automation part). But after the delay time the will alarm still goes off. I think because the door sensor is already triggered before you switch the alarm automation off. (Automation has already started before I can switch it off?) But there is no other way to do that because I first need to enter my house before I can push the button. Please let me know when you checked your automations. Greets Kevin

        • Hi Kevin
          sorry for the delay. I’ve tested the second automation I posted about and it seems you’re right. The alarm automation is turned off by my button (Aqara mini switch) but after the delay, the alarm still triggers. I’ve spoken to the person who suggested the ‘easier’ automation and he said that he did not have any issues, but after we both tried brand new automations, these new ones failed, like yours did. Mariusz told me that it’s an error with Aqara’s cloud server, as he had this issue before but somehow Aqara managed to fix his issue remotely by resetting his account in their cloud server. For now don’t try anything more, as it seems that Aqara will possibly be using the Mi Home app very soon, and abandoning the Aqara app, as the Mi home app is a lot more stable.

          • Hi Simon! Don’t bother the delay haha! Thnx for you help, testing and explanation! It’s good to hear the maybe the mi home app will be used in the near future! :)) let’s wait and hope for the update on November 25!!! Thnx again and keep up the good work!

Comments are closed.