Introduction: Set Up Remote Desktop Connection (RDP) on Raspberry Pi With Windows PC

This guide shows how to set up a Remote Desktop Connection with a Raspberry Pi using RDP on a Windows PC. The Remote Desktop Protocol (RDP) is the proprietary network protocol developed by Microsoft to connect to a remote desktop computer and access its graphical user interface. This allows you to connect your Windows PC to your Raspberry Pi and control its GUI remotely.

Supplies

  • You need a Raspberry Pi board.
  • Operating System: you should have a Raspberry Pi running Raspberry Pi OS (32-bit or 64-bit). The OS should have Desktop support (doesn’t work on Lite OS).
  • SSH: You should be able to establish an SSH connection with your Raspberry Pi.

Step 1: Xrdp (open-source Remote Desktop Protocol Server)

xrdp provides a graphical login to remote machines using RDP (Microsoft’s proprietary Remote Desktop Protocol). xrdp accepts connections from a variety of RDP clients. We’ll be using Microsoft Remote Desktop Client for Windows (but it’s also compatible with Mac OS, iOS, and Android).

xrdp allows you to connect to your Raspberry Pi to control its desktop remotely.

Please note that your Raspberry Pi must be running a full Raspberry Pi OS – it will not work with a headless or Lite OS.

Step 2: Installing Xrdp on Raspberry Pi (Remote Desktop Protocol)

Having an SSH connection established with your Raspberry Pi, update and upgrade your Raspberry Pi, if any updates are available. Run the following command:

sudo apt update && sudo apt upgrade -y

Next, we need to install the xrdp software on your Raspberry Pi:

sudo apt install -y xrdp

That’s it. You don’t need to change any configurations, everything will work out of the box with the default settings.

Finally, run the following command to get the Raspberry Pi IP address. You’ll need the IP address to establish the remote connection.

hostname -I


Step 3: Remote Desktop Connection Software – Windows PC

The Remote Desktop Connection software is installed on all Windows PCs by default. Click the search bar.

Search for "Remote Desktop Connection" and open the App

Type the Raspberry Pi IP address in the computer field and press the Connect button

Click the "Yes" button to establish the connection.

Next, type your Raspberry Pi username and password and click the "OK" button to login into your device.

You might be prompted one more time for the authentication if you just powered your Raspberry Pi, so enter again your username and password.

That's it! You can now control your Raspberry Pi desktop computer remotely from a Windows PC.