Trigger automation when temperature is above 21

I want to build an automation that is triggered when de current temperature in my living room is above 21 degrees. This is what I’ve got:

The automation simply doesn’t get triggered. I tried numerous of variations, including templates but nothing seems to work. I also build a custom sensor with the current_temperature in it’s state, but triggering on that sensor also gives zero result.

I hope anyone of you guys can help me out with this. I bet it’s simple, but I already spent hours on it without any luck.

Did the attribute ‘current_temperature’ of the ‘climate.woonkamer’ entity go from below 21 to above 21? The trigger only happens when the threshold is crossed. And it will then only trigger again when it goes below 21 and then above 21 again.

Can you verify what’s the attribute value of the entity climate.woonkamer is in the developer tools?

Yes it did. I tested it by turning on a electrical heater to make the current temperature go up. I also tested with the “temperature” attribute, as that’s easier to change.

Yes it’s there:

It’s below 21 now, but I can ensure you that it came from below, and has come above during my test.

Please show the rest of the automation, and please post the code not pictures. Do you get any errors under Configuration -> Logs? How do you know it doesn’t trigger? Maybe the action is not working or a conditon is not correct.

Please enter the attribute as: current_temperature

I got it working. It’s a bit silly but because at first I couldn’t get it to work, I was with different conditions that weren’t met. When I disabled those conditions I was testing with a notification as an action, because I didn’t want to execute the real automation all the time. But it seemed that the notification in my phone wasn’t working properly either.

So after all the final config I posted here, was working. Sorry guys :slight_smile: