Entity names starting with digits

One of my integrations (Meteo France), generates Entity names which begin with numbers. For instance: sensor.78_weather_alert.

This seems to cause problems with templating.

I have solved this problem by changing the entity ID to sensor.weather_alert_78. There are helpful instructions for this here: Customizing entities - Home Assistant

Hopefully this will help someone in the future who happens to have an entity name starting with digits.

(Please make suggestions for keywords to add here to help this become findable!)

Whilst it is easier to avoid the problem, you can reference such entities in templates:

{{ states['sensor.78_weather'].state }}

Entity_id that begins with a number

1 Like