Network Windows Windows Server

How to change the default RDP port in Windows

rdp4

Remote Desktop Protocol is used by Windows users to connect remotely to another computer. By default, the RDP port is 3389 and sometimes you may want to change this port and assign another port for the RDP. If you want to read more on Remote Desktop Protocol you can check these: if you are having RDP connection How to Resolve Microsoft RDP Connection Black Screen if the account is not authorized The connection was denied because the user account is not authorized for remote login: How to add and remove Remote Desktop Users, How to allow saved credentials for RDP connection, when you are having licensing issue What to do when your Remote Desktop Licensing Manager Server Crashed.

Here are some more guides you may be interested in: Remote Desktop cannot find the computer this in the specified network: Verify the computer name and domain that you are trying to connect, Error 0x204: How to fix Remote Desktop Connection issues if you want to view or remove RDP History How to view Remote Desktop connection history or remove server connection entries from RDP. In this guide, we will be using the Registry Editor to make the changes to the RDP port, but you have to be very careful when you are using the Registry Editor because if not handled properly can cause permanent damage to the system.

But why do we want to change the default RDP port? Everyone knows that Microsoft uses the standard port 3389 for all remote connections and this is to the bad actor’s advantage because they are always trying to access people’s systems without their knowledge. So changing this default port to another open port will make it very hard for an attacker to easily break into your system.

  1. Open the Registry Editor
image-16
Registry Editor

You can also run the regedit command.

image-17
regedit

2. Browse to this key KEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Terminal Server\WinStations\RDP-Tcp

image-18
Registry Editor

3. Click on the PortNumber and click Decimal option button. In the Value data field enter the new port number and click OK to save the changes. In this guide I will be changing 3389 to 3333.

image-19
Editing PortNumber

You can confirm if the port have actually been changed using this command on PowerShell.

Get-ItemProperty -Path ‘HKLM:\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations\RDP-Tcp’ -name “PortNumber”

Run it on Windows PowerShell and you will see the RDP Port has now changed to 3333

image-20
Windows PowerShell

Another thing you will need to do is to open the ports because if you try to RDP using this port may not work at first until you open it.

If you would like to see a live demonstration of how this can be done, I have embedded a YouTube video beneath.

I hope you found this blog post on How to change the default RDP port Interesting and helpful. In case you have any questions do not hesitate to ask in the comment section.

Subscribe
Notify of
guest

0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x