Introduction to making a website with GitHub pages
- 1. Create a free GitHub account. (Note your username will be part of your URL)
- 2. Create an Open Source repository. (Note The name of this is important as it will be part of your URL)
Two repository name options:
-
username.github.io
this will be the URL for your website -
any-name
the URL would beusername.github.io/any-name
-
3. Check the repository settings under the
settings
tab, then towards the end underGitHub Pages
section, select the right branch. (Note default branch is master on a new repository) -
4. Create a file called
index.html
with some text and wait a minute to see the deployed changes. Ask a friend to take a look at your website that is live on the internet. -
5. Add some content with html to this file, for example
<h1>Hello world</h1>
and see how this effects the deployed changes -
6. Add more content to the same file, for example
<p>My name is Eddie</p>
-
7. Lets add some styling, change
<p style="color:blue">My name is Eddie</p>
- You can use a custom domain, for example,
example.com
to point to your webiste