Skip to main content

MQTT Module Configuration

If your device is connected to Internet via wifi or ethernet, you can enable it to forward packets along to an MQTT server. This allows users on the local mesh to communicate with users on the internet. One or more channels must also be enabled as uplink and/or downlink for packets to be transmitted from and/or to your mesh (See channels). Without these settings enabled, the node will still connect to the MQTT server but only send status messages.

The MQTT module config options are: Enabled, Server Address, Username, Password, Encryption Enabled, JSON Enabled, TLS Enabled, and Root Topic. MQTT Module config uses an admin message sending a ConfigModule.MQTT protobuf.

Settings

MQTT Module Config Values

Enabled

Enables the MQTT module.

Server Address

The server to use for MQTT. If not set, the default public server will be used.

Username

MQTT Server username to use (most useful for a custom MQTT server). If using a custom server, this will be honored even if empty. If using the default public server, this will only be honored if set, otherwise the device will use the default username.

Password

MQTT password to use (most useful for a custom MQTT server). If using a custom server, this will be honored even if empty. If using the default server, this will only be honored if set, otherwise the device will use the default password.

Encryption Enabled

Whether to send encrypted or unencrypted packets to MQTT. This parameter is only honored if you also set server (the default official mqtt.meshtastic.org server can handle encrypted packets). Unencrypted packets may be useful for external systems that want to consume meshtastic packets.

JSON Enabled

Enable the sending / consumption of JSON packets on MQTT. These packets are not encrypted, but offer an easy way to integrate with systems that can read JSON.

TLS Enabled

If true, we attempt to establish a secure connection using TLS.

Root Topic

The root topic to use for MQTT messages. This is useful if you want to use a single MQTT server for multiple meshtastic networks and separate them via ACLs.

MQTT Module Config Client Availability

info

MQTT Config options are available on iOS, iPadOS and macOS at Settings > Modules > MQTT.

Connect to the Default Public Server

1. Enable the MQTT Module

Navigate to Settings > MQTT: Turn on the slider for MQTT enabled and tap Save

MQTT Settings 1 MQTT Settings 2

Optional: To use your phone's internet connection to send and receive packets over the web, also enable the slider for MQTT Client Proxy and skip the Configure Network Settings step below.

Client Proxy

2. Enable Channel Uplink & Downlink

Navigate to Settings > Channels > Primary Channel: Turn on the sliders for Uplink enabled and Downlink enabled - Tap Save

Channel Settings

3. Configure Network Settings

Navigate to Settings > Network: Turn on the slider for WiFi enabled - Enter your SSID and PSK for your network - Tap Save

Network Settings