GitHub Pages + Route 53 + Cloudflare: DNS_PROBE_FINISHED_NXDOMAIN


#1

Hi everyone,
I would like to serve my GitHub Pages site on my custom domain over HTTPS. What I have:

  • A custom domain registered at AWS Route 53.

  • A Cloudflare account set up for my custom domain

  • In Route 53, I’ve set the name servers of the domain
    to the Cloudflare nameservers:
    first.ns.cloudflare.com.notalink
    second.ns.cloudflare.com.notalink

  • In Route 53, under Hosted Zones I’ve also removed the current NS records
    and added the Cloudflare nameservers:
    first.ns.cloudflare.com.notalink
    second.ns.cloudflare.com.notalink

  • In Cloudflare, I have 4 A records, and a CNAME which is an alias of mypage.github.io.notalink

  • In the project root folder I’ve added a CNAME document
    with the following content:
    mycustomdomain.com.notalink

  • In Route 53 everything seems healthy

  • In Cloudflare Overview the the website status is Active (This website is active on Cloudflare)

  • On GitHub under the Repository settings under GitHub Pages I can see that “Your site is published at https://mycustomdomain.com/

  • If I do whois mycustomdomain.com.notalink I can see that the name servers have been changed to the Cloudflare nameservers.

  • When I visit mypage.github.io.notalink or http / https : mycustomdomain.comnotalink I get redirected to https://mycustomdomain.com/index.html
    and I get the following error:

mycustomdomain.com.notalink’s server IP address could not be found.
DNS_PROBE_FINISHED_NXDOMAIN

Note that I’ve made these changes a day ago, so I would expect them to be working by now. What am I doing wrong?
Thanks in advance.


#2

I’ve managed to find the solution: I had to delete the A records in my Cloudflare account and leave the CNAME record.