# MQTT Pub and Sub

MQTT Pub and Sub is a self-hosted databases app. Unraid plugin that lets you publish messages to and subscribe to topics on an MQTT (Message Queuing Telemetry Transport) broker. It is open source and self-hosted, installable on Unraid.

Canonical page: https://ourlocalhost.com/app/4349/mqtt-pub-and-sub

## Description

Unraid plugin that lets you publish messages to and subscribe to topics on an MQTT (Message Queuing Telemetry Transport) broker.

## Platform availability

Available on 1 of 10 platforms: Unraid.

## Health score

11/100 (Low), based on 3 of 4 factors.
- Maintained: 0 (last commit 746 days ago)
- Popular: 18 (7 GitHub stars)
- Easy to install: 25 (1 install platform, install notes)

## Links

- Unraid: https://ca.unraid.net/apps/mqtt-pub-and-sub-0wr3vgd13qb4w9?q=MQTT%20Pub%20and%20Sub
- GitHub: https://github.com/giganode/unraid-mqtt-pub-sub

## Common questions

### How do I install MQTT Pub and Sub on Unraid?

Install it from Plugins > Install Plugin, or from the Community Apps plugin.

### Can I configure the plugin before an MQTT broker is reachable?

No, you need a reachable MQTT broker such as Mosquitto before configuring publish or subscribe topics.

### Where should I store broker credentials for Unraid scripts?

Enter the MQTT credentials under Settings > MQTT. Scripts can then source /boot/config/mqttcredentials and use variables such as MQTT_HOST, MQTT_PORT, MQTT_USER, MQTT_PASSWORD, and MQTT_CLIENT_ID.

### Can I perform float calculations in scripts used with the plugin?

Yes, the plugin includes bc, which is useful for float calculations in bash scripts.

### Will missed messages be queued for a later subscriber?

No, MQTT pub/sub is not message queuing. Retained messages can be held by the broker and sent to later subscribers.

---
Source: Our Local Host (https://ourlocalhost.com/app/4349/mqtt-pub-and-sub), the self-hosted and open-source app directory.
