Skip to content
Laviyx Learn

Try

Mini project

Personal Portfolio Website with HTML and CSS

A responsive personal portfolio with about, skills, projects and contact sections, built with semantic HTML and modern CSS, and published free on GitHub Pages.

Beginner 1 week 1 studentUpdated

HTMLCSSFlexboxGridGitHub Pages

The problem

Recruiters often look at a candidate's projects before an interview. A portfolio site gives every student one link to share that shows who they are, what they can do and where their code is. It is also a good first web project because you will keep improving it for years.

Features to build

  • Header with your name, a one-line introduction and navigation links to each section
  • About section with a photo and a short paragraph
  • Skills section grouped by area, for example languages, web and tools
  • Projects section with a card for each project: title, description, tech used and links to code and live demo
  • Contact section with email and profile links
  • Responsive layout that works from a phone to a wide screen
  • Accessible: semantic elements, alt text on images and good colour contrast

Build plan

  1. 1

    Plan the content

    Write the text for each section first: introduction, about, three projects and contact. Good content matters more than effects.

  2. 2

    Write semantic HTML

    Use header, nav, main, section, article and footer, with one h1 and h2 headings for sections.

  3. 3

    Lay out with Flexbox and Grid

    Use Flexbox for the navigation and Grid for the project cards, with repeat(auto-fit, minmax(...)) so cards wrap on small screens.

  4. 4

    Make it responsive

    Start with the mobile layout and add media queries for wider screens. Test in the browser's device toolbar.

  5. 5

    Polish

    Use CSS custom properties for colours and spacing, add hover and focus styles, and compress images.

  6. 6

    Publish

    Push the site to a GitHub repository and turn on GitHub Pages. The guided portfolio project lesson walks through every step.

Learn these first

Each part of the project is taught in one of these free lessons.

Make it stand out

  • A dark mode that follows the system setting
  • A contact form using a free form service
  • A downloadable résumé PDF
  • A custom domain name

Viva and interview questions

Try to answer each one aloud before you open it.

  • What is semantic HTML and why did you use it?

    Semantic elements like nav, main and article describe what the content is. Screen readers and search engines understand the page better, and the code is easier to read.

  • When did you use Flexbox and when Grid?

    Flexbox lays items out in one direction, which suits the navigation bar. Grid handles rows and columns together, which suits the project cards.

  • What does mobile-first mean?

    I wrote the styles for small screens first, then added min-width media queries for larger screens. Phones load the simplest styles, and the layout grows as space increases.

  • Why does every image need alt text?

    Screen readers read the alt text to people who cannot see the image, and it shows if the image fails to load. Decorative images get an empty alt so they are skipped.

  • How is the site hosted for free?

    GitHub Pages serves the files from a repository as a website. Every push to the main branch updates the live site.

What to put in your project report

  1. Abstract: the problem, your solution and the result in one paragraph.
  2. Introduction and problem statement: who has the problem and why it matters.
  3. Requirements: the features (functional) and qualities such as speed and security (non-functional).
  4. Design: architecture diagram, database tables or data flow, and screen layouts.
  5. Implementation: the main modules and the most interesting code, explained.
  6. Testing: the test cases you ran, with inputs, expected and actual results.
  7. Results: screenshots or numbers that show the project working.
  8. Conclusion and future scope: what you achieved and what you would add next.

Your college may give its own format. Follow that first, and use this list to check nothing is missing.

All project ideas →