Dogz, yes might try turning on Dmz for an hour & see if it improves.
I've not seen wifi serial, must look into that, is that how you program an esp over wifi.
Poms, my code is much simpler, only one page, and that is served with client.print(), there are onlt 4 lines, a descriptor then a value on each line, just enough to be humanly readable with a browser, and simple enough to scrape with finder.find() in software.
Your code looks fairly standard server wise, you have a diffrent issue, yours works most of the time, mine works some of the time.
Apparently the esp32 has more 'advanced' and faster wifi & networking, maybe we should upgrade.
I'm at work now, my webservers page is open, and it hits every auto refresh, sometimes it takes a few secs to receive the data once requested but doesnt seem to fail, whereas last night using it at home on the same net it would only work after hitting refresh a couple of times.