Setting Remote Desktop to an Alternate Port

The default port for Remote Desktop is 3389, but there are cases where it is useful to change this port, for example on the external interface of a firewall should you be providing remote support of said firewall. These steps are known to work on Windows XP and Windows Server 2003. They have not been tested by me on other versions of Windows.

On the Remote Desktop Server

    1. Start Registry Editor (Regedt32.exe).
  • Locate the following key in the registry:HKEY_LOCAL_MACHINE\ System\ CurrentControlSet\ Control\ TerminalServer\ WinStations\ RDP-Tcp\ PortNumber
  • On the Edit menu, click Modify, click Decimal, type the new port number, and
    then click OK.


  • Quit Registry Editor.



On the Client

    1. Click Start, click All Programs, point to Accessories,
      point to Communications, and then click Remote Desktop Connection.
  • In the Computer box, type the computer name or IP address of the
    computer to which you want to connect, followed by a colon (:) and the port
    number you want to use.For example, to connect to port 3390 on a computer named “MyXPPro,”
    type the following information: MyXPPro:3390

    To connect to port 3391 on a computer with IP address,
    type the following information:


More information at;en-us;306759







6 responses to “Setting Remote Desktop to an Alternate Port”

  1. Kevin Lewis avatar

    Did you know the Windows Server Administration Tools Pack provides a new MMC plugin to easily manage multiple servers, and also supports accessing servers on alternate RDP ports.

  2. Remote Support avatar

    Its so highly informative things are posted in your blog. I was seeking for this type of blog only and also that you have a fresh and interesting content.
    Web Conference

  3. Tina avatar

    Do you know if this works in Windows 7? I’ve been trying to get this to work there and haven’t had much luck.

    I opened up port 12394 on my router that points to the local IP address of the machine I want to connect to from a remote location. I’ve also pointed that port in the registry settings for RDP.

    On the machine I use from my remote location, I then type the IP address to the firewall followed by a colon, followed by the new port number. I get a generic “can’t connect” message.

    If I do the exact same thing with a Windows XP machine, no problems.

  4. matt avatar

    Check your firewall exceptions. Windows FW configuration has changed dramatically in Win7 and may require a bit more tweaking than before. Start by disabling to test yiour config, then turn it back on and work from there to open the port you are using.

  5. maximo avatar

    Great! This is a very useful information. I am in charge with the IT department in our company and I always do remote access whenever I need files back home.

    assistenza computer

  6. Cory Buckholz avatar

    Here is a good hypothetical for you:

    Say I have a server with 2 internal I.P. address of and and my current port forwarding configuration on my router is to have port 3389 (Default port) point to if I enter as the address. If I change my registry value to allow the alternative port and set my port forwarding over to have point to will this disable the default port? Can I have 2 ports for 2 simultaneous connections on one machine with 2 I.P. addresses?

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.