How to Get Online - Hosting

You already know how to upload and publish a website using your student web space, but you're obviously not going to use this space forever.

This page should provide you enough information to get started looking for a hosting provider, so you can "properly" publish your work on the internet. Let's go over some of the key things to look for, then some my personal recommendations to get started.

tl;dr

There are 2 things you'll need to start hosting a web site online:

  • Shared hosting to store your web site's files and scripts, provided by a hosting company.
  • A super awesome domain name for people to find you. This is often provided along with your hosting, but can also be purchase separately.

Domains

A good domain name is very important, as this is essentially the flag for identifying your little island on the internet.

A domain name is the human-friendly URL that is associated with your web site, or more specifically, your site's IP address. When a user directs their browser to your domain, they are invisibly pointed to the network IP address for your web site's server. This is accomplished through a very complex system called DNS, or the Domain Name System.

xkcd map of the internet, 2006

Top Level Domains

A Top Level Domain (TLD) is the best kind to have. They're easy remember and rank highest with search engines. Many hosting providers offer one free TLD to go with your hosting plan.

Examples of TLDs include

  • http://greatestwebsite.com
  • http://myisland.net

There are country code TLDs like .us for the United States, and you've undoubtedly seen others like .co.uk (Britain), .com.au (Australia), .jp (Japan), .eu (European Union), .de (Germany) or .ru (Russia).

Some TLDs have restrictions on who can use them. .edu domains for example can only be used by educational institutions. .org has restrictions as well.

Since 2012 over 1000 new TLDs have been made available to registrars. You can now register domains ending in words longer than 3 characters like .hospital, .expert, .rugby, or .ninja.

Subdomains

Some services offer hosting completely for free under a subdomain. A subdomain is a great way to get a simple web site quickly and easily online, but it usually doesn't offer the same level of control as having your own server.

Examples of subdomains include

  • http://today.tcnj.edu
  • http://ithinkthereforeiblog.wordpress.com
  • http://random-musings.tumblr.com

If you have a TLD and your own hosting, you can create your own subdomains. You can even run an entirely separate web site under a subdomain!

Finding and Registering a Domain

You can search for available domains through the web site of almost any hosting company. A TLD will cost about $8-15/yr if not included with your hosting plan. Newer TLDs may cost more, about $18-$60/yr.

If offered, a free domain to go with your hosting is great, and having everything managed under one account at the same company makes things very easy.

You should know however, that domains are technically separate from hosting, and it is possible to have a domain registered with one company, and point it to your web server at a different company.

You can even point a domain to a computer at your house! Although I wouldn't recommend it.

The process of acquiring a domain is very straightforward if no one else currently owns it. If you purchase a domain off of someone else, they will need to unlock it and initiate a transfer. Your registrar can help you with this process.

I strongly recommend finding a domain that is readily available, if you can. While a pretty dirty tactic, cybersquatting is common. People often buy popular domain names and auction them off for a ridiculously inflated price. This is basically legal, unless they are squatting on a name or likeness that you or your business has trademarked.

As an example, when I began searching for a domain to host my photography site, I was hoping to use brphotography.com. Unfortunately, someone was sitting on that domain and tried to negotiate a price of $3000 to release it. I purchased brphotographs.com for about $10 instead. As of this writing several years later, no one has yet purchased brphotography.com.

Remember, the point of a domain is to have something people can easily find you by! Try to choose a domain name that's easy to remember and spell, relevant, and relatively short (characters are precious in tweets and captions!).

Domain Privacy

In order to maintain accountability and prove ownership, all domain registrars require domain owners to submit their full name and contact information, and keep it up to date each year.

Transparency makes sense, right? The only problem is that your full name, email, and other legitimate contact info are made publicly available.

To stop potential spammers and marketing, it's a really good idea to add domain privacy when registering your domain. This will hide your contact info from the public, but legitimate inquiries can get in touch with the registrar as a liaison if they really need to reach you. This service should be free and included, but is often an up-charge of about $15/yr. Either way, it's worth it.

Domain Registrars

Again, registering a domain separate from your hosting is not required, and many hosting companies will include a domain with your plan. That said, here a few of the top registrars if you decide to register your domain separate from your hosting:

Hosting

The term hosting refers to rented space on a server that is optimally tied to the internet.

Hosting for a basic web site, like the ones we've created in this class, is pretty simple and a lot like your student server space. You get some login credentials, drop your files in the www/ or public_html/ folder, and you're good to go.

You should, however, know a little more about what you're buying into, so here are some things to look for in a hosting provider.

Operating System

While you won't have to spend much time under the hood of your server for doing front-end development, look for a server that's running some flavor of Linux or UNIX as its operating system (as opposed to Windows). These servers are by far the most common, and most of the software that runs on them is free and open source (like Apache, MySQL, and PHP). All of my suggested hosting providers fall into this category.

You will need a server that has a control panel or some kind of web interface already set up for you. This gives you a visual interface for changing settings and managing your files, as opposed to the command line. cPanel is the most common. This type of plan is usually called managed hosting, which means the host will handle software upgrades, security patches, etc for you.

Diagram of a web server LAMP stack, with the client (browser) on one side, and the software combination of Linux, Apache, MySQL, and PHP, on the other
"Traditional" LAMP stack hosting architecture (source)

Quotas

Here are some of the things hosting companies categorize into different pricing tiers.

  • Disk Usage - The amount of hard drive space you're allotted
  • Bandwidth - The amount of monthly network resources (data transfer) you're allotted
  • Number of email accounts
  • Number of subdomains
  • Number of databases

Many hosting companies advertise unlimited resources for certain things. Be aware that unlimited isn't truly unlimited, but you aren't likely to get capped.

Server Types

Look for a shared server as opposed to dedicated or VPS.

Shared servers are by far the cheapest, most common, and easiest to use. You should start on a shared server. They have plenty of resources to handle small and medium sized web sites. They will also be ready to go with a login and web interface.

Basic shared server space typically runs about $3-15/mo depending on promos and what you're getting. Introductory pricing at most hosting providers is very cheap.

"Shared" means that the server your web site is on also hosts other accounts and their web sites (sometimes 100+). You can't see anyone else's files, and they can't see yours.

All of the drawbacks of a shared server come with the fact that you're sharing the same computer resources with several other people. Anyone who has poorly written code, or a password that's easily compromised, or get flagged for sending spam, can affect everyone else on the server. Sometimes a web site has a massive spike in visits, which could cause the server to slow down or even go completely offline for a little while, affecting everyone on it.

Hosting providers monitor how everyone is using server resources very closely, and take many precautions to prevent these things, so problems are rare. If you're lucky enough to go viral and drive tons of people to your website unexpectedly, hosting companies can quickly migrate your site to a more capable setup with a simple phone call.

Dedicated servers are considerably more expensive and only necessary for medium to large sized business with high traffic and demand.

A VPS, or Virtual Private Server falls somewhere in between. Essentially you are sharing a physical computer with other users, but you have full control of the settings and software. In other words, it appears as though you're on your own machine.

VPSes vary considerably in price and capabilities, but start as low as about $6/mo from places like Linode and Digital Ocean. An unmanaged VPS mean you have to manage the software stack yourself, including software updates and security patches.

Hosting Companies

It is very difficult to find consistency among reviews of hosting provider, and performance tests are rarely definitive. If you plan to do considerable research before signing up, try to find reviews and ratings from independent, non sponsored sources.

To get you started, here is a short list of providers who appear among the top rated often, and who I know to offer good service:

  • Dreamhost - A couple dollars per month more than your cheapest options, worth the premium. Dreamhost uses their own interface (not cPanel) and it's very easy to use. Their support is very responsive.
  • HostGator - Consistently one of the top-rated hosting providers, excellent customer support, and very good pricing. Uses cPanel interface.
  • JustHost and BlueHost - Same company. Cheap, but I used to host with JustHost and had a good experience. Phone support in my experience was great. Uses cPanel interface.

I started and stayed with JustHost for many years, but have since migrated to an unmanaged VPS with Linode. The price was better, I'm comfortable with the command line and managing the software stack myself, and the performance and uptime are excellent for my relatively modest needs.