State history for number entities

I have a Xiaomi Air Purifier, which comes with two number entity built in through the Miio integration.
One is fan level which has the levels 1, 2 and 3. The other is Favorite Mode, which has the levels 1 and to 17.

I was wondering if it was possible to log previous levels a number entity has been adjusted to?

You could add the number entity to a history graph card.

I think the issue is that the state is not being recorded.

But you made me realize that it is probably because I don’t have the type as an included domain in my recorder settings.

Would adding number to the below solve that?

recorder:
  purge_keep_days: 10
  auto_purge: true
  db_url: !secret db-url
  commit_interval: 60
  include:
    domains:
      - sensor
      - binary_sensor
      - switch
      - automation
      - light
      - media_player
      - updater

Yes it would.

Thank you!

1 Like