Enable virtual displays on a VM
Stay organized with collections
Save and categorize content based on your preferences.
Linux
Windows
This document describes how to enable or disable virtual displays on a virtual
machine (VM) instance.
If an application running on your VM requires a display device, but you don't
need the performance of a GPU, then configure your VM to use virtual display
devices. By enabling virtual displays on a VM, you can run virtual display
devices on the VM, such as remote system management tools, remote desktop
software, and
screen capturing.
Before you begin
If you haven't already, set up authentication.
Authentication verifies your identity for access to Google Cloud services and APIs. To run
code or samples from a local development environment, you can authenticate to
Compute Engine by selecting one of the following options:
Select the tab for how you plan to use the samples on this page:
Console
When you use the Google Cloud console to access Google Cloud services and
APIs, you don't need to set up authentication.
gcloud
Install the Google Cloud CLI.
After installation,
initialize the Google Cloud CLI by running the following command:
To use the Terraform samples on this page in a local development environment, install and
initialize the gcloud CLI, and then set up Application Default Credentials with
your user credentials.
This predefined role contains
the permissions required to enable or disable virtual displays on a VM. To see the exact permissions that are
required, expand the Required permissions section:
Required permissions
The following permissions are required to enable or disable virtual displays on a VM:
To enable or disable virtual displays on an existing VM:
compute.instances.updateDisplayDevice on the VM
To create a VM with virtual displays enabled:
compute.instances.create on the project
To use a custom image to create the VM: compute.images.useReadOnly on the image
To use a snapshot to create the VM: compute.snapshots.useReadOnly on the snapshot
To use an instance template to create the VM: compute.instanceTemplates.useReadOnly on the instance template
To assign a legacy network to the VM: compute.networks.use on the project
To specify a static IP address for the VM: compute.addresses.use on the project
To assign an external IP address to the VM when using a legacy network: compute.networks.useExternalIp on the project
To specify a subnet for the VM: compute.subnetworks.use on the project or on the chosen subnet
To assign an external IP address to the VM when using a VPC network: compute.subnetworks.useExternalIp on the project or on the chosen subnet
To set VM instance metadata for the VM: compute.instances.setMetadata on the project
To set tags for the VM: compute.instances.setTags on the VM
To set labels for the VM: compute.instances.setLabels on the VM
To set a service account for the VM to use: compute.instances.setServiceAccount on the VM
To create a new disk for the VM: compute.disks.create on the project
To attach an existing disk in read-only or read-write mode: compute.disks.use on the disk
To attach an existing disk in read-only mode: compute.disks.useReadOnly on the disk
There are no costs associated with enabling or disabling virtual displays on a
VM.
Restrictions
For VMs with virtual displays enabled, the following limitations apply:
If your VM is running an x64-based Windows OS image earlier than version
v20190312, then, after enabling virtual displays on your VM, you must
install the virtual display driver as described in this
document. If your VM is running a later OS image version, then the driver is
already installed on the OS image.
You can use a virtual display device on the VM only after the guest OS boots
and initializes the virtual display driver.
If your VM is running an x64-based Windows OS image earlier than version
v20190312, then, after you enable virtual displays on the VM,
install the virtual display driver as described in this
document.
Create a VM with virtual displays enabled
To create a VM with virtual displays enabled, select one of the following
options:
If you've enabled virtual displays on a Windows VM that runs a Windows OS image
earlier than version v20190312, then, to use a virtual display device on the
VM, you must install the virtual display driver provided by Google Cloud. If the
VM runs a more recent OS image version, then the driver is already installed and
you can skip this section.
To install the virtual display driver on a VM with virtual displays enabled, do
the following:
If you had to manually install the virtual display driver on
a Windows VM as described in the previous section, then you can verify that the
installation was successful by doing the following:
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2026-10-02 UTC."],[],[]]