Making a website to show it only on your laptop is no fun. To serve your content, you will need a server.
Luckily, you won’t always need a whole computer to act as a server, but there are many different ways to share your page. Like when you have a static site - which consists only of HTML, CSS and JS (and image) files - there are many options for hosting. One of the most commonly used one is GitHub Pages, GitHub’s own solution.
Let’s clone a test project, and share it with the world!
- How easy it is to use an online service for hosting
- A way to publish a static website
-
Create a public repository on
Github
with the namemy-first-github-page
then clone the repository to your computer.- A repository with the name
my-first-github-page
is created onGithub
and cloned into the computer.
- A repository with the name
-
Copy the starter code from this project's repository to your repository then replace the
replace this
text in the repository. Commit then push the changes.- Starter code of this project is in the
my-first-github-page
repository. - The the
replace this
text is replaced with a personal sentence inside theindex.html
file's<p>
tag. - The change is commited and pushed in git.
- The commit message is meaningful.
- There is no typo in the commit message.
- Starter code of this project is in the
-
Follow the official tutorial for a "Project site", and share your project with the world.
- The modified webpage is available at
https://<username>.github.io/my-first-github-page
- The modified webpage is available at
None
- Documentation is the developers best friend.
- GitHub Pages are available for public, or payed private accounts.
CodecoolGlobal
is a paid organization account, so you can accomplish this project. If you'd like to use GitHub Pages on your personal repository, it has to be set to publicly available, or you'll need to upgrade your personal account.