How to run automation from energy dashboard values

Im trying to run an automation based on the reported values as I see on the energy dashboard.

I would like to enable a water heater when the hourly generation rises above a certain ammount (say 1KW).

These values are reported by MQTT sensors and a smart life meter as absolute KWh values, so I cant run an automation directly on them. But as HA calculates the hourly change, this would be an ideal trigger!

Any ideas on how to accomplish this?

Key word being “calculates”.

Those values are calculated from statistics data whenever the page is displayed. They are not entities, so there is nothing you can use in automations.

You need to create your own sensors. For hourly use you can use the utility meter helper.

1 Like