MQTT connection

What is MQTT?

MQTT (Message Queuing Telemetry Transport) is an asynchronous and decoupled communication protocol that uses the publish / subscribe paradigm (like Twitter, for instance).

Publish/subscribe model

It is an asynchronous and decoupled communication paradigm. Subscribers (receivers) subscribe to topics and publishers (senders) publish messages on topics. The broker manages the topics: when a topic receives a message it is sent to all its subscribers. The topics allow a decoupling between publisher and subcriber.

Figure 1 - Example of communication between publishers and subscribers

Public MQTT broker

Here you can find a list of free and paid public MQTT brokers

Public MQTT brokers list updated on November 2021

Name Broker address TCP port

EMQ X 1883

HiveMQ 1883

Teserakt 1883 (*)

Fluux 1883 (*)

(*) not working

Here's how to configure your test MQTT broker

Set the broker (server) domain name:

Set the port number:


Set the input topic:


Set the output topic:


Store the configuration:

] save

Connect to the broker

Connect to the Wi-Fi router first:

] wifi=1



and wait for it to connect.

Wi-Fi connecting ...


Wi-Fi connected to 'Telekom-59086450' with IP:


After the connection there is an automatic connection to the NTP Server to update the calendar.

NTP connection to '' ...

NTP update of date and time: 19-04-2019 13:21:50

Then connect to the broker MQTT:

] mqtt=1



and wait for it to connect.

MQTT connection to ...

user: , client-ID: Smick-3448534573

subscribe to: in

publish on: out


MQTT connected to


< Conn


Sending the Conn message indicates that the connection has been made.