Module 3 · ~40 min

GitHub Pages — your username.github.io site

Goal: Publish a simple personal webpage hosted free on GitHub.

Two common patterns

PatternRepo nameLive URL
User site<username>.github.iohttps://<username>.github.io
Project sitehello-githubhttps://<username>.github.io/hello-github/

Steps — user site

  1. Create a public repo named exactly <your-username>.github.io.
  2. Add file index.html via Add file → Create new file.
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <title>My GitHub Page</title>
</head>
<body>
  <h1>Hello, world!</h1>
  <p>This is my first GitHub Pages site.</p>
</body>
</html>
  1. Commit to main.
  2. Settings → Pages → Deploy from branch main / root → Save.
  3. Wait 1–3 minutes, then open your live URL.
Tip: If you see 404, wait longer, confirm the repo is public, and check index.html is on main.

Checklist

  • I created username.github.io (or a project Pages repo)
  • index.html is committed on main
  • Pages is enabled in Settings
  • My site loads in the browser