Setup Google Domains & Github Pages
Google Domains paired with github pages is a very inexpensive way to build a website. I have been looking for a GoDaddy alternative for some time (they constantly try to sell me things I don’t need at the time of checkout), so when Google dropped its domain hosting I jumped ship fairly quickly.
1. Navigate to “My Domains” & Click Manage
2. Click DNS
3. Setup The A Records
- Name: @
- Type: A
- TTL: 1H
- Data - You can add multiple IPs by clicking the plus sign
1184.108.40.206 220.127.116.11 18.104.22.168 22.214.171.124
4. Setup the CNAME
- Name: www
- Type: CNAME
- TTL: 1H
- Data: @
Once you click add the data column will automatically swap to your base URL:
1. Custom Domain Settings
Navigate to the repository settings.
Check the “Enforce HTTPS” box and save your custom domain name. Github now automagically sets up HTTPS for you as well ( using letsencrypt behind the scenes).
2. Create the CNAME file
Update: The last time I setup a domain the CNAME file was automatically generated when I added the custom domain. Your mileage may vary.
The CNAME file just needs to contain your domain name:
You’re done! Congratulations
Github may display a yellow warning message, but please note all of these changes could take up to 48 hours to take place. If you still see a warning message in your github settings after 48 hours try removing the custom domain, saving, and then re-applying it.
View this post on medium.