Template Time Sensor

I am looking to create a template sensor with multiple time brackets in a day to label that time bracket.

I.E.

5-6PM Dinner time
6-7pm Kids time
8-10pm Parents time
etc

Depending on the state of this template sensor use it as conditions to automations

How ever the document say using Now() for time will trigger a re-read every minute. Is this a bad idea and should I consider another way?
or
Would it be ok to have multiple if statements to do this in a template senor?

There are a number of options described in this thread:

If you are worried about performance, you can always use a trigger-based template sensor to throttle how often the templates are rendered. For this case you could use something like the following to cover the necessary bases:

template:
  - trigger:
      - platform: time_pattern
        hours: "/1"
      - platform: homeassistant
        event: start
      - platform: event
        event_type: event_template_reloaded
    sensor:
      - name: .....
template:
  - trigger:
      - id: Dinner time
        platform: time
        at: '17:00:00'
      - id: Kids time
        platform: time
        at: '18:00:00'
      - id: Parents time
        platform: time
        at: '20:00:00'
      - id: Nothing 
        platform: time
        at:
          - '00:00:00'
          - '18:00:00'
          - '22:00:00'
    sensor:
      - name: whatever
        state: '{{ trigger.id }}'
1 Like