I'm using ssh to do some computations on a remote server, which is in linux whereas my computer is Windows 10. I would like to be able to see plots from gnuplot, but a priori it does not plot anything.
From what I've read, it seems I need to setup X11 forwarding. I installed VcXsrv X server with everything default, and set "export DISPLAY=localhost:0" in the ssh terminal, but then I get an error like pictured below.
From here it seems less clear to me what I should do. It seems many people have a variety of issues which lead to this error, but I don't think I'm doing anything particularly complicated. Some things have mentioned checking some kind of config file or trying something like localhost:10 or 137 or something else, but I'm not even sure if my profile has that kind of config file, and I have no clue how to choose what number to put after localhost.
I'm quite new to this kind of thing so any help is appreciated.

I cannot help with the question of how to get the Windows end of an X11 connection working, but depending on the resolution or type of graphics output needed you may be able to use one of the other gnuplot output modes.
"set term dumb" will send low resolution character-cell graphics back to the terminal window you are typing in. This should work anywhere. The output would look like this:
If on the Windows end you run a terminal emulator capable of sixel graphics, then much higher resolution color graphics can be sent directly back to the terminal using "set terminal sixel". See screenshot below.
More complicated options are also possible that involve piping files (png jpeg svg pdf ...) back through the x11 connection for separate display on the Windows end.