X0Vncserver Unable to Open Display:0

I am attempting to use x0vncserver from the package tigervnc-scraping-server to run a VNC server using my local desktop session. Many guides such as this recommend starting the server with

x0vncserver -passwordfile ~/.vnc/passwd -display :0

or

x0vncserver -display :0

For me, both result in

No protocol specified
x0vncserver: unable to open display ":0"

How can I fix this? I have seen similar issues where the desktop session is owned by a different user, but I am the only user in this situation.

12
Maya Lin-Takahashi

Maya Lin-Takahashi

Consumer Tech & Gadget Reviewer

Maya is a hardware enthusiast who tests and reviews smart home devices, smartphones, wearables, and audio gear. She focuses on practical consumer value and build quality.

Share this article