I can't see the MQTT data in home Assistant

Hello everyone
I do not know what I’m doing wrong.
Sensor created and data is not seen.


looks like an entity

Node red data
Node_red
Config node
Node_Config
Connection with mosquitto brocker is OK
MQTT Explorer
Lines in configuration.yaml file

mqtt:
  sensor:
    - name: "Watios_RST"
      unique_id: energiacasa
      state_topic: "/nuc"
      unit_of_measurement: "W"
      value_template: "{{ value_json.wtotal }}"

Don’t use leading “/” on the topic. It is not a URL path and some applications can handle it and some can’t.

What is the green node on your NodeRed flow? Why aren’t you using the MQTT In node?

Thank you very much for the answer.
I have removed “/” and I still cannot see the data.
The W_RST node is the data read from a siemens automata, and I connect it to MQTT OUT to publish the value, with the idea of seeing it in HA-OS as a new sensor.
As a test I have used MQTT IN node to see that they work, and it works fine.


The version of home assistant, Supervisor 2022.07.0
OS 8.4
I have also tried to pass this data to HA with the nodes of (node-red-contrib-home-assistant-websocket) but in HA_OS it asks me (Node-RED Companion Integration) and I have not been able to install it. But that is another story.
Again, many thanks for the help.