Zigbee last_reported not updating?

This is a head scratcher and I’m hoping someone can put me right on this. (there was no tag for last_reported)

I’m using last_reported to determine whether my temperature sensors are active.

According to the zigbee2mqtt log, HA is receiving the updates from the temperature sensors… or rather the zigbee integration is. However, in HA, the last_reported is not being updated.

I’m not sure where to go with this. Is it an issue with the zigbee2mqtt integration? With the HA integration? I’m lost with where to go forward with this one.

Grateful for thoughts and advice please.

EDIT - i’m up to date on HA and Zigbee2MQTT installations.

  • Core 2025.4.2
  • Supervisor 2025.04.0
  • Operating System 15.1
  • Frontend 20250411.0

  • Zigbee2MQTT version 2.2.1 commit: unknown
    Coordinator type
    EmberZNet
    Coordinator revision
    7.4.5 [GA]
    Frontend version
    0.9.7
    zigbee-herdsman-converters version
    23.20.1
    zigbee-herdsman version
    3.4.11



I’m no further forward on this. I can’t find any settings anywhere, or any other log entries that explain why the device reports are hitting the Zigbee2MQTT integration, but aren’t updating in HA entities.

I’m running a heating system off these sensors so this is important to me. If I have to up the reporting rate to cover for this issue, it’s going to have quite a negative effect on battery life.

Review this thread. Specifically this post to start…

Thank you for this.

I may be off the mark, but that thread concerned the lack of updating of that entity on the screen. ie. the last_reported changing in the system, but not changing on screen.

Where I’m coming from is that the update of the entity itself isn’t happening… within the actual HA “engine” … that events are coming in and showing on the Z2M logs, but the time stamps against last_reported aren’t changing.

My understanding is that when something reports… last_reported should update.

Or am I understanding this wrong? If I’ve got this wrong, then how do I achieve what I need to achieve please?

This is what I was pointing to The 4 ways templates update:

If you add relative_time like this in Developer Tools {{relative_time(states.sensor.xxxx_sensor_battery.last_reported) }}

you’ll see this status on the right This template updates at the start of each minute.

If you remove it you’ll see This template listens for the following state changed events:

OK - I observed for a while and it looks like last_reported is only updating if there is a change to that value. To me, reading this - State and state object - Home Assistant - I interpreted that as something which last_changed should be doing… but last_reported looks to be behaving that way also.

Ergo - “Time the state was written to the state machine in UTC time. This timestamp is updated regardless of any changes to the state or state attributes.” … but if the state is only being updated when there is a change, then this renders it kind of moot in this application and the only thing that is, “saving,” me is that the temperature is reporting to two decimal digits so a very small fluctuation is enough to trigger a change and thus an update.

Hmmm… a little frustrating for what I’m trying to do.

You can control the reporting from the Z2M side as well

There is an option that can be set per sensor in the MQTT payload to force sensor data update even if the data hasn’t changed. See force_update

From the Z2M side, the process described in Home Assistant | Zigbee2MQTT can be used to add a per-sensor force_update: true setting to the z2m configuration.yaml. Because only this one option is set in the file, all GUI-controlled settings remain editable. Looks like this;

  '0xa4c1384cc0c2d3c2':
    friendly_name: Washing Machine Plug
    description: ''
    homeassistant:
      power:
        force_update: true
1 Like

Reporting is set this way and the sensor does report back as scheduled. I can see the payload come back to Z2M in the Z2M logs. The issue is that the reporting doesn’t seem to make it through to HA where the automations can see it.

It didn’t like this code. It failed on the “name” line…

mqtt:
  sensor:
    - name: "Bedroom 2"
      homeassistant:
        power:
          force_update: true

In Zigbee2MQTT’s configuration.yaml, under your sensor. Not in HA’s configuration.yaml.

Ah. Thanks.

Unfortunately the situation is still the same. If the sensor reports back and the temperature hasn’t changed, then the last_reported doesn’t change. Only when the temperature actually changes does that change, and the only thing that’s doing it, is because it’s going down to two decimal points so there’s a reasonable chance that it notices a change.

Did you restart Zigbee2MQTT ?

Nope - (I just reloaded all YAML files) but I’ll try it again!

After a complete restart of HA, a packet came back because the humidity had changed, but the temperature hadn’t. Net result, the last_reported on the temperature didn’t change.

So it looks like the last_reported isn’t going to work at the level I need it to, because the last_reported will only change when there is a change to “report” to HA.

I wonder if the whole sensor has a last_reported that I can latch on to, so whenever the sensor reports, for any reason, I see the change. (doesn’t look like such a thing exists)

If you restart HA, add-ons are not restarted. You have to restart Zigbee2MQTT.

Oh! I didn’t know that. I’ll try again. Learn something new every day!

Nope. Received another report back for humidity changing and the temperature.last_reported didn’t change.

Here’s my code just in case I’ve got an indentation wrong or something…

  '0xa4c138bc7df37f3e':
    friendly_name: Bedroom 2
    temperature_calibration: 0.2
    homeassistant:
      power:
        force_update: true

Try with

'0xa4c138bc7df37f3e':
    friendly_name: Bedroom 2
    temperature_calibration: 0.2
    homeassistant:
      force_update: true

power is for power plugs.

Could also be you need to

'0xa4c138bc7df37f3e':
    friendly_name: Bedroom 2
    temperature_calibration: 0.2
    homeassistant:
      - temperature:
          force_update: true
      - humidity:
          force_update: true