30 September 2014
I’ve had a personal website at TheRub.org since 2002. In that time, a lot has changed on its front end and back end. Having a personal website is a great way to experiment with new web technologies and stake your claim on the Internet. This article will describe my 2014 recommendations for creating a low cost, high performance website for personal use.
This part is optional. However, without it, you are merely “renting” space from a landlord, who may kick you out at any time. A domain name gives you a permanent residence which you can fully control. For ~$10/yr, you become a partial owner of the internet. How cool is that!
I recommend Namecheap.com for domain registration. TheRub.org started at Network Solutions, then went to GoDaddy, and is currently at Namecheap.
I really like Jekyll for providing a full featured way to dynamically generate static content.
The problem with server side languages is security, performance, and complexity. For example, when running Wordpress, you have to concern yourself with the security of Wordpress, the security of PHP, and the security of any PHP modules or Wordpress plugins you have installed. For my site, it was a lot of code running on every page load for very little benefit (rendering pages).
Previously TheRub has used plain HTML, PHP (custom), MediaWiki, and Wordpress. I may have even had a Slashcode or Django phase in there somewhere. Currently I’ve settled on and really enjoy the simplicity and control that Jekyll provides.
If you use GitHub, one of the neatest (and cheapest) ways to host your personal website is with GitHub Pages.
GitHub pages takes the Jekyll source of your website from your GitHub repo (here’s mine), compiles it to static HTML, and publishes it on their infrastructure. All that is required is a properly formatted git repository and a few DNS changes to make your site live, even at your own domain.
If GitHub Pages isn’t sufficient, Amazon S3 can also host a static website without spinning up a VM, at a very low cost (but not free).
In the past I’ve always self hosted my website. I still have a VPS for other sites and purposes, but allowing someone else to host TheRub.org is one less thing I have to worry about.
And now, for complete and ridiculous overkill.
First, you get a global Content Delivery Network (CDN). Since your site is static, it can be heavily cached around the world for ridiculous page load performance. It’s not clear to me how much control there is of caching headers with GitHub pages - this may be a limitation of the platform.
You also get SSL - securing the connection between the client and CloudFlare. The connection between CloudFlare and GitHub pages is still unencrypted, but that’s still an enormous improvement over having the entire session unencrypted.
TheRub.org’s CloudFlare+GitHub Pages performance looks pretty good:
The “F” is a result of some of GitHub’s caching headers, and a lack of caching on some google fonts. The site loads in less than a second cold and half a second with a warm cache according to webpagetest.org.
Thanks to the open source technologies cited in this article and companies such as GitHub and CloudFlare, it’s amazing to consider that in 2014 you can take for granted a secure globally performant home on the internet for a mere $10/yr.