Jewish calendar sensor triggers when time matches now()

What is the best way to set a trigger for time based automations based on the Jewish Calendar integration? The time sensor states are represented as ISO8601 formatted UTC time

At the moment I am using template triggers. For example to trigger when it is tset hakochavim I use the following template. The calue of the sensor is 2025-05-12T16:58:00+00:00

{{  (states('sensor.jewish_calendar_t_set_hakochavim') | as_timestamp)| timestamp_custom("%H:%M") == as_timestamp(now()) | timestamp_custom("%H:%M") }}

Is there a better way to do this? This works its just a pain to keep doing this for automations and I was wondering if there is a cleaner way

@tsvi Do you have any suggestions or best practices here?

If the sensor’s device_class is timestamp then you can simply use a Time Trigger.

alias: example 
triggers:
  - trigger: time 
    at: sensor.jewish_calendar_t_set_hakochavim
conditions: []
actions:
  ... etc ...

I missed that option in the settings. Thanks

1 Like

Yes, thanks @123 for pointing it out.

Up until about a year ago you had to do something like what you suggested in the OP.

@123 's suggestion is currently the recommended way. Note, that you can also have offsets in the time trigger so you can do stuff 5 min before or after.

What happened a year ago?

FWIW, the ability to specify a datetime sensor for a Time Trigger was added by Paulus in late 2020.

You’re right. I was thinking about this part:

Allowing the user to add an offset in addition to the time trigger.

1 Like