This is about the Domain Name System. This is what translates “reddit.com” into an IP address that a computer can use to actually understand and route, sort of like a phone book translating a business name into a phone number.
Back in the old days, you just had a record for “a.b.c” = 10.11.12.13. That worked great originally when you would just setup a server with a web server and mail server and everything you needed. However, eventually we wanted to start putting the mail server on a separate box that would be dedicated to it.
But now here’s the problem. If you email [email protected], that message is going to go to the server that `example.com` represents. That means you need to specifically route `example.com` to the mail server to keep it working. If you want the web server separate, you need to distinguish it. That’s where the `www` comes in. It gives you a separate address that you can point to the web server and have everything work.
There was an invention that helped in the 90s with this — the MX record. Basically, the DNS protocol allowed you to specifically request the Mail Server for a given address. This is what is used all the time today. It did take some time to roll out though, so many websites still had to have their main `example.com` domain point to a mail server, and maybe had a small web server on the same box that redirected to `www`. It’s the equivalent to having a phone book listing for a business having separate numbers for different departments.
Latest Answers