It seems this is not a screensaver issue because the monitor switches off even if I disable the screensaver and set the display power properties to never switch off. It's very weird. It's definitely not a temperature issue because according to SpeedFan, all the temperatures stay below 40.
I've now figures that when the display is off, I can usually wake it up by a combination of moving the mouse, switching the monitor off and back on and pressing keys like ctrl-alt-F12.
Does anyone have any ideas what could be causing the monitor/display to switch off and how I can stop it?