Zigbee2MQTT dashboard on iPhone and iPad

Updated

Show your Zigbee sensors and control lamps and plugs from a dashboard on your iPhone or iPad. Zigbee2MQTT already publishes every device to your MQTT broker, and Routix Dash connects to that broker directly. No extra software is needed.

You need a running Zigbee2MQTT and the address of the MQTT broker it uses.

Zigbee2MQTT topics in short

Each device publishes its state as JSON to zigbee2mqtt/ followed by its friendly name. The examples use a sensor named Bedroom sensor and a lamp named Desk lamp.

Topic What it carries
zigbee2mqtt/Bedroom sensor Readings, for example {"temperature": 21.4, "humidity": 48, "battery": 97}
zigbee2mqtt/Desk lamp State, for example {"state": "ON", "brightness": 180}
zigbee2mqtt/Desk lamp/set A command, for example {"state": "OFF"}

1. Connect Routix Dash to the broker

Open the menu → MQTT connections → Add MQTT connection. Enter a Name, the broker's Host and Port, and the user name and password if it needs them. Tap Test, then the save tick.

2. Show a sensor

Create a data source: menu → Data sources → Add data source. Set Data source type to MQTT, choose the connection, and set Topic filters (subscribe) to zigbee2mqtt/Bedroom sensor. Save.

On a data section, tap Add data piece manually and pick Design your own data piece. Set the new source as the root data source.

Add one Label per reading. On each Label, turn Inherited off and add a Simple expression transformer under Data transformers pipe:

For a gauge, add a Dial gauge and set Default value to {{ value.temperature }}.

3. Switch a lamp

Create a second MQTT data source for zigbee2mqtt/Desk lamp. In a new data piece that uses it, add a Toggle:

Under Events → On tap, a new Toggle already has Apply value. It flips 1 and 0, so tap it and change Value to {{ value == "ON" ? "OFF" : "ON" }}: the toggle then flips between ON and OFF.

Then tap Add... below it, choose MQTT send, pick the connection and set:

Save. The toggle switches the lamp, and it follows the lamp when you switch it somewhere else.

4. Dim it

Add a Slider to the same data piece:

Under Events → On changed, add MQTT send with the same topic and the Payload {"brightness": {{ value }}}. The lamp changes when you let go of the handle.

Tips

Read more