DEV Community

Cover image for ๐Ÿš€ Build and Run a Java + HTML Portfolio Website Using Spring Boot and Maven
Chaitanya Chopde
Chaitanya Chopde

Posted on

๐Ÿš€ Build and Run a Java + HTML Portfolio Website Using Spring Boot and Maven

โœ๏ธ Written by: Chaitanya Chopde
๐Ÿ“ซchaitanyachopde14@gmail.com
Inspired By: @devsyncin

๐ŸŒŸ Introduction

Creating a professional portfolio website is one of the best ways to showcase your skills as a developer. In this tutorial, Iโ€™ll walk you through how to build and run a full-featured portfolio website using:

โœ… Java (Spring Boot backend)

โœ… HTML, CSS, JavaScript frontend

โœ… Maven for project management

โœ… VS Code as the IDE

By the end, youโ€™ll have a fully functional portfolio with a working contact form, animations, and a clean modern UI.

๐Ÿงฐ Tools & Tech Stack

  • Java 17+
  • Spring Boot 3.x
  • Maven
  • HTML/CSS/JavaScript
  • VS Code
  • Chocolatey (optional)
  • Windows OS

๐Ÿ”ง Step 1: Install Prerequisites

โœ… Install Java 17
Using Chocolatey (fastest method):

Image description
โœ… Install Maven

Image description

โœ… Verify Java & Maven
Open PowerShell or CMD:

Image description

๐Ÿ“ Step 2: Project Structure

Image description

๐Ÿ–ผ๏ธ Step 3: Frontend Code

index.html

Image description

script.js

Image description

โš™๏ธ Step 4: Backend with Spring Boot

ContactController.java

Image description

PortfolioBackendApplication.java

Image description

๐Ÿš€ Step 5: Run the Website

๐Ÿ’ป Backend (Java)
Open backend folder โ†’ Terminal:

Image description
Backend runs at:
http://localhost:8080

๐ŸŒ Frontend (HTML)

Use Live Server in VS Code:

Right-click index.html โ†’ "Open with Live Server"
Form submits to backend โ†’ You get a success alert โœ…

๐Ÿงช Testing

  • Run backend
  • Run frontend
  • Submit contact form โ†’ Check terminal logs
  • ๐ŸŽ‰ Your full-stack portfolio is working!

Image description

๐Ÿ› ๏ธ Common Errors

  1. โŒ mvn not recognized Maven isnโ€™t in your PATH

Fix: Add C:\path\to\maven\bin to Environment Variables โ†’ Path

  1. โŒ CORS Error Add @CrossOrigin(origins = "*") in your controller

๐ŸŒ Future Upgrades

  1. Add Resume Upload
  2. Dark/Light Theme Toggle
  3. Database for storing messages
  4. Deploy backend (Render) and frontend (Vercel)

๐Ÿ™Œ Final Notes

Building your own portfolio from scratch using Java + HTML is a great learning experience. You learn how frontend talks to backend, how to build REST APIs, and how to deploy projects.

๐Ÿ”– Inspired by @devsyncin

Special thanks to @devsyncin community for inspiring clean code, full-stack clarity, and real-world deployment skills.

Top comments (0)