How to Create and Host Your First Website With GitHub

GitHub Setup

Firstly, you’ll need to create a GitHub account if you don’t have one already.

git clone https://github.com/<username>/<username>.github.io.git

Website Creation

You can write your own HTML and CSS to create your website however, for the purposes of this tutorial I’ll be using a template from HTML5Up.

<username>.github.io/
├── assets/
├── index.html
├── LICENSE.txt
└── README.txt

Checking Your Website

Now you should be done! Congrats!

https://<username>.github.io

Optional: Custom Domain Name

As an optional step, I’ll be showing you how to add a custom domain to your website.

185.199.108.153185.199.109.153185.199.110.153185.199.111.153
mydomain.com

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store