# External mqtt broker

**URL:** <https://community.tago.io/t/external-mqtt-broker/1312>\
**Category:** Devices and Connectors\
**Created:** [February 13, 2023, 11:55am UTC](https://community.tago.io/t/external-mqtt-broker/1312 "2023-02-13T11:55:11Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![spulawski](https://avatars.discourse-cdn.com/v4/letter/s/e9bcb4/32.png) [@spulawski](https://community.tago.io/u/spulawski)\
**Post date:** [February 13, 2023, 11:55am UTC](https://community.tago.io/t/external-mqtt-broker/1312/1 "2023-02-13T11:55:11Z")

</div>

Hi,

I have device which communiacate with mqtt broker hosted by device manufacturer. Could I connect Tago directly to non-tago MQTT server?

Tago Have mqtt integration, but it works only for device connected with broker [mqtt.tago.io](http://mqtt.tago.io) ?

​

---

<div class="post-metadata">

**Author:** ![freddy.minuzzi](https://yyz2.discourse-cdn.com/flex034/user_avatar/community.tago.io/freddy.minuzzi/32/415_2.png) [@freddy.minuzzi](https://community.tago.io/u/freddy.minuzzi)\
**Post date:** [February 13, 2023, 2:10pm UTC](https://community.tago.io/t/external-mqtt-broker/1312/2 "2023-02-13T14:10:29Z")

</div>

Hi spulawski!

Check out [this comment](https://community.tago.io/t/connecting-devices-to-external-brokers) left by Vitor. He describes a way you can communicate to a external MQTT broker. TagoIO doesn’t natively support external MQTT brokers, You’ll need to create an Analysis that does this.

If you need further help, let us know!

---

<div class="post-metadata">

**Author:** ![spulawski](https://avatars.discourse-cdn.com/v4/letter/s/e9bcb4/32.png) [@spulawski](https://community.tago.io/u/spulawski)\
**Post date:** [February 18, 2023, 5:54am UTC](https://community.tago.io/t/external-mqtt-broker/1312/3 "2023-02-18T05:54:47Z")

</div>

Ok, using analysis as mqtt client looks interesting, so I have 2 questions:

1. Which library I can use to connect to external broker? I use: [https://www.npmjs.com/package/mqtt](https://www.npmjs.com/package/mqtt) but Tago NodeJs online can’t see this library.

2. I can execute scrip with MQTT client on server, or it should work only with external analyses?

---

<div class="post-metadata">

**Author:** ![freddy.minuzzi](https://yyz2.discourse-cdn.com/flex034/user_avatar/community.tago.io/freddy.minuzzi/32/415_2.png) [@freddy.minuzzi](https://community.tago.io/u/freddy.minuzzi)\
**Post date:** [February 20, 2023, 8:36pm UTC](https://community.tago.io/t/external-mqtt-broker/1312/4 "2023-02-20T20:36:26Z")

</div>

Hey Spulawski,

You can use any library in the analysis when in external mode and when in internal mode, all you have to do is use the web-package builder on your code before being running it at TagoIO in internal mode.

There’s a video explaining it in detail [here](https://learn.tago.io/courses/19826/lessons/19934/) at 21:00.

---

<div class="post-metadata">

**Author:** ![felipe.gutierre](https://yyz2.discourse-cdn.com/flex034/user_avatar/community.tago.io/felipe.gutierre/32/1596_2.png) [@felipe.gutierre](https://community.tago.io/u/felipe.gutierre)\
**Post date:** [June 25, 2026, 4:30pm UTC](https://community.tago.io/t/external-mqtt-broker/1312/5 "2026-06-25T16:30:28Z")

</div>

Quick update regarding the Learning Center, it is now TagoIO Academy - please, access using this link [Academy | TagoIO](https://tago.io/academy)
