How to access your Raspberry Pi remotely over the internet

I run a lot of Raspberry Pi devices at home. My fully open sourced 3D printer, Prusa i3 Mk2, is managed via Raspberry Pi, a couple of security cameras powered by Raspberry Pi, an irrigation system, and more.

However, it becomes tricky to access these devices when I’m not at home, or on the local network. Since 2016, Raspbian included a VNC server, which allowed for limited functionality to access Pi remotely through VNC.

The VNC server is powered by RealVNC, and yesterday RealVNC announced a free VNC solution for Raspberry Pi users. That means Pi users will get access to many features that are paid on other platforms, including the cloud service.

If you already have Raspbian installed on your Pi, you can install the latest version of RealVNC on your system. You do need access to the machine to configure cloud services on your Raspberry Pi, as far as I know. So log into your system and update the repositories:

sudo apt-get update



Then install the latest RealVNC packages:


sudo apt-get install realvnc-vnc-server realvnc-vnc-viewer

While the packages are being installed, open the RealVNC site and create a user account. The free service allows you to connect up to five devices.

Once the RealVNC packages are installed on the Pi, reboot your system. Once booted, you will notice the VNC logo on the top bar of the PIXEL desktop. Click on the icon. In the messages window, you might see an error. Select the error message and click on the “resolve” button. It will open a window where you have to enter the username and password for RealVNC that you created earlier. Click “next,” and in the second window choose “Direct and Cloud Connectivity.” Click “next,” and it will show you the name of the machine.

Install the VNC Viewer on your desktop PC, smartphone or tablet (whichever device you are planning to use). Log into your account. Click on the 3 bars on the top left and you will see the name of your VNC team there. Click on it.

Eureka! Your Raspberry Pi device is listed. Open that device, provide it with the username and password for that device (the system username, and not the VNC username), and you will be logged into your system remotely. If you’re on a laptop, you can use the mouse and keyboard to manage your device, if you’re on a mobile device then use touch.

Swapnil Bhartiya

Accessing my Raspberry Pi form my iPhone over the internet.

Enjoy your Raspberry Pi, remotely!

This article is published as part of the IDG Contributor Network. Want to Join?