Time template issues - Making time look nice

Hi all

I had my time template all ok, I did a update and there was a change to the templates and having to assign and entitiy ID, I modified this and seemed to be working but now my time template doesn’t update ?
any thoughts ?

here is my code

  - platform: time_date
    display_options:
      - 'time'
      - 'date'

  - platform: template
    sensors:
      template_date:
        entity_id: sensor.template_date
        value_template: >-
          {{now().strftime("%A")}}, {{now().strftime("%d")}} {{now().strftime("%B")}}

  - platform: template
    sensors:
      template_time:
        entity_id: sensor.template_time
        value_template: >-
          {{now().strftime("%I")}}:{{now().strftime("%M")}} {{now().strftime("%p")}}

My template displays perfectly as i want it to however it doesn’t update unless i reboot.

sensor.time and date work correctly however and update but the formatting inst how i want.

Can anyone help please ?

Try this:

  - platform: template
    sensors:
      template_date:
        entity_id: sensor.date
        value_template: >-
          {{now().strftime("%A")}}, {{now().strftime("%d")}} {{now().strftime("%B")}}

  - platform: template
    sensors:
      template_time:
        entity_id: sensor.time
        value_template: >-
          {{now().strftime("%I")}}:{{now().strftime("%M")}} {{now().strftime("%p")}}

You need to specify the entity id that the template uses. Not the entity id of the template.

1 Like

oh wow cant believe i missed that mistake in entity ID

Thanks Tom,m working fine now much appreciated.