Building an Interactive 3D Portfolio with Three.js & Next.js

Most developer portfolios stick to the standard playbook: a clean hero section, a grid of project cards, and a contact form. There is nothing wrong with that—it works. But when redesigning my own site, I wanted the space to feel more like an interactive experience and less like a static resume.
I decided to integrate 3D elements using React Three Fiber alongside Next.js 15. The real challenge wasn't just getting 3D shapes to render on a screen; it was making sure the visual flair never got in the way of a fast, smooth user experience.
The Vision: Tactile and Engaging
The goal was to give visitors a sense of craftsmanship the moment they land on the page:
- Subtle interaction: 3D objects that gently respond to mouse sweeps and scrolling without distracting from the actual content.
- Immediate loading: Ensuring visitors aren't greeted with a 10-second loading screen just to read about my work.
- Mobile-friendly: A site that runs smoothly on a phone without draining the battery or lagging.
How It Comes Together
The application is built around three core layers:
- Next.js 15 (App Router): Handles the site structure, layout, and lightning-fast page navigation.
- React Three Fiber & Drei: Provides a declarative, React-friendly bridge to Three.js, making scene setup and lighting straightforward to maintain.
- Framer Motion: Ties the 2D text, cards, and transitions together with smooth micro-interactions.
// The 3D scene sits cleanly within a client component,
// running inside a standard Next.js page layout.
export function CanvasShell({ children }: { children: React.ReactNode }) {
return (
<Canvas
camera={{ position: [0, 0, 5], fov: 45 }}
gl={{ antialias: true, alpha: true }}
>
{children}
</Canvas>
);
}
Keeping It Lightweight
Bringing WebGL to a website often gets a bad reputation for bloated loading times and choppy frame rates. A few simple rules kept everything snappy:
- Lazy loading the canvas: The primary text and project links load immediately; the 3D scene hydrates smoothly right behind them.
- Low-poly assets: Relying on clever lighting and materials rather than heavy 3D models with millions of polygons.
- Capping device demands: Tuning pixel ratios so high-density mobile screens aren't forced to render unnecessary GPU overhead.
What’s Next
Adding 3D to my portfolio turned a weekend redesign into a fun study of modern web graphics. It gave the site an identity that reflects what I enjoy building: interfaces that are responsive, interactive, and fun to explore.
Check out the live portfolio to see it in action, and feel free to reach out if you're experimenting with Web3D yourself!