PortScan › Port guide › Port 1883

Port 1883 (MQTT): How an Anonymous Broker Hands Your Smart Home to Strangers

TCP 1883MQTTVideo & IoTExposure risk: High

Port 1883 is MQTT, the IoT message broker. If anonymous, one # subscription reveals every sensor and lets anyone flip lights and plugs. Mosquitto auth, ACLs, TLS.

What is port 1883?

MQTT is a lightweight protocol that small devices — sensors, smart plugs, lights — use to exchange messages. It was created at IBM in 1999 and is now an OASIS standard (3.1.1, 5.0). Port 1883 is plaintext; port 8883 is TLS-encrypted.

It follows a publish–subscribe model. Devices publish values to a central broker (Mosquitto, EMQX, etc.) under topics such as home/livingroom/temp, and whoever needs them subscribes to those topics. Commands are sent as topics too. In other words, anyone who can connect to the broker can read the state of every device and send commands to every device.

Home smart setups — Home Assistant, Zigbee2MQTT, smart plugs flashed with Tasmota firmware — often run their own Mosquitto broker. Port-forwarding 1883 to use it from outside is the most common way things go wrong.

When it is normally open

Risks if it is open

Anonymous brokers and the # subscription

MQTT supports wildcard subscriptions. Connect to an unauthenticated broker and subscribe to #, and every message on every topic passing through that broker pours in live. If occupancy sensors, door sensors or location data are in the mix, even the hours your home sits empty are revealed. Subscribing to $SYS/# also shows the broker version and the number of connected clients.

Strangers can control your devices

It is not just reading. A Tasmota plug, for example, turns off when OFF is sent to the cmnd/devicename/POWER topic. If the broker allows anonymous writes, anyone can operate relays for lights, boilers or garage doors.

Plaintext transport

Port 1883 has no encryption, so even with a password set, the credentials travel as-is in the CONNECT packet. A broker reachable across the internet must use 8883 (TLS).

Already indexed by search engines

Security researchers have repeatedly found large numbers of anonymous MQTT brokers open on the internet and reported exposed smart home and industrial data. Port 1883 is one that IoT-hunting scanners sweep by default.

Security checklist

How to check whether port 1883 is open

From outside (is it exposed to the internet?)

Whether your server or home router accepts port 1883 from the internet can only be confirmed by connecting from outside. A check from inside the same network bypasses the router's firewall and gives a different answer.

PortScan opens a real TCP connection from the Cloudflare edge and reports Open, Closed or Filtered. Members can scan every port on their own IP for free and other targets free once a day.

Check port 1883

On the server (what is listening?)

Windows (PowerShell):

netstat -ano | findstr ":1883 "
Get-NetTCPConnection -LocalPort 1883 -State Listen | Select LocalAddress,OwningProcess

Linux:

sudo ss -tlnp | grep ':1883 '

If it listens on 0.0.0.0 or [::] it is open on every network; 127.0.0.1 means only that machine can connect. To test port 1883 on a server from another computer, use Test-NetConnection server-address -Port 1883 on Windows or nc -vz server-address 1883 on Linux and macOS.

How to close or restrict port 1883

The best fix is to turn the service off or make it listen only on 127.0.0.1 (see the checklist above). If you need the service but must keep it off the internet, use a firewall.

Windows Firewall

# Administrator PowerShell
New-NetFirewallRule -DisplayName "Block TCP 1883" -Direction Inbound -Protocol TCP -LocalPort 1883 -Action Block
# To allow a single IP instead (block rules take precedence, so use this instead of the rule above)
New-NetFirewallRule -DisplayName "Allow TCP 1883 from office" -Direction Inbound -Protocol TCP -LocalPort 1883 -RemoteAddress 203.0.113.10 -Action Allow

Linux (ufw)

sudo ufw deny 1883/tcp
# Allow a single IP only
sudo ufw allow from 203.0.113.10 to any port 1883 proto tcp

On a cloud server, also check port 1883 in the security group (inbound rules), which is separate from the OS firewall. For services running in Docker, the rules Docker creates can bypass ufw, so binding the port to localhost with -p 127.0.0.1:1883:1883 is the reliable option.

Router

At home or in a small office, open the router's admin page and check whether port 1883 is in the port forwarding list, whether DMZ is enabled, and whether any program opened ports by itself through UPnP. If any of the three applies, port 1883 on your PC is directly visible from the internet.

How to read the scan result

The verdict can depend on where you connect from. Many ISPs (including most Korean ISPs) block some ports such as 135, 139 and 445 on their network, so the same server can look Filtered from inside that network and Closed from abroad.

FAQ

Port 1883 is closed but 8883 is open. Is that fine?
It is better than 1883 because traffic is encrypted with TLS. But encryption and authentication are separate things. If 8883 also allows anonymous access, anyone can connect — securely, over TLS(!) — and subscribe to #. You still need authentication and ACLs.
Should I check MQTT over WebSocket ports too?
Some setups open a separate WebSocket listener for browser dashboards. The port number varies by configuration, so check every listener entry in the broker's config file and make sure the same authentication rules apply.
8883 MQTT (TLS)8123 Home Assistant554 RTSP (IP cameras / CCTV)

Last updated 2026-11-04 · Use this guide to check systems you manage. Scanning systems without permission may carry legal liability.