Create your first website on GitHub Pages
Tags: webdev, beginners, git, github
Published: 2017-09-22 04:35:29

---
title: Create your first website on GitHub Pages
published: true
description: This article walks you through every step of creating a webpage with GitHub Pages, from creating a GitHub account, to creating the live site!
tags: webdev, beginners, git, GitHub
---

*This article was originally published on [programmingliftoff.com](http://programmingliftoff.com/) as [Create your first website on GitHub Pages](http://programmingliftoff.com/create-your-first-website-on-github-pages/).*

![GitHub Pages Jekyll Theme](https://thepracticaldev.s3.amazonaws.com/i/76nkqy3fobe6u9h31mes.png)


I have been spending most of my time lately working on projects around web development. One of the most amazing tools I've found during this process is GitHub Pages. This article will walk you through creating a 'Hello, World' website hosted on GitHub Pages. Everything here is 100% free. If you learn better from videos, scroll down to the bottom of this article for a video walkthrough.

## STEP 1 - CREATE A GITHUB ACCOUNT

If you already have a GitHub account, great! Â Feel free to skip to step 2. Â If not, no worries! Â Creating a GitHub account is easy and will boost your visibility and credibility as a developer. Â In a way, a GitHub account is like a LinkedIn account for developers. Â GitHub allows you to put your code under version control and store it on a server (aka "In the cloud") so that even if you lose your computer or hard drive, all your code will still be accessible through your GitHub account. Â There are many different types of version control systems (vcs) such as subversion (svn), mercurial, and git. Â GitHub, as you may have guessed, uses git. Â They all have different strengths and weaknesses, but overall git is probably the easiest to get started with and is the go-to vcs system for the majority of developers. Â Version control systems are outside the scope of this tutorial, but you can find a short comparison of some of the most popular version control systems here. Â A nice Youtube playlist with introductory git videos published by GitHub can be found <a href="https://www.youtube.com/watch?v=8oRjP8yj2Wo">here</a>.

To make an account on GitHub, head on over to their webpage at https://github.com/. Â They have a really simple process for creating an account, so simply pick a username, enter your email address, and choose a (strong) password, and you're good to go!


##STEP 2 - CREATE A REPOSITORY

Â 
Next we will create the repository we will use for our GitHub Pages site. Â First a quick, but important note on repositories created with GitHub. Â GitHub has a free plan and a paid plan. Â The main difference between a free and paid plan on GitHub is the ability to create a private repository. Â With a free plan, all repositories you create will be public. Â That means anyone can see the code/files/ect. that you upload or create in the repository. Â Therefore it is super important that you do not put any private information in a public GitHub repository. Â Whatever you put in a public GitHub repository, you are sharing with the world. Â Using the free plan works great for this tutorial, as we will be adding a simple 'Hello, World' webpage to our repository, but keep in mind that if you want to be the only one with access to your GitHub repositories, you will need to upgrade to a paid account, which is currently $7 a month. Â If you're a college student, GitHub will give you unlimited free private repositories and many other benefits; you can find more info <a href="https://education.github.com/pack">here</a>.

Steps to create a repository:

1. Click the 'New Repository' button


2. Enter the repository details as shown below and then click the green 'Create repository' button.


##STEP 3 - ENABLE GITHUB PAGES FOR THE REPOSITORY

3. Click the 'Settings' button on the repository home page.


4. Once you are on the settings page, scroll down to the 'GitHub Pages' section and choose the master branch for the source.


##STEP 4 - CREATE THE HELLO WORLD WEBSITE

5. After enabling GitHub Pages for the repository, the next step is to create your website! Â Head back to the 'Code' tab in GitHub as shown below.


6. To create a homepage for your website, click on the 'Create new file' button.


7. Next enter the information shown below to create the index.html file.


##STEP 5 - VISIT YOUR WEBSITE!

8. Great! Now it's time to visit your new website! Â Head back to the 'Settings' tab and click on your GitHub Pages URL in the GitHub Pages section. Â Note: It may take 5-10 minutes for the link to show your updated site.


9. Congratulations! Your website should be live on the internet! Â Now you can utilize your web development skills to make an awesome website without having to pay a penny for hosting!


Final Site
##BONUS - USING JEKYLL THEMES

If you were checking out the options under the GitHub Pages section, you will have noticed that you can choose a theme. Â Themes are an easy way to get a great looking webpage up and running in no time! Â After choosing a theme, you will need to delete the index.html file you created to see the theme take effect.


And that's the basics of GitHub Pages. Â In summary, GitHub Pages allows you to host your static websites for free. Â If you want your website source code to be private, you can upgrade to a paid GitHub account for unlimited private repositories. Â Static websites are very powerful. Â These sites can be built so well that it is not obvious whether a site is a static site, or a dynamic site using a server. Â This tutorial was to help you become aware of the possibilities made available to you by GitHub's support for static websites. Â To fully take advantage of static sites on GitHub you will need to practice your HTML, CSS, and JavaScript skills! Â With GitHub Pages, (almost) anything is possible, so start building your website today!

Did you create a static site on GitHub? Â If so, post a link in the comments below so others can see it and gain some inspiration!

Decide to watch this tutorial instead of reading it? Â Great! Â Hit play below.
<iframe width="560" height="315" src="https://www.youtube.com/embed/BA_c3bGQXlQ" frameborder="0" allowfullscreen></iframe>