Hosting Sites Using Github

A website can be hosted using GitHub or another domain service (such as GoDaddy), instead of just locally.

In short: websites can be built locally using a file structure, but to view it online or share it with your friends worldwide you must host it online.

How to host a website using Github

  1. Create an account on GitHub
  2. Add a new repository. This is a folder that stores our project files. We can use the repository to also track our changes.
  3. Ensure that you have added a README file to the repository.
  4. Add in the files and upload them to github for the website.
  5. In settings, look at GitHub Pages. This can be used to host the pages
  6. Select a source where our files reside (main)
  7. The website will have a link gemerated, and you can share this with anyone on the internet.
  8. Ensure that all of the links work from the html, and check to make sure that it is in the main directory.