Before you get started, you will need to have:
When it comes to a computer, almost any computer less than 5 years old will do, but the more you want out of it the better machine you need to start with. You can start small and as things progress easily migrate to better computers. If you are going to buy one, my best advice is to look for refurbished equipment without operating systems installed. It saves you a lot of money and gets you the best bang for your buck. I used this search on Newegg to get my machine's. Recently I noticed this site for Hard Drives; HardDrivesDirect which has great pricing comparatively to my searches. You could get bare equipment on Newegg and fill it with bargain Hard Drives.
A UPS Device
The same investment strategy for a computer goes for a UPS device. I got one from eBay, another from Amazon, and here is a search on Newegg to show you what you are looking for. A corollary to the no operating system here is the no battery. It lightens the shipping and the hazardous materials issue. Get new batteries locally that fit the UPS you pick.
An Internet Connection
Most people that read this have an Internet connection. You merely have to access the router that connects your computer to the internet (usually http://192.168.1.1/, user:admin, password:admin), and set up the DMZ to point to the server computer you build by following the rest of this guide. Most routers have instructions about how to do this on their website. It's a safe bet that if you browse to YouTUBE and search the Make and Model of your router along with the words "Set-up DMZ" you'll see just how to do that.
Mine is through Google Domains right now, but their's many excellent alternatives, like Rackspace., or Afraid.org (Free DNS), or DNSimple, or No*IP, or Xname, or Dyn, or Dynu, or FreeNom... This Domain thing you need is very different than a Hosting Service. My guide is showing you how to become your own hosting service and more. A Domain Name Service Provider is more like a phone book for webpages. It's probably going to cost you $10.00/year or less to have a FQDN, but having reasonable hosting somewhere would be at least $15.00/month. After you get your own version of example.com, you tell your domain service to point your FQDN to your router. Easiest way I know to find your router's IP number is to ask Google "What's my IP address". Every computer in that routers domain will give the same answer. (Special note: you probably have dynamic IP addressing as opposed to static IP addressing, so they can change your dotted-quad at any time and your web-server will be disconnected until you go to your Domain Name Service Provider and edit your FQDN to point to the new IP number)