Introduction

Using Github pages we can use own domain - more about that you can find in documentation.

Here is steps to configure custom domain

  1. First we need repository. Repository for root domain should be named {user_name}.github.io or {organization_name}.github.io. In my case this is pelicandev.github.io repository.

  2. Now go to repository settings and set your domain in GitHub Pages -> Custom domain section. setting custon domain address on GitHub Pages

  3. Go to your DNS provider and create records for you site. Here is my records:

    | Name | Type  | Value                 |
    |------|-------|-----------------------|
    | @    | A     | 185.199.108.153       |
    | @    | A     | 185.199.109.153       |
    | @    | A     | 185.199.110.153       |
    | @    | A     | 185.199.111.153       |
    | www  | CNAME | pelicandev.github.io. |
    

    IPs adresses in A records could be vary, so it is worth checking the documentation to see if they are up to date. Value in CNAME records is my Github Pages address.

Now everything is set up correctly. It may take a while for the page to be accessible by our custom domain - this time depends on DNS propagation.