Next.js 9: static, fast, considered
Next.js 9 brought API routes and automatic static optimization — finally making hybrid static and server-rendered sites effortless.
I love working with React, but the blunt question — "how does this actually get to the server, fast?" — followed me for a long time. Next.js was already my answer before. Yet version 9, released this summer, feels like the moment the framework truly grows up.
Automatic static optimization
The most important step for me: Next.js now detects on its own which pages need no server-side data and renders them automatically as static HTML. I don't have to configure anything. A page without getInitialProps is served statically — lightning fast, cacheable, with no live server render.
The best performance optimization is the one I never have to think about.
And the beauty of it: it isn't an either-or. On the same site a static landing page can sit right next to a data-driven, server-rendered route. That hybridity is exactly what real projects need — because a website is almost never fully static or fully dynamic.
API routes, without a separate backend
The second big win is API routes. A file under pages/api/ becomes an endpoint:
export default function handler(req, res) {
res.status(200).json({ name: "Max" });
}
For a contact form, a newsletter handler, or a small data query, I no longer need a separate backend. Front and back live in the same project, in the same language, with the same deployment. For the smaller brand and portfolio sites I often build, that's an enormous simplification.
What excites me about Next.js 9 isn't a single feature, but the attitude behind it. The framework makes sensible default decisions, yet hands me control whenever I need it. It takes the boring work off my plate and leaves me the interesting part.
Fast sites aren't a luxury, they're respect for the people who visit them. Next.js 9 makes it easier to deliver on that respect — and that's exactly why it's becoming my default tool for React projects.