Is there any way to use a changing part of the MQTT Topic as (numeric) sensor value?

I am not sure if this is possible, but can I turn these entities into one? Here is a screenshot:

I would like all GPMPxxxxxx entities in one GPMP sensor entity where xxxxxx is the value so that Home Assistant shows a graph of the changes to the value over time instead of creating a new entity every time the value changes. (preferably only where the response is “ACK”)

Sorry if this is already documented somewhere, but i found nothing.

Hello Emanuel Loos,

Most applications including HA assume if the MQTT topic changes, the device is changing. Data should be what the topic provides, and the topic should be an identifier of that data.

If there is no way to control the source, you will need to stop the auto-discovery on that device and do your own code in your own sensor to decode that.

2 Likes