Camera Pop-Up Alert in Home-Assistant

Hello !

Wouldn't it be nice to receive a text banner notofication or pop-up from the camera if someone opens the main door or if a motion is detected?

Today, I'm going to show you how this is possible with Home Assistant.


I am using a Zigbee door sensor from Moes for this, which will give the real-time door status and can be used as the trigger for the automation in the home-assistant, which in turn gives a banner message like in the picture below.

(Note: For this to work you should be using the Home-Assistant companion app in your mobile/tab.)

  • Use the below given yaml for creating an automation for the banner notification :

                alias: Front Door Alert!
                description: "Notifying Door Open Status"
                trigger:
                  - platform: state
                    entity_id:
                      - binary_sensor.xxxxxxxxx
                    to: "on"condition: []
                action:
                  - service: notify.notify
                    data:
                      message: Someone opened the door at {{ now().strftime('%-I:%-M %p | %d %b %Y') }}
                      title: Office Front Door Alert !!
                      data:
                        time: now().hour
                mode: single

              
Door Open

You can also add a camera pop-up to see who has opened the door.

To do this, we need to install the "BrowserMod" integration from HACS. Follow the instructions in this link to install BrowserMod.

We can now write a simple script for camera pop-ups using the "browser_mod.popup" service. Later, we can call this script in the previous automation as an "action".

YAML for the script :


                alias: "Camera Pop-up"
                sequence:
                  - service: browser_mod.popup
                    data:
                      title: null
                      dismissable: true
                      size: normal
                      auto_close: true
                      timeout: 120000
                      target:
                        device_ID:
                          - My iPad
                          - My Mobile
                      content:
                        camera_view: live
                        type: picture-entity
                        entity: camera.xxxxxx
                        name: Office Camera
                mode: single
                icon: mdi:cctv

              

YAML for the final automation :


                alias: Front Door Alert!
                description: "Notifying Door Open Status"
                trigger:
                  - platform: state
                    entity_id:
                      - binary_sensor.xxxxxxx
                    to: "on"condition: []
                action:
                  - service: script.xxxxxxx
                    data: {}
                    enabled: false
                  - service: notify.notify
                    data:
                      message: Someone opened the door at {{ now().strftime('%-I:%-M %p | %d %b %Y') }}
                      title: Office Front Door Alert !!
                      data:
                        time: now().hour
                mode: single

              
Camera pop-up

Thank you note !

I want to personally thank you for reading my article. Your time and attention are greatly appreciated, and it means a lot to me that you took the time to engage with my content.

Your support and feedback are invaluable, and I am grateful for the opportunity to share my thoughts and ideas with you. Whether you left a comment, shared the article, or read it, your participation helps fuel my passion for writing and motivates me to keep creating content that resonates with readers like you.

Please feel free to reach out if you have any thoughts, questions, or feedback about the article. I love hearing from my readers and learning about your perspectives.

Once again, thank you for your support. I look forward to sharing more with you soon.