Home Assistant

WhatsApp notifications from Home Assistant

There's no built-in WhatsApp integration in Home Assistant. For a business number, the usual route is a rest_command that calls a WhatsApp API. Here's the config, with examples from holiday parks, marinas and buildings.

The short answer

A rest_command to your own number

1

A template

Get a utility template approved, with fixed wording around the details such as the location and the fault.

2

A rest_command

The API key goes in secrets.yaml, the command in configuration.yaml. Restart once and it's ready.

3

An automation

Call the command from any trigger: a leak sensor, a door contact, a temperature reading.

secrets.yaml
tobachat_api_key: tc_live_...
configuration.yaml
rest_command:
  tobachat_alert:
    url: https://api.tobachat.nl/v1/send-template
    method: POST
    headers:
      X-API-Key: !secret tobachat_api_key
    content_type: "application/json"
    payload: >-
      {"phone": "{{ phone }}",
       "template": "outage_alert",
       "language": "en",
       "variable_mapping": {"1": {{ where | to_json }}, "2": {{ what | to_json }}}}
automations.yaml
- alias: "Leak in the plant room"
  triggers:
    - trigger: state
      entity_id: binary_sensor.leak_sensor_plant_room
      to: "on"
  actions:
    - action: rest_command.tobachat_alert
      data:
        phone: "+31612345678"
        where: "Plant room"
        what: "water on the floor"
Examples

Alerts businesses set up

Fixed template wording, with the details filled in by Home Assistant.

Holiday park

Alert from Lodge 14: bathroom leak sensor triggered.

Marina

Alert from pontoon B, berth 7: shore power lost.

Office building

Alert from the plant room: boiler pressure below 1 bar.

End every template with fixed wording, such as: You get this message because you signed up for our outage alerts.

WhatsApp's rules

What an alert has to meet

  • Only to people who asked: your team, or a customer who signed up for alerts. Anyone who replies STOP gets nothing more.
  • Pick the Utility category and leave offers out, or Meta may reclassify the template as marketing, which costs more.
  • A template can't start or end with a variable.
With Tobachat

Alerts from the number your customers already know

Your own business number

The alert comes from your number with your business name on top, over the official WhatsApp Business Platform.

No duplicates

Add an Idempotency-Key and we won't send the same alert twice within 24 hours, even when Home Assistant retries.

Every alert in your inbox

You see every alert in your shared inbox, and when the caretaker or a guest replies, you answer right there.

More than alerts

The same number answers customer questions too, handled by your team or the AI agent.

Pricing

What it costs

Alerts are part of every plan. Start free, then €29, €99 or €199 a month, cancel any month. Meta charges per alert on top, depending on the recipient's country.

Questions

Home Assistant and WhatsApp

Yes. Call the command once per number, and each person gets their own message.

More guides

Other questions about WhatsApp

Your first alert from Home Assistant

Start free, connect your number and create an API key.

Prefer a hand getting started? We'll get you started

Start free, no credit card required No setup fees No commitment