Smart Home Assistant

Home Assistant Frost Alert: Protect Pipes from Freezing (UK)

SepehrBy Sepehr· 4 November 2026· Updated 4 November 2026· 7 min read
✓ Independent — no paid placements✓ UK-tested in real homes✓ Cited sources
Outdoor brass tap on a brick wall with a long column of ice frozen beneath it

Key takeaways

  • A Home Assistant frost alert needs two parts: a forecast warning when tonight's low is at or below 0°C, and a sensor alert in your coldest space.
  • WaterSafe advises keeping heating at least 14°C overnight and when away, so use 14°C as the floor for your away-from-home alert.
  • A numeric state trigger with a 15-minute for delay stops a briefly opened door from firing a false cold-spot alert.
  • Forecasts are read with the weather.get_forecasts action, and field names vary by provider, so test it in Developer tools first.
  • Start with notifications rather than automatic heating changes; a silent thermostat override is much harder to debug than an alert.
On this page[tap to expand]

A Home Assistant frost alert watches two things: the forecast low for tonight and the real temperature in the coldest spots in your house. When either crosses your threshold, it sends a notification to your phone before pipes freeze, not after they burst.

You can build the whole thing in about 30 minutes with parts you probably own. The catch is that a weather forecast describes the street, not your uninsulated loft, so the most useful alert is the one fed by a cheap sensor in the cold spot itself.

What do you need before you start?

  • Home Assistant: any current release. The automations below use the newer triggers: / actions: YAML keys.
  • A forecast source: the official Met Office integration (free DataHub account, API key, one location on the free tier) or any other weather integration that supports daily forecasts.
  • A temperature sensor in the cold spot: a Zigbee or Thread temperature sensor in the loft, garage, utility room, outhouse or under the kitchen sink on an external wall. Our temperature and humidity sensor roundup covers the options.
  • The Companion app: so the alert reaches your phone. See the notifications guide if you have not set it up.

Why does a frost alert matter for pipes?

Water companies and plumbing bodies give the same basic advice every winter: keep some heat on and protect exposed pipework. WaterSafe, the UK plumbing approved-contractor scheme, says to keep your heating on at least 14°C overnight and when you are away, to insulate outside taps and pipes in unheated areas with foam insulation, and to know where your stop tap is.

That advice is easy to follow when you are home and awake. It is the nights you are away, or asleep while a cold snap arrives early, that a notification earns its keep. Home Assistant cannot lag a pipe, but it can tell you the temperature is heading for trouble while you can still act.

Step 1: Decide which temperatures you actually care about

Pick three numbers before writing any YAML. The values below are sensible starting points of my own choosing, not official thresholds, so adjust them to your house.

  • Forecast trigger: 0°C or below. If the forecast low for tonight is at or under freezing, you want a heads-up in the evening while you can still open the loft hatch or drain an outside tap.
  • Cold-spot trigger: below 4°C for 15 minutes. This is the "something is wrong right now" alert. A few degrees above freezing leaves time to act, and the 15-minute delay stops a draughty door opening from firing it.
  • Heated-rooms floor: below 14°C while you are away. This mirrors the WaterSafe figure. It catches a boiler that has locked out or a thermostat that was left switched off.

Keep the numbers as separate automations rather than one clever template. When a notification arrives you want to know at a glance which rule fired.

Step 2: Add a weather forecast entity

If you already have a weather entity, skip to Step 3. Otherwise, go to Settings > Devices & services > Add integration and search for Met Office.

The Home Assistant Met Office page explains that you register for a Met Office DataHub account, subscribe to the Site Specific Global Spot dataset, and enter the API key along with a latitude and longitude. The free tier is limited to a single location, which is fine for one house. The integration creates a weather entity with hourly (next three days), twice-daily and daily (next seven days) forecasts, and refreshes every 15 minutes.

Note the entity ID it creates. It is usually something like weather.met_office_your_location, but check Settings > Devices & services > Entities rather than assuming, because the examples below need the exact name.

Step 3: Build the forecast frost warning

To read a forecast, you call the weather.get_forecasts action, which returns the forecast for one or more weather entities into a response variable. The response is keyed by entity ID, and each entity has a forecast list of entries with fields such as datetime, condition and temperature.

Before writing the automation, open Developer tools > Actions, run weather.get_forecasts with type: daily against your entity, and look at what comes back. Check whether the first entry contains a low-temperature field (usually templow) and whether the first entry is today or tonight. Providers differ and I would rather you confirm than trust a copy-pasted template.

alias: "Frost warning: forecast low at or below freezing"
triggers:
  - trigger: time
    at: "21:00:00"
actions:
  - action: weather.get_forecasts
    target:
      entity_id: weather.met_office_home
    data:
      type: daily
    response_variable: daily
  - if:
      - condition: template
        value_template: >
          {{ daily['weather.met_office_home'].forecast[0].templow
             | float(99) <= 0 }}
    then:
      - action: notify.send_message
        target:
          entity_id: notify.my_phone
        data:
          message: >
            Frost forecast tonight: low of
            {{ daily['weather.met_office_home'].forecast[0].templow }}°C.
            Check outside taps and the loft.
mode: single

Replace weather.met_office_home and notify.my_phone with your own entity IDs. The float(99) means a missing value becomes 99, so a failed forecast stays silent rather than throwing a false alarm. If the first daily entry turns out to be the daytime period, change forecast[0] to forecast[1] so the automation reads the right night.

Use notify.send_message pointed at your phone, as the Home Assistant notify documentation recommends for current setups. The older phone-specific notify.mobile_app_* action still works on some installs, and the Companion app documentation lists the extra options such as priority and notification tags.

Step 4: Build the cold-spot alert

This is the one that protects you. It watches a sensor in the loft, garage or utility room and fires when it stays cold.

alias: "Frost alert: cold spot below 4C"
triggers:
  - trigger: numeric_state
    entity_id: sensor.loft_temperature
    below: 4
    for: "00:15:00"
actions:
  - action: notify.send_message
    target:
      entity_id: notify.my_phone
    data:
      message: >
        {{ trigger.to_state.name }} has been under 4°C for 15 minutes
        ({{ trigger.to_state.state }}°C). Pipes nearby could freeze.
mode: single

The numeric state trigger takes below and an optional for, and the Home Assistant documentation notes that entity_id can be a list. That means you can add every cold-spot sensor to one automation, and the trigger.to_state.name in the message tells you which one fired.

Place sensors where water pipes are most exposed: against an external wall, near an outside tap's internal run, in an unheated outhouse, or in the loft close to the cold water tank. A sensor in a warm hallway tells you nothing useful about a pipe in a garage.

Step 5: Add a heated-rooms floor for when you are away

Last, catch the scenario where the whole house goes cold while nobody is in. This one only fires when everyone is out, so it will not nag you on a chilly evening at home.

alias: "Frost alert: house cold while away"
triggers:
  - trigger: numeric_state
    entity_id: sensor.living_room_temperature
    below: 14
    for: "00:30:00"
conditions:
  - condition: state
    entity_id: zone.home
    state: "0"
actions:
  - action: notify.send_message
    target:
      entity_id: notify.my_phone
    data:
      message: >
        The living room has been under 14°C for 30 minutes and nobody is home.
        Check the boiler and heating schedule.
mode: single

The zone.home state is the number of people currently in the zone, so "0" means nobody is home. If you use a different presence method, such as the approach in our presence detection guide, swap the condition for that entity.

I have deliberately made this an alert, not an automatic change to the thermostat. Heating setups vary a lot, from a single zone to per-room radiator valves, and an automation that silently overrides a schedule is hard to debug. If you want Home Assistant to act, the heating control guide shows how to drive a thermostat safely. For longer trips, pair this with the holiday mode guide.

How do you test a frost alert without waiting for winter?

Test each automation by hand. For the forecast warning, use the automation's Run button in the editor: the time trigger is bypassed but the actions run, so you will see whether the template reads a sensible value. If the notification does not arrive, open the trace to see where it stopped.

For the cold-spot alert, go to Developer tools > States, pick the sensor, and set its state to 2 to simulate a cold reading. Fifteen minutes later, the notification should fire. This only changes the stored state until the next real update, and it does not affect the physical device. Remember to wait for the for period, or temporarily set it to a short value while testing and change it back afterwards.

Why is my frost alert not firing?

The sensor shows unavailable: a numeric state trigger cannot fire on an unavailable or unknown state. Add a separate automation that notifies you when a cold-spot sensor has been unavailable for an hour, because a dead battery in a freezing loft is exactly when you want to know.

The forecast template errors: the field name differs between providers. Re-run weather.get_forecasts in Developer tools and copy the exact field names from the response.

It fires every few minutes: the sensor is hovering around the threshold. Lengthen the for time or lower the threshold by a degree, and keep mode: single so duplicate runs do not stack up.

Nothing arrives on the phone: check the notify entity name and that the Companion app is allowed to send notifications in your phone settings.

What should you do after the alert fires?

Know where your stop tap is before you need it, because WaterSafe suggests turning it off if you are leaving the property overnight or longer. Insulate outside taps and exposed pipes with foam lagging. Keep heating at 14°C or above while away. If a pipe does freeze, thaw it gently with a hairdryer on its lowest setting or warm towels, avoid naked flames, and do not switch on a heating system that has been off in order to thaw it.

A frost alert warns about cold. A leak sensor tells you when the cold has already done damage. Our water leak sensor roundup covers the ones that work well with Home Assistant, and together the two close the gap between a freeze and a flood.

Buy the picks in this guide

Recommended for Home Automation

See all devices →

Frequently asked questions

How do I get a frost alert in Home Assistant?
Create an automation with a numeric state trigger on a temperature sensor placed in your coldest space, such as the loft or garage, set to fire when it stays below about 4°C for 15 minutes, and have it send a notification to your phone. Add a second, evening automation that calls the weather.get_forecasts action and warns you when the forecast low is at or under 0°C. Together they cover both the incoming cold and the actual conditions at your pipes. The caveat is that the thresholds are your own judgement, not an official standard, so tune them to your house. A sensor in the right place matters far more than a precise number.
What temperature should a frost alert trigger at?
For a forecast alert, 0°C or below is the natural line, because that is when freezing becomes possible outdoors. For a sensor inside an unheated space, a higher trigger such as 4°C gives you time to react before a pipe is at risk, though that figure is a practical choice rather than a standard. For heated rooms, WaterSafe advises keeping heating on at least 14°C overnight and when you are away to stop pipes freezing, so that is a sensible floor for an away-from-home alert. The caveat is that the air temperature near a pipe on an external wall can be colder than the room reading, so place the sensor close to the exposed pipework.
Does the Met Office integration give a frost forecast in Home Assistant?
Yes, it provides weather forecasts you can use for a frost warning, though not a dedicated frost sensor. The Home Assistant Met Office integration needs a free DataHub account and an API key for the Site Specific Global Spot dataset, supports one location on the free tier, and offers hourly, twice-daily and daily forecasts that refresh every 15 minutes. You read the forecast with the weather.get_forecasts action and test the low temperature in a template. The caveat is that it forecasts conditions for a point location, not your loft or an exposed outhouse, so pair it with a real sensor where your pipes run.
Can Home Assistant turn the heating on automatically when it freezes?
It can, but whether it should depends on your heating. If you have a smart thermostat or radiator valves that Home Assistant controls, an automation can raise the target temperature when a cold-spot sensor drops below a threshold. The safer starting point is an alert, because a silent override of a schedule is hard to debug and some boilers or thermostats behave unexpectedly when told to heat to a new target. Start with notifications, watch how often they fire for a few weeks, then automate the response if the pattern is clear. Our heating control guide covers how to drive thermostats and valves from Home Assistant without fighting the schedule.

Sources

Sources verified 2026-11-04

  1. Home Assistant — Weather integration (weather.get_forecasts)
  2. Home Assistant — Met Office integration
  3. Home Assistant — Numeric state trigger
  4. Home Assistant — Notify integration
  5. WaterSafe — Winter advice: protecting pipes
  6. Wikimedia Commons — Frozen water tap by Paul van de Velde, CC BY 2.0
›How we researched this

Claims in this article are checked against primary sources — manufacturer specifications, official documentation, Which? research, Ofgem guidance, or gov.uk — rather than forum threads or video reviews. Where the author has direct hands-on experience with a product (most Home Assistant, Zigbee, and home-networking gear is running in his own homelab), that is stated explicitly in the text.

For categories outside that personal setup — such as boilers, heat pumps, and other areas that are traditionally a heating engineer's domain — verdicts are built from cross-referenced manufacturer data, published lab results, and vetted expert and owner reviews rather than a claim of personal hands-on testing. See the editorial policy for the full methodology.

Sepehr

Written by

Sepehr

10+ years hands-on with Home Assistant & networking · Research-backed elsewhere · No brand deals

Smart home specialist with 10+ years running a self-hosted Home Assistant setup — Zigbee2MQTT, Frigate NVR, and local-first automations. Independent coverage for UK homes, no brand deals.

LinkedIn →

Citing this page? Please use a dofollow link back to the original article — it helps us keep the data on this page accurate and up to date.

Related reading