Protocols·4 / 4

MQTT - the IoT messaging protocol

~5 min read

MQTT is a lightweight publish/subscribe protocol perfect for low-power devices. A central 'broker' (e.g. Mosquitto) routes messages between publishers and subscribers.

import paho.mqtt.client as mqtt
client = mqtt.Client()
client.connect('broker.hivemq.com', 1883)
client.publish('home/livingroom/temperature', '22.3')

Made with Emergent