Connect Airthings devices to Evolo using MQTT

Using the Airthings MQTT Publisher, Airthings sends your measurements to Evolo.

Written By Evolo Support

Last updated 4 days ago

Once setup is complete, you can view values such as temperature, radon, CO₂, humidity, and noise in Evolo, with logging, alarms, and display options just like for all other data points.

Before you begin

To get started, you’ll need the following from Airthings:

  • An Airthings for Business account with at least one device online, and access to the MQTT Publisher in the Airthings Dashboard.

  • The serial number of each Airthings device you want to retrieve data from (displayed on the device and in the Airthings Dashboard).

  • Access to User → Integrations in Evolo to create an MQTT key.

1. Enable MQTT and create a key in Evolo

Go to Configuration → Gateways:

  1. Open the gateway you created, check Enable MQTT, and save. Note the gateway’s key, for example, C2DM-4T4Z-GA71. It will be used in the topics later.

  2. Go to User → Integrations, the MQTT tab, and click Create New MQTT Client.

  3. Give it a name, select the “Write MQTT” access type, select “Built-in,” and click “Create.”

  4. Copy the username (UUID) and the token. The token is displayed only once, and you’ll need both in Airthings later.

2. Add Airthings as a device in Evolo

Go to Configuration → Devices

  1. Add a new device, for example, “Airthings.” Enter mqtt.evolo.no as the IP address/hostname. This field is required but is not used to connect to anything for this type of device.

  2. Add an interface to the device with the type MQTT Incoming. No other settings are needed.

All Airthings devices in the building can be connected behind this single interface. The serial number in the topic of each data point determines which physical device the value comes from.

3. Add data points

Add one data point per measurement you want to read, for each Airthings device. The data points for a single physical device use the same topic but different expressions. Feel free to include the room or device name in the label, for example, “Room 109 Temperature”:

Field

Value

Name

For example, “Temperature”

Topic

airthings/2930123456/sample

JavaScript to read value

return message.temp;

Expressions for the most common measurements

Measurement

Expression

Unit

Temperature

return message.temp;

°C

CO₂

return message.co2;

ppm

Humidity

return message.humidity;

%

Radon (short-term)

return message.radonShortTermAvg;

Bq/m³

Volatile Organic Compounds (VOC)

return message.voc;

ppb

Air pressure

return message.pressure;

hPa

Particulate matter PM2.5

return message.pm25;

µg/m³

Light

return message.lux;

lux

Noise level

return message.soundLevel;

dBA

Import from Excel

If you have many devices, you can import the data points from Excel.

Select Import → MQTT Inbound in the data point list and download the template. The template contains pre-filled rows for the Airthings measurements; copy the rows for each device, replace the serial number in the “topic” column, and enter the interface ID. All rows can point to the same interface.

Add a data point for temperature

4. Set up the Airthings MQTT Publisher

In the Airthings Dashboard, under Integrations → MQTT Publisher, create a connection to Evolo:

Setting

Value

Broker / Host

mqtt.evolo.no

Port

8883

Protocol

MQTTS (TLS)

Username

The MQTT key's UUID from Evolo

Password

The token from Evolo

Certificates

Not required; username and password are sufficient

Event types

Samples. “Hub metadata” can be left off; it only provides the hub’s own status

Topic format

evolo/<gateway-nøkkel>/inbound/airthings/${serial_number}/${message_type}

When you save and activate the publisher, Airthings sends one test message from the serial number 0000000000. It confirms the connection but does not hit any data points and can be ignored.

5. Test

Airthings devices measure and report approximately every 5 minutes, so expect a delay of 5 to 10 minutes from when the publisher is activated until the first value appears.
Open a data point in Evolo and click “Read Data Point” to view the most recently received value. You can also subscribe to evolo/<gateway-nøkkel>/tags/# using an MQTT client and watch the values come in.

Troubleshooting

Need help? Contact your installer or our support team at support@evolo.no