Energy dashboard displays "No statistics" despite working utility meters

So thanks to this Github issue I have been able to solved it: the unit is case sensitive, and I has using wh instead of Wh. From Zyta2002’s comment the db has to be updated:

  1. Stop HA
  2. Open the DB using sqlite3: sqlite3 home-assistant_v2.db
  3. SELECT * FROM statistics_meta GROUP BY id (check the sensor which doesnt appear in energy-settings)
  4. UPDATE statistics_meta SET unit_of_measurement="kWh" WHERE id=xx (<-- the id of the sensor)
  5. Start HA

Then I also had to update the case for the sensors unit, which is declared through MQTT discovery.

7 Likes