GitHub Pages site not constantly displayed after enforcing HTTPS on custom domain

I have built a blog using Jekyll and deployed using GhPages.

I then enforced HTTPS in settings.

However, there are times where my site refuses and or fails to load saying:

This site can’t provide a secure connection sent an invalid response.

The link to the repo:

The link to the live site:

  1. What could be the issue?
  2. How can I be able to solve it?

Hey @newtonkiragu, I got an error the first time I visited the site but the subsequent visits were successful. Who is your DNS provider? 


Namecheap is my DNS provider.

an update, I received the following email. I have updated my records and will update my question if anything changes.

Hi Newton,

Thanks for writing in! I took a look at your DNS settings and it appears that your custom domain is set up with an extra A record pointing to

You’ll need to remove that extra A record before you’ll be able to enable HTTPS for your custom domain.

Once you’ve removed the A record, you’ll need to visit your repository’s settings page, which will kick off the process of provisioning an HTTPS certificate for your domain name.

Once your certificate has been provisioned, you’ll then be able to enforce HTTPS by checking the “Enforce HTTPS” checkbox.

Bear in mind that it can take up to 72 hours for DNS changes to take full effect, and up to an hour for an HTTPS certificate to be requested, so if you follow these steps but are still having trouble, that’s usually why.