Skip to content
Protocols

MQTT

A lightweight publish-subscribe messaging protocol over TCP in which devices send messages to topics on a broker, which forwards them to interested subscribers.

MQTT was designed for unreliable, low-bandwidth links and has become the default way IoT devices talk to platforms. A client opens one long-lived TCP connection to a broker, publishes messages to hierarchical topics such as site1/line2/temp, and subscribes to the topics it cares about. The broker handles fan-out, so a sensor never needs to know who is listening.

Small fixed headers keep overhead low, three QoS levels let each message choose between speed and delivery guarantees, and features such as retained messages and last will handle the realities of devices that drop offline. The main trade-off is the broker itself: it is a central component that must be sized, secured and made highly available. MQTT 5 added properties, shared subscriptions and reason codes. See MQTT explained.

Part of the IoT Glossary. Spotted an error or a missing term? Tell us.