MQTT • NODE-RED

How MQTT JSON payloads work in Node-RED

A common industrial pattern is MQTT input → JSON parsing → Function processing → another output such as MQTT, a database or a dashboard.

Typical flow

MQTT In → JSON → Function → MQTT Out

If the MQTT message arrives as a JSON string, a JSON node can convert it into an object. The Function node can then use expressions such as msg.payload.temperature.

Always inspect a real MQTT message before designing the downstream logic because payload formats vary between devices and vendors.