Design Portfolio


Setting Up a Custom Subdomain with GitHub User Pages and Namecheap

I finally found a succinct guide to setting up a custom Namecheap subdomain with GitHub pages.

My objective was to redirect my GitHub user page ellatronic.github.io to my custom subdomain projects.ellatronic.com. This process was actually alot easier than the hours it took me to figure it out, mostly due to the new format of the Namecheap dashboard and the old format shown in other guides I referenced.

Log in to Namecheap, go to Dashboard > Domain List. Then click Manage on the domain you want. Click Advanced DNS, then under Host Records click Add New Record. Enter the following:

Type: CNAME Record
Host: the subdomain name, for me this is projects
Value: the GitHub pages URL, for me this is ellatronic.github.io. Namecheap will automatically add the last “.” if you forget it.
TTL: Automatic

Press the green checkmark to save the record.

Next, go to the GitHub user page repo (username.github.io), for me it is ellatronic.github.io. Add a CNAME file containing subdomain.domain.com, so mine is projects.ellatronic.com. Make sure CNAME is in all capitals. Do not put http:// before the subdomain.

Here's what the GitHub file looks like

Here's what the GitHub file looks like