Port reference › Remote access

Port 5986 · WinRM (HTTPS)

Encrypted Windows Remote Management

TCP Remote access Exposure risk: Medium

What is port 5986 used for?

WinRM over HTTPS, for certificate-protected PowerShell remoting.

Registered port (1024-49151): the range used by ordinary applications.

Security notes

It is an admin port — limit it to management IPs.

Allow port 5986 through the firewall

This port is risky to expose, so the commands below allow only the IPs you specify.

# Replace 203.0.113.10/32 with the IP or network you want to allow
sudo ufw allow from 203.0.113.10/32 to any port 5986 proto tcp
sudo ufw status

Check whether port 5986 is open

sudo ss -tlpn | grep ':5986 '

Ports used together

Other remote access ports

22 SSH 2222 SSH (alternate port) 23 Telnet 3389 RDP 5900 VNC