Cloudflare & Gitbook

Getting a free website like this one using Gitbook and CloudFlare

Introduction

Running some kind of simple blog typically means you either need to hand yourself off entirely to someone else's service (Medium, Wordpress, etc) with a domain name that isn't yours and shared with many other users or you spend a lot of time and effort installing, patching and configuring something that you host yourself.

In both the above cases you are also likely to need to pay (though there are some free services they are typically full of ads).

The Goal

Simple:

  • a site that costs nothing other than the cost of a domain name

  • a site that requires no maintenance

  • using my own domain

  • easy to use - I can just type and format stuff in a reasonable way

  • Secured by Cloudflare for DDOS protection, TLS etc

Pre-requisites

  • Your own domain name (optional)

Setup

Mandatory steps

  1. Go to https://www.gitbook.com/ and register a free account

  2. Follow the simple instructions to get started and customise the site according to your preferences

  3. Once you have created your first space you are already up and running on domain provided by Gitbook

Optional steps (bring your own domain)

  1. From the Gitbook dashboard, Choose Advanced -> Custom Domain

  2. Enter your domain name and click configure

  3. As described you will now use the provided cname in CloudFlare to point your domain (or subdomain) to the hosting.gitbook.com

CNAME added to CloudFlare DNS configuration for your domain

NOTE: It seems like Gitbook will likely have trouble verifying the DNS entry due to CloudFlare proxying. Just ignore that step and go check out your domain!

The Result

Well, you are looking at it already!