Link Search Menu Expand Document

GitHub Pages

GitHub Pages is a static site hosting service that takes HTML, CSS, and JavaScript files straight from a repository on GitHub, optionally runs the files through a build process, and publishes a website.

Table of Contents

Public GitHub Pages repository

To create GitHub Pages repository, follow the instructions:

  1. Log in to your GitHub account.
  2. Then click New at the top left of the screen.
  3. In the specified field, type the name of the repository. For GitHub Pages, you have to name your repository according to the scheme my_username.github.io.

  4. Select Public.

    📝 Note: For GitHub Pages, you need to make the repository public.

  5. Click Create repository.

Adding files to GitHub Pages repository

  1. Open your GitHub Pages repository in VS Code.
  2. In the top menu click File.
  3. Select New File.
  4. Name the file as index.html.
  5. Write any content in HTML.
  6. Save the file.
  7. To add the file to GitHub, open GitHub Desktop.
  8. Select a repository from the list.
  9. Go into Changes.
  10. If the change summary name did not automatically generate, type the name in the space specified.
  11. Select Commit to master.
  12. Then select Publish branch.
  13. To check if your web page works, go into browser.
  14. In the web browser type the name of your GitHub Pages repository: my_username.github.io.

Back to top

This documentation is part of the reference materials for the Technical Communication course at Vistula University (Warsaw).