You can use your own custom domain with GitHub Pages, instead of GitHub’s <username>.github.io domain. This GitHub Pages post covers the domain configuration steps.
If you bought the domain on GoDaddy, I’m going to show you the exact GoDaddy DNS configuration you need.
Go to your godaddy.com domain, and find the Manage DNS option.
Add these settings.
My website is hosted on GitHub under the valinsky.github.io domain. You’ll have to update the CNAME with your own <username>.github.io domain.
You’ll then be greeted with this message in your GitHub respository’s settings, right under the GitHub Pages section.
Like the message says, you have to wait 24 hours for the internet to magically issue an HTTPS SSL certificate for you.
That was not the case for me.
Make sure you unpark your domain
Even though your certificate is not issued, you can still access your website through HTTP.
Never do that! Never serve your website through HTTP. Read why.
When I was setting up my own custom domain for this website, I waited 24 hours, then another 24 hours, and yet another 24 hours, but the certificate wasn’t getting issued.
I soon realized the problem was with GoDaddy’s DNS configuration.
My initial configuration looked like this.
Those two DNS entries were setup by GoDaddy, and I didn’t pay much attention to them initially. If you see these in your own DNS configuration, be sure to remove them, or else you’ll end up with a parked domain that won’t work with your GitHub Pages setup.
After I removed those entries, a few hours later my HTTPS SSL certificate was issued and I was able to activate it.
And that’s it.
Now you have a website hosted by GitHub and configured with your own custom GoDaddy DNS.