# Homey MQTT broker & suscriber (node-red)

**URL:** <https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437>\
**Category:** Questions & Help\
**Created:** [September 9, 2018, 4:04pm UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437 "2018-09-09T16:04:49Z")\
**Posts on this page:** 16\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jose\_Lorca](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jose_lorca/32/941_2.png) [@Jose\_Lorca](https://community.homey.app/u/Jose_Lorca)\
**Post date:** [September 9, 2018, 4:04pm UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/1 "2018-09-09T16:04:49Z")

</div>

hi dears,

im trying to use the Hemy like MQTT broker to share information with my oters devices (Raspberry pi 3 with node-red) in order to learn and “play” with this data.

![imagen](https://us1.discourse-cdn.com/flex025/uploads/athom/original/1X/6e15d14042c1ccdcda04e8527dce8d7387a55e27.png)

after many mistakes with the ports (1183 instead 1883 LOL)

Eureka… my node-red was connected to my Homey  
 ![232](https://us1.discourse-cdn.com/flex025/uploads/athom/original/1X/ec855da65ac2a098dc76d089961d0a94a4ccc5ae.png)

but… and now that??  
node is suscribed and sent the birth message but no menssages from homey to Node  
i has one folder in homey named Doors and nothing from Homey

maybe one beginers manuals to use the MQTT borker??

thanks in advance

---

<div class="post-metadata">

**Author:** ![robertklep](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/robertklep/32/160628_2.png) [@robertklep](https://community.homey.app/u/robertklep)\
**Post date:** [September 9, 2018, 4:20pm UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/2 "2018-09-09T16:20:02Z")

</div>

Homey _itself_ doesn’t use MQTT at all, so the broker is “only” useful if you need to run an MQTT broker for devices that use it (like the Sonoff Tasmota devices) and don’t have an always-on computer to run that broker on.

Which _does_ give me a new app idea: an app that broadcasts all realtime data from Homey over MQTT, like capability changes, new/deleted devices, and whatever else.

---

<div class="post-metadata">

**Author:** ![Jose\_Lorca](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jose_lorca/32/941_2.png) [@Jose\_Lorca](https://community.homey.app/u/Jose_Lorca)\
**Post date:** [September 9, 2018, 4:34pm UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/3 "2018-09-09T16:34:34Z")

</div>

bad news for me…

and then how can i serve the data (temperatature for example) to others? or MQTT?

BR

---

<div class="post-metadata">

**Author:** ![robertklep](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/robertklep/32/160628_2.png) [@robertklep](https://community.homey.app/u/robertklep)\
**Post date:** [September 9, 2018, 4:46pm UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/4 "2018-09-09T16:46:24Z")

</div>

You can use the [MQTT client](https://apps.athom.com/app/nl.scanno.mqtt) app as part of a flow that will publish changes over MQTT.

---

<div class="post-metadata">

**Author:** ![Robin\_van\_Kekem](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/robin_van_kekem/32/8187_2.png) [@Robin\_van\_Kekem](https://community.homey.app/u/Robin_van_Kekem)\
**Post date:** [September 10, 2018, 8:26am UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/5 "2018-09-10T08:26:55Z")

</div>

I’m afraid you need to read a little about a broker and a client.

[https://www.hivemq.com/blog/mqtt-essentials-part-3-client-broker-connection-establishment](https://www.hivemq.com/blog/mqtt-essentials-part-3-client-broker-connection-establishment)  
You could read them there.

I’v got Homey working as a client, Node Red as a client and an Docker image as MQTT broker.  
I use it to send data (like sensors temp data) via MQTT to a SQL database which is then plotted to a nice graph using Grafana.  
Also build my custom dashboard for use on a tablet in Node Red dashboard.

---

<div class="post-metadata">

**Author:** ![Jose\_Lorca](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jose_lorca/32/941_2.png) [@Jose\_Lorca](https://community.homey.app/u/Jose_Lorca)\
**Post date:** [September 10, 2018, 8:52am UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/6 "2018-09-10T08:52:13Z")

</div>

i’ll read and try it

Homey as a client, node as broker and use simple dashboard

thank you so much

---

<div class="post-metadata">

**Author:** ![Robin\_van\_Kekem](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/robin_van_kekem/32/8187_2.png) [@Robin\_van\_Kekem](https://community.homey.app/u/Robin_van_Kekem)\
**Post date:** [September 10, 2018, 8:55am UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/7 "2018-09-10T08:55:46Z")

</div>

Node red can also act like a broker.  
Install the MQTT Musquito client on Homey and use the same topics to send and receive data to and from Homey.  
I used this client: [https://apps.athom.com/app/nl.scanno.mqtt](https://apps.athom.com/app/nl.scanno.mqtt)

---

<div class="post-metadata">

**Author:** ![xAPPO](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/xappo/32/13726_2.png) [@xAPPO](https://community.homey.app/u/xAPPO)\
**Post date:** [September 10, 2018, 11:40pm UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/8 "2018-09-10T23:40:13Z")

</div>

> [@robertklep](#):
>
> Which _does_ give me a new app idea: an app that broadcasts all realtime data from Homey over MQTT, like capability changes, new/deleted devices, and whatever else.

Interested… particularly if I can update device capabilities too via MQTT

---

<div class="post-metadata">

**Author:** ![robertklep](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/robertklep/32/160628_2.png) [@robertklep](https://community.homey.app/u/robertklep)\
**Post date:** [September 11, 2018, 6:36am UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/9 "2018-09-11T06:36:40Z")

</div>

> [@xAPPO](#):
>
> Interested… particularly if I can update device capabilities too via MQTT

Have to look closer, but from first looks it seems that not all sensor data is being “broadcast” in realtime.

That said, updating device capabilities should be easy to implement.

---

<div class="post-metadata">

**Author:** ![cnoork](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/cnoork/32/13596_2.png) [@cnoork](https://community.homey.app/u/cnoork)\
**Post date:** [November 30, 2018, 8:33pm UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/10 "2018-11-30T20:33:27Z")

</div>

Hi, I am also interested to pass all data from Homey to mqtt broker. Currently I add in some flows the MQTT Client to send a message in a topic, this is not really manageable with 30+ devices.

---

<div class="post-metadata">

**Author:** ![Marlon](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/marlon/32/3794_2.png) [@Marlon](https://community.homey.app/u/Marlon)\
**Post date:** [December 1, 2018, 9:37am UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/11 "2018-12-01T09:37:16Z")

</div>

You could run node-red on a docker image on your NAS (if you have one). It is also possible to install a MQTT broker in node-red. For an example of an MQTT broker installation in node-red take a look [here](http://www.steves-internet-guide.com/install-mosca-mqtt-broker-node-red/)

---

<div class="post-metadata">

**Author:** ![cnoork](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/cnoork/32/13596_2.png) [@cnoork](https://community.homey.app/u/cnoork)\
**Post date:** [December 1, 2018, 2:51pm UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/12 "2018-12-01T14:51:24Z")

</div>

Hi Marlon, that is what I am running already, Mosquitto, Node-Red with Influx database and Grafana are already running in docker on my NAS. What I am looking for is an easy way to get all messages with mqtt instead that I have to create many extra flows to get the info. So connection which transfer all messages to mqtt.

---

<div class="post-metadata">

**Author:** ![Marlon](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/marlon/32/3794_2.png) [@Marlon](https://community.homey.app/u/Marlon)\
**Post date:** [December 1, 2018, 3:19pm UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/13 "2018-12-01T15:19:18Z")

</div>

I see your point. I don’t know if what you want is possible with mqtt and node-red.

Maybe worth checking out is the [Prometheus exporter app](https://apps.athom.com/app/io.prometheus) for Homey (Beta). I haven’t used it yet, though. (Still on my todo list) As an added bonus, Grafana supports querying Prometheus. Take a look a the info [here](https://prometheus.io/docs/visualization/grafana/)

---

<div class="post-metadata">

**Author:** ![Tangodelta](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/tangodelta/32/9471_2.png) [@Tangodelta](https://community.homey.app/u/Tangodelta)\
**Post date:** [January 1, 2020, 6:45pm UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/14 "2020-01-01T18:45:51Z")

</div>

Status?

---

<div class="post-metadata">

**Author:** ![robertklep](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/robertklep/32/160628_2.png) [@robertklep](https://community.homey.app/u/robertklep)\
**Post date:** [January 1, 2020, 7:52pm UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/15 "2020-01-01T19:52:42Z")

</div>

Current status: I stopped using Homey entirely almost a year ago. But take a look at the MQTT Gateway/Hub app.

---

<div class="post-metadata">

**Author:** ![Tangodelta](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/tangodelta/32/9471_2.png) [@Tangodelta](https://community.homey.app/u/Tangodelta)\
**Post date:** [January 1, 2020, 7:55pm UTC](https://community.homey.app/t/homey-mqtt-broker-suscriber-node-red/1437/16 "2020-01-01T19:55:15Z")

</div>

yes, that`s the problem. Hub dosen`t support “local and presence” (Owntracks), so no topics.
