DEV Community

Discussion on: How to set up a custom domain on Github Pages

Collapse
 
stephanie profile image
Stephanie Handsteiner • Edited

You don't need to create the CNAME file by hand, GitHub does that automatically, when you enter the custom domain in the repository settings.

Collapse
 
heymarkkop profile image
Mark Kop

Cool! I was having a problem that if I didn't include CNAME on build, this setting would reset after each deploy.

Collapse
 
xanderyzwich profile image
Corey McCarty

You do have to include it on build, but when you add the custom domain from the github site it automatically creates and commits the CNAME file for you.