I wanted to have a simple way of checking out my Raspberry Pi's board temperature, storage space, memory usage and other stats' so I cobbled together some php and bash to serve up using the webserver on my Raspberry Pi.
There are many examples/tutorials on writing a HTTP server in C. I would recommend starting with one of those, then modifying it to do what you are trying to do, or writing your own based on what you learn.
Another possibility is to use an embeddable HTTP server, or a light weight HTTP server like lighttpd.
You could use Lighthttpd. It's similar to apache, but it's simpler. https://www.lighttpd.net/
If bandwidth/connection count is an issue for your uplink, i'd reccomend using even cloudflare free to act as a CDN. That also helps with your security, and mitigates against DDoS attacks (which since you're in the game world, I can imagine that might be a thing for you)
​
EDIT: What PromoFaux said. We responded without knowing the other was responding... :P
It seems that simplenas uses a different web server than us. We use lighttpd, and it seems that they use nginx. It's not recommended to run 2 web servers at once (if they even will start up together). You may be able to change the web port for simplenas, and then install pi-hole again. Then all traffic will default to using lighttpd (blocking ads) and when you want to use their web interface you connect via a different port (xxx.xxx.xxx.xxx:port#).
Thank you! I'm looking at https://www.lighttpd.net/ as an alternative on windows since people say it's easier to set up.
I do have a domain name so need to look up how to set up SSL for it and everything.
I run Debian Stable on my home server and love it. I find it a bit more reliable than ubuntu (opinion), but what I love most about Debian is the depth and bredth of the documentation, especially documentation seemingly targeted at Sys Admins, covering the topics you brought up.
If you just need a web server and don't have a lot of resources on the machine, consider lighttp.
The /r/selfhosted and /r/homelab subs are good places to look around too.