One of the most common ways for users to access and administer their Raspberry Pi is via a VNC connection. VNC allows users to control their Raspberry Pi remotely, and interact with the desktop environment as if they were sitting directly in front of the Raspberry Pi, with a monitor and other peripherals plugged in. In reality, the Raspberry Pi needs nothing more than an Ethernet or Wi-Fi connection to facilitate VNC connections and full access to the system’s desktop.
The only problem you might encounter is if you connect via VNC and notice that the resolution is either too small or too large. This will make your desktop and application windows look the wrong size and may cause your picture to seem warped. The solution is to adjust the VNC resolution. In this tutorial, you will see how to adjust the VNC resolution on a Raspberry Pi.
In this tutorial you will learn:
- How to set headless resolution (for VNC connection) via GUI and command line on Raspberry Pi
|Requirements, Conventions or Software Version Used
|Privileged access to your Linux system as root or via the
# – requires given linux commands to be executed with root privileges either directly as a root user or by use of
$ – requires given linux commands to be executed as a regular non-privileged user
Set VNC resolution on Raspberry Pi step by step instructions
Setting the VNC resolution on your Raspberry Pi can be done either via the desktop GUI or from command line. We will go over both methods in the sections below. Feel free to choose whichever method is most convenient for you.
Set VNC resolution via GUI
- Headless resolution can be configured via the GUI’s menus via Preferences > Raspberry Pi Configuration.
- Click on the ‘Display’ tab and then you will be able to adjust the ‘Headless resolution’ as seen in the screenshot below. Although it does not explicitly say VNC, this setting will affect your current and future VNC connections.
Set VNC resolution via command line
In case you do not currently have direct access to the Raspberry Pi desktop GUI, or if you just prefer to use the command line, you can refer to the following step by step instructions to configure the headless resolution via command line:
- Open a command line terminal and type the following command to open the Raspberry Pi configuration tool:
$ sudo raspi-config
- Open up Display Options from the configuration tool.
- Then, highlight the option for VNC resolution and press
- Finally, we can set the VNC resolution to any of the choices on this menu.
In this tutorial, we saw how to set the VNC resolution on a Raspberry Pi system. The VNC resolution is also referred to as the headless resolution, since it is not necessary to have a monitor plugged into the Raspberry Pi and still access its desktop environment. We can adjust the VNC resolution easily enough from the GUI menus as seen here, and can also configure the VNC resolution via command line, depending on what we currently have access to.