It would be much appreciated if someone could tell me the settings to run Mosquito MQTT and Thingsboard with Thingsboard IoT-gateway on the same server.

Mosquito is receiving on port 1883 which is working. Were do I need to configure the ports (must be different, right?) between IoT-Gateway and Thingsboard and how do I configure IoT-Gateway that it is connecting to Thingsboard?

The Thingsboard documentation is not helping here.

  • 3
    Can't you change port of Mosquito, instead ?
    – Bhushan
    Commented May 11, 2018 at 9:51
  • It is also about the communicatios between gateway and thingsboard.
    – Frank
    Commented May 11, 2018 at 21:45
  • Which ports are you trying to configure? Why? A port is only an issue when its on the same IP address, eg if you had two mosquitto servers on one ip address, then you would need to use different port for one of them.
    – Trevor
    Commented Sep 5, 2018 at 12:38
  • Which Documentation you are following, please update it in question for more clarity. Thanks Commented Dec 27, 2018 at 4:28

1 Answer 1


You can Configure Mosquito MQTT and Thingsboard IoT-gateway on the same host by configuring the MQTT port different for both the application. Below is a sample configuration which uses default port for Mosquito MQTT (i.e 1883) and port 1893 for Thingsboard IoT-gateway, also you need to configure all Thingsboard device to new port 1893

Host Configuration

Configuring ThingsBoard IOT The configuration file is located in the installation folder for Windows and /etc/tb-gateway/conf for Linux host.

Open the tb-gateway.yml in you favorite text editor and change value of port (under gateways:, tenents:, connection:) to 1893 save the file and restart the Thingsboard IOT server, also note change all ThingsBoard device to use the new port 1893

This is the link to the ThingsBoard Document

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.