Custom domain for project pages in Github

# Github is social coding website where we can host, collaborate with others on our code.
# Near month ago, I’ve made a repository to host CDN of SeeBeeTee in Github. But in first try I can’t get working. So I’ve written an email to Github Support. And they’ve answered quickly and it just solved my problem.

Why you should host cdn or website in Github?
  • Github is totally free if you would like to host your website/sub-domain publicly. Yeah It costs if you want to make private repositories.
  • Github Support is awesome.
  • It supports Jekyll. Which is static site generator. (Many of bloggers host their blogs on Github.)
  • We can also host One Page Website by just adding index.html and some stylesheets, images etc.
  • It works on git which is version control system so we can also see our previous version of website, make new branches, people can submit pull request etc.
# There is no support for php right now.
How to?
  1. First of all make a new repository in Github of your choice like if you want to host cdn of then you should name repository
  2. Clone it in your desktop via Github app… or what you used to clone repositories from github.
  3. Then delete the branch master if it’s there (It’s there if you checked Initialize this repository with a README and/or added .gitignore and/or added license file), and then just make a new branch called gh-pages.
  4. Then add your content there like index.html, style.css, images etc.
  5. Then add CNAME which is used to set-up sub-domain with Github, in CNAME write your sub-domain name like
  6. Commit and Push it to Github.
  7. Go to your Domain Control Panel(where you’ve bought your domain) and go to domain’s CNAME Records.
  8. Add a CNAME record with host name like here and in the value field type (username will be your username of Github/organization username of Github.)
  9. Then click Submit/Add Record.

# Now wait for some minutes (near 10 minutes) and your sub-domain will be hosted in Github. Enjoy.
# If you face any problem(s) while doing this you can email to Github Support or just fill this form.

# Thank you very much for reading. Have a Nice Day :).

Share This Now:

Add a Comment

Your email address will not be published. Required fields are marked *