Raspberry Pi: Set Up Remote Desktop Connection (RDP) – Mac OS

This guide shows how to set up a Remote Desktop Connection with a Raspberry Pi using RDP on Mac OS. 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 Mac computer to your Raspberry Pi and control its GUI remotely.

Raspberry Pi Setup Remote Desktop Connection RDP Mac OS

We have a similar guide for Windows PC: Raspberry Pi: Set Up Remote Desktop Connection (RDP)


Before proceeding, make sure you check the following prerequisites.

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 Mac OS (but it’s also compatible with Windows, 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.

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
Raspberry Pi IP Address

Microsoft Remote Desktop Connection Software – Mac OS

The Microsoft Remote Desktop software can be installed in the App Store. Open the App Store.

Mac OS Open App Store

Search for “Microsoft Remote Desktop” on the App Store and click the “Get” button:

Mac OS App Store search install Microsoft remote desktop

After the software is installed, click “Open“.

Mac OS Open Microsoft Remote Desktop software

Next press the “Add PC” button to set the Raspberry Pi settings.

Microsoft Remote Desktop software add PC

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

Microsoft Remote Desktop software type Raspberry Pi IP Address save

The Raspberry Pi PC will be added to your Microsoft Remote Desktop software, then click the “Connect” option.

Microsoft Remote Desktop software connect to Raspberry Pi

Click the “Connect” button to establish the connection.

Microsoft Remote Desktop software Connect

Next, type your Raspberry Pi username and password and click the “Continue” button to login into your device.

Microsoft Remote Desktop Type Raspberry Pi username password authentication

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

Raspberry Pi Authentication username and password

That’s it! You can now control your Raspberry Pi desktop computer remotely from Mac OS.

Raspberry Pi IP address RDP establish remote desktop connection Mac OS

Wrapping Up

In this tutorial, you learned a very convenient, practical, and easy way to establish a remote connection with your Raspberry Pi using xrdp. This is our favorite method to access the Raspberry Pi desktop because you don’t have to connect an additional screen, keyboard, and mouse. You can also use RDP on a Windows PC.

We hope you found this tutorial useful. You can check all our Raspberry Pi projects on the following link:

Thanks for reading.

Learn how to build a home automation system and we’ll cover the following main subjects: Node-RED, Node-RED Dashboard, Raspberry Pi, ESP32, ESP8266, MQTT, and InfluxDB database DOWNLOAD »
Learn how to build a home automation system and we’ll cover the following main subjects: Node-RED, Node-RED Dashboard, Raspberry Pi, ESP32, ESP8266, MQTT, and InfluxDB database DOWNLOAD »

Enjoyed this project? Stay updated by subscribing our newsletter!

3 thoughts on “Raspberry Pi: Set Up Remote Desktop Connection (RDP) – Mac OS”

  1. Same here, running raspi4 with 64 bit bookworm and the rdp login process from windows 10 fails immediatly after the authentification screen. The overlay in /boot/firmware/config.txt (the /boot/config.txt exist but a notice says to use the one in 3boot/firware instead) was already uncommented. Tried the the fkms variant to no avail. I will keep you posted if i find a solution.

  2. Hi.

    Can’t get this working. I have a rpizero with 32 bit os with desktop. SSH works but remote desktop gives error. Trying from a mac mini with monterey.:

    connecting to sesame on
    sesame connect ok
    sending login info to session manager.Please wait…
    login successful for user xxx on display 10
    started connecting
    connection problem, giving up
    some problem

    Error connecting to user session

    Any suggestions ?

    #TLDR: create a new user, and use that id to RDP into the RPi instead of the root user (e.g., pi@raspberrypi)

    I ran into the same issue …. I can ssh into the RPi from my MacBook Pro, but cannot RDP into it. Long story short I learnedthat RDP requires a different username than the one you’re using on the RPI. If your RPi’s root user is ‘pi’ then for some reason (probably security) you cannot also rdp in as ‘pi’; you need to create another username using the adduser command on the RPi.

    This isn’t my solution, I merely found it on the RaspberryPi forum, tried it, and it worked!

    I’ve excerpted the solution text below, and the link below that. Some additional hints at the bottom…..Hope this help!

    Re: Remote desktop connection not working, no desktop after login
    Tue Oct 25, 2022 7:47 am
    XRDP doesn’t work for root user ‘pi’, You need to create another user. The Pi root user cannot RDP for whatever reason.

    sudo adduser <username>.
    Choose password
    Confirm password
    Hit enter for defaults
    Try RDP again with that login

    I hope this helps the next person running into this!


    PS: You may find that you won’t have access to all the directories and files that the root account had. For example, opening the terminal, will show you a different user’s command prompt than what you normally see.

    After RDP-ing into the RaspberryPI, open a terminal;

    Suppose the rdp user account name is ‘new-rdp-user’; you should see the following prompt

    and the pwd ( print working directory ) command will show the new user’s home directory

    new-rdp-user@raspberrypi:~ $ pwd

    To change back over to the root user, ‘pi’ (if that was the original root user),

    use the ‘su ‘ command to use that user’s login

    new-rdp-user@raspberrypi:~ $ su pi
    pi@raspberrypi:/home/new-rdp-user $

    But here, you can see the directory did not change … it’s still in the new user’s home # directory so just type ‘cd’ followed by [Enter] to go to pi’s home directory

    pi@raspberrypi:/home/new-rdp-user $ pwd
    pi@raspberrypi:/home/new-rdp-user $ cd
    pi@raspberrypi:~ $
    pi@raspberrypi:~ $ pwd

    Now you should see all of the pi’s directories and files

    pi@raspberrypi:~ $ pwd

    To get out of pi’s login context, just type the ‘exit’ command

    and you’ll be back to new-rdp-user’s user prompt – hope this helps 🙂


Leave a Comment

Download Our Free eBooks and Resources

Get instant access to our FREE eBooks, Resources, and Exclusive Electronics Projects by entering your email address below.