How I set up this website using GitHub Pages, namecheap and Cloudflare

Warning

I have migrated my website to Hugo PaperMod + hugo notice

Read the Papermod Guide and how to host on Github for more info.

GitHub Pages

GitHub Pages is a free and easy way to host a static website. It also works with jekyll, making creating a personal blog very easy.

Selecting a theme

There are a lot of different themes that you can choose from on GitHub.

In my case I pretty much chose the first one: Minimal Mistakes and used the starter from its guide.

After setting myusername.github.io as the repository name and enabling github pages in the settings, the website was up and running.

Custom Domain

I wanted to use a custom domain name for my site, so I went to namecheap and purchased xiang.dev given that Google released this domain quite recently.

I used Cloudflare to handle the redirect and SSL certificates for the site, it is completely free and quite easy to use.

This guide by Bart de Goede is quite detailed and explains this step quite well.

You may also need to set up A records on Cloudflare pointing to the IPs owned by GitHub.

Note: Don’t forget to also change the nameservers of your domain to the ones provided by cloudflare.