Even the most careful developers run into problems! This section will help you fix common issues, recover from mistakes, organize your files properly, and maintain your website long-term.
Common Problems & Solutions
❌ Problem: My website isn't showing up / I get a 404 error
✅ Solutions to try:
- Check if GitHub Pages is enabled:
- Go to Settings → Pages
- Make sure "Branch" is set to "main" (not "None")
- Click Save again if needed
- Verify repository is Public:
- Go to Settings → General
- Scroll down to "Danger Zone"
- Check if it says "This repository is public"
- If private, click "Change visibility" to make it public
- Wait longer: Sometimes it takes 5-10 minutes for pages to deploy
- Check your URL: Make sure you're using the correct URL format:
https://username.github.io/repository-name/
❌ Problem: My changes aren't showing up on the live site
✅ Solutions to try:
- Did you commit your changes?
- Editing isn't enough—you MUST click "Commit changes"
- Check the file to see if your edits are there
- Wait 2-3 minutes: GitHub Pages needs time to rebuild
- Hard refresh your browser:
- Windows/Linux:
Ctrl + Shift + R
- Mac:
Cmd + Shift + R
- Clear cache or use incognito mode: Open site in private/incognito window
- Try a different browser or device: Test on your phone or different computer
❌ Problem: My images aren't showing up (broken image icon)
✅ Solutions to try:
- Check filename matches EXACTLY:
- HTML says:
profile.jpg
- File must be named:
profile.jpg (not Profile.jpg or profile.JPG)
- Case-sensitive! Capital letters matter!
- Check file extension matches:
- If HTML says
.jpg, file must be .jpg (not .png)
- Check file path is correct:
- If image is in
/images folder, HTML should say: images/filename.jpg
- No
/ at the beginning: images/file.jpg NOT /images/file.jpg
- Verify image was uploaded: Go to your images folder on GitHub and check it's there
❌ Problem: My website layout is broken / looks weird
✅ Possible causes & solutions:
- Missing or extra HTML tag:
- Did you accidentally delete a
<div> or </div>?
- Every opening tag needs a closing tag
- Use GitHub's version history to restore (see next section)
- CSS was changed incorrectly:
- Did you edit the CSS file?
- Try reverting the CSS changes
- File encoding issue:
- When copying code, sometimes special characters break
- Re-type instead of copy-pasting
❌ Problem: My PDF/document download link doesn't work
✅ Solutions to try:
- Check link path:
- If file is in
/files folder: href="files/resume.pdf"
- If file is in root:
href="resume.pdf"
- Check filename matches: Same rules as images—case-sensitive, exact match
- Verify file was uploaded: Check the folder on GitHub
Made a mistake and want to go back to a previous version? GitHub saves every version!
Step 27: Viewing Version History
- Go to your repository homepage
- Click on the file you want to restore (e.g.,
index.html)
- Click the "History" button (or clock icon) at the top right
- You'll see a list of all commits (saves) made to this file
- Each commit shows:
- The commit message you wrote
- When it was saved
- Who saved it (you)
Step 28: Restoring a Previous Version
- In the History view, find the version you want to go back to
- Click on that commit
- You'll see the file as it was at that point in time
- Click the "View file" button
- Copy all the code from that version
- Go back to the current version of the file
- Click edit (pencil icon)
- Select all current code (
Ctrl+A or Cmd+A)
- Delete it and paste the old version
- Commit with a message like "Restored previous version"
✨ Pro Tip: This is why committing frequently with clear messages is important! You can easily find and restore exactly the version you want.
Good File Naming Rules:
- Use lowercase:
my-file.jpg not My-File.JPG
- Use hyphens instead of spaces:
project-image.png not project image.png
- Be descriptive but concise:
profile-photo.jpg not img123.jpg
- No special characters: Only letters, numbers, hyphens, underscores
💡 Why these rules?
- Some servers are case-sensitive
- Spaces in URLs become
%20 which looks messy
- Special characters can break links
Folder Structure Best Practices:
your-repository/
├── index.html (homepage)
├── about.html (other pages)
├── projects.html
├── style.css (or in a /css folder)
├── images/ (all images)
│ ├── profile.jpg
│ ├── project1.png
│ └── project2.png
└── files/ (documents)
├── resume.pdf
└── portfolio.pdf
✨ Keep It Clean: Don't upload random files, old versions, or test files to your repository. Keep only what you need for your website!
Monthly Maintenance Checklist:
Regular Tasks:
- Test all links (navigation, external links, downloads)
- Update your resume/CV PDF if you have new accomplishments
- Add new projects to your portfolio
- Check website on mobile devices
- Update your "About" section if your role/situation changed
- Review and update social media links
- Check for broken images
Quarterly Review Checklist:
Deeper Review:
- Remove outdated projects or information
- Update skills section with new skills learned
- Refresh design/colors if needed
- Update copyright year in footer
- Test website speed and loading times
- Review analytics (if you've added Google Analytics)
💡 Why maintenance matters: An outdated portfolio site can hurt more than help! Keep it current to make the best impression on potential employers, clients, or collaborators.
Where to Find Help:
1. GitHub Community:
- GitHub Community Forum
- Post your question with:
- What you're trying to do
- What you've tried
- Error messages or screenshots
- Link to your repository (if public)
2. Stack Overflow:
- Stack Overflow
- Search first—your question might already be answered!
- Use tags like
[github-pages], [html], [css]
3. GitHub Pages Documentation:
4. Web Development Resources:
How to Ask Good Questions:
✨ Include these details:
- What you're trying to accomplish: "I want to change my navbar color"
- What you've tried: "I edited the CSS file and changed background-color"
- What's happening instead: "The color didn't change"
- Any error messages: Screenshots of errors or console messages
- Your code: Share the relevant code snippet (use code blocks)
GitHub automatically saves all versions, but you can also create local backups:
Downloading Your Repository:
- Go to your repository homepage
- Click the green "Code" button
- Select "Download ZIP"
- Save the ZIP file to your computer
- Extract it to have a local copy of all your files
💡 When to download a backup:
- Before making major changes
- Every few months for archival purposes
- Before changing templates
🎊 You're Now a GitHub Pages Pro!
You've completed the entire tutorial series and learned:
- ✅ Setting up and publishing your website
- ✅ Editing HTML content and structure
- ✅ Customizing with CSS, images, and links
- ✅ Troubleshooting common problems
- ✅ Maintaining your site long-term
You now have the skills to manage and grow your website independently!
📝 Final Tips:
- Update your site regularly—don't let it go stale
- Share your website URL on your resume and LinkedIn
- Keep learning—explore more HTML/CSS tutorials to add new features
- Don't be afraid to experiment! You can always undo changes
This tutorial was created for students in the Master of Arts in Educational Innovation, Technology, and Entrepreneurship (MEITE) program at UNC Chapel Hill School of Education.