How to access VNC server running in an android phone in another computer? I have installed Ubuntu in my Android phone and I can access its GUI in my phone by connecting a VNC viewer to localhost:1. The VNC server is running inside Android.

Is it possible to access this in a computer connected to the wifi hotspot of the phone?

I connected to computer to the phone's hotspot and tried to access locahost:1 in Real VNC Viewer, but it says "The connection was refused by the remote computer".

Please note that I am not trying to access vnc server running in another computer in my phone but the opposite.
Go to Setting > About Phone and note down the ip address of your mobile phone.

Now connect to the Wifi hotspot of your mobile phone. In the VNC viewer, connect to the address ip-address-of-mobile-phone:1, to access the localhost:1 of the mobile phone.