• Home
  • |
  • Blog
  • |
  • Step by Step Tutorial to Set Up VNC on Raspberry Pi
set up VNC on Raspberry Pi

Virtual Network Computing is the obvious option when you work with Linux platforms. In short, it’s called VNC. It’s a cross-platform remote desktop technology that can be used on most operating systems. There is a variety of products available on the market. Few products are free, and few are commercial. But, most of the new Raspberry Pi distributions come with ReavVNC, which supports cloud-based connections right in. This allows you to connect Pi not only within the network but also over the internet. RealVNC gives users the freedom to connect from anywhere. This flexibility makes this option more prominent than others. Let’s see how to set up VNC on the Raspberry Pi.

Note: VNC runs on port 5900. You should open this port on all the middle devices to work the communication from your PC to the Raspberry Pi.

  1. Make sure VNC is enabled on the Pi. to ensure that, go to main menu -> preferences -> Raspberry Pi configuration as shown here. And, go to the interfaces tab where you can enable the VNC and hit OK.
An image shows how to go to Preferences then Raspberry Pi configuration
Go to Preferences, then Raspberry Pi configuration
An image shows the VNC configuration in Raspberry Pi
VNC configuration in Raspberry Pi

If you see the problem in enabling the VNC on your Pi, then you may need to install the RealVNC from the repositories.

Install the RealVNC on Raspberry Pi

Time needed: 5 minutes.

Install the RealVNC on Raspberry Pi

  1. Update the system repositories:

    Open the terminal if you have direct access. Or, take an SSH session to the Raspberry Pi CLI.
    $ sudo apt-get update && apt-get upgrade

  2. Install the RealVNC server:

    $ sudo apt-get install realvnc-vnc-server

  3. Enable VNC server:

    $ sudo raspi-config
    Got to Interfacing options
    Select VNC
    Answer Yes
    Select Finish to quit (or ESC)

Connect from Windows client: Visit the RealVNC “https://www.realvnc.com/en/connect/download/viewer/” site and download the client for your operating system and install it. Once it’s done, fire up the VNC viewer and enter the Raspberry PI IP address, and hit enter. You are going to see a warning message like this.

Connecting Raspberry Pi using VNC viewer
Connecting Raspberry Pi using VNC viewer

Select ‘Continue.’ This prompts username and password. In a movement, you are going to see the full-size GUI desktop.

Note: You ended up in some sort of problem if you unplug the monitor, mouse, and keyboard from the Pi and try accessing its GUI desktop over VNC

The problem in connecting Raspberry Pi using VNC viewer
The problem in connecting Raspberry Pi using VNC viewer

$ sudo raspi-config

The output of "sudo raspi-config" command
The output of “sudo raspi-config” command

Choose Advanced Options.

Advanced Options in Raspberry Pi Software Configuration Tool
Advanced Options in Raspberry Pi Software Configuration Tool

Set the resolution as per your screen size. We recommend setting DMT Mode 82 1920 X 1080 69 Hz 16:9.

Setting screen resolution in Raspberry Pi
Setting screen resolution in Raspberry Pi

As we said earlier, it is possible to connect Raspberry Pi over the internet. You need not be part of the network to which Raspberry Pi has connected. To access Pi over the internet, you should create an account on the VNC cloud and sign into it.

Open the VNC application on the Pi and click on the Sign in link.

VNC application on Raspberry Pi
VNC application on Raspberry Pi

Create your own account here or just sign in if you have already.

Sign in to the VNC server
Sign in to the VNC server

Note: You are allowed to connect only 5 computers in the free account. You have paid account options as well if you want to add more than 5 computers.

Upon setting up these configurations on VNC, you can sign in to your cloud account and connect the Pi over the internet. That’s all. This ends with how to set up VNC on the Raspberry Pi.

Thank you for reading this article. Please visit the below links to read more such interesting articles. Peace leave your comments here below and let us know your feedback. This helps us to bring more such articles.

About the author

Arun KL

Hi All, I am Arun KL, an IT Security Professional. Founder of “thesecmaster.com”. Enthusiast, Security Blogger, Technical Writer, Editor, Author at TheSecMaster. To know more about me. Follow me on LinkedIn

Leave a Reply

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

{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}

Learn Something New with Free Email subscription

Email is also one of the ways to be in touch with us. Our free subscription plan offers you to receive post updates straight to your inbox.