#Countdown timer with date/time/duration picker

1 messages · Page 1 of 1 (latest)

faint storm
#

Is there any way to create a countdown timer with a date/time/duration picker?

The idea is to give the user a way to select on a dashboard a timer that will count down to some time in the future (ex. 8 hours from now, or on 2025-07-28 at 20:00) to trigger automations off of. So for example, if I'm going on vacation and I want my house to run in a low energy mode until a few hours before my return, I can kick off the timer, and when the timer gets to zero, my automations will fire to bring my house up to the correct temperature, etc.

I can't use zone-based automations for this, because if I wait until I'm in my house zone the house will be too hot/cold by the time I return. Right now I use a toggle button for this but often forget to toggle the button on my way back, so a "set-and-forget" timer would help avoid that problem.

#

Countdown timer with date/time/duration picker

nocturne relic
#

Can't you just use a datetime helper? You can do stuff when now > datetime_helper (or add a bias). And if you also want to start the "low energy mode" based on that helper you could use now < datetime_helper for that.

There is no UI element for it but you can do it with template triggers:

{{ now() < states("input_datetime.test") |as_datetime |as_local }}
faint storm
#

Yeah DateTime helper looks like the closest I'm going to get.

faint storm
#

I ended up using a datetime helper, a toggle switch, and a template sensor to do it and it works well enough.