Use Github Pages for your server environment

GitHub (github.com) offers free code storage and Internet hosting service. It is a popular tool used for code collaboration and sharing, but it also offers free hosting for static sites via Github Pages (pages.github.com).

In this short lesson, we are going to demonstrate how you can use Github to store your code (and as a "cloud" backup service), and how to use Github Pages as your web server (free web host).

Step

1

Github Setup

Login to GitHub.com and note your username.

  • Username: __________________

Step

2

Create a new username repo for main your Github Pages site

Create a new repo and name it yourusername.github.io

  • Add a brief description
  • Check the box that says "Add a readme"
Github new repo
The create-a-new-repo settings screen.
Your Github Pages username repo. Note the url path.

Step

3

Test your live website

To see if the setup worked, test your site on the server by visiting the url in a browser.

  • Launch your favorite browser (e.g. Google Chrome) then type in the url yourusername.github.io and see if the readme.md file is displaying as your home page.
    • If not, you'll need to pause here and troubleshoot.
    • If it's working, then way to go!