Next.js 14: Server Actions, Turbopack and Partial Prerendering for production
Next.js 14 is a release focused on performance and DX (developer experience), especially with three main pillars:
- Server Actions (stable) – simplifies mutation & form handling, reducing client-side JS.
- Turbopack – extremely fast dev server, gradually replacing Webpack in development.
- Partial Prerendering – combines static + dynamic on the same page, optimizing Core Web Vitals.
In this article, I won't just list new features, but also suggest when to use, when to avoid, and how to apply them to real-world applications.
1. Server Actions (stable) – Goodbye to small API routes
1.1. What are Server Actions?
In Next.js 14, Server Actions are stable, allowing you to:
- Send form / trigger mutation directly to server component.
- No need to create numerous API routes just for
create/update/delete. - Reduce JavaScript sent to client → good for performance & SEO.
Instead of:
- Creating file
app/api/posts/route.ts - Calling
fetch('/api/posts', { method: 'POST' })from client
You can write directly like this:
async function createPost(formData: FormData) {
'use server';
const title = formData.get('title');
const content = formData.get('content');
if (!title || !content) {
throw new Error('Title and content are required');
}
// Handle post creation logic
await db.post.create({
data: { title: String(title), content: String(content) },
});
}
And in component:
export default function CreatePostForm() {
return (
<form action={createPost} className="space-y-4">
<input name="title" placeholder="Title" />
<textarea name="content" placeholder="Content" />
<button type="submit">Create Post</button>
</form>
);
}
1.2. When to use Server Actions?
Use when:
- Simple forms: login, registration, creating posts, contact forms.
- You want to reduce client JS and don't need complex SPAs.
Consider/Avoid when:
- You have a separate client app (mobile / SPA) that needs to reuse API → prefer REST/GraphQL.
- You need API versioning, public API for third parties.
2. Turbopack – extremely fast dev server but still Beta
Turbopack has been advertised heavily for its speed:
- 🚀 5x faster server startup.
- ⚡ 700x faster updates with Fast Refresh.
- 📦 4x faster code bundling.
To enable Turbopack for development, you can use:
next dev --turbo
Or config in package.json:
{
"scripts": {
"dev": "next dev --turbo"
}
}
2.1. When to enable Turbopack?
- Medium–large projects where Webpack build/dev is very slow.
- You've checked that custom plugins/babel/loaders don't depend on Webpack.
Note:
- Turbopack is still in Beta and might encounter bugs with complex setups.
- Test carefully before applying for large teams / critical projects.
3. Partial Prerendering – static and dynamic on the same page
Partial Prerendering allows:
- The "shell" of the page (header, hero, layout) is prerendered (SSG).
- Dynamic parts (e.g., realtime stats, personalized feeds) will be streamed in later.
Simple example:
import { Suspense } from 'react';
import { StaticComponent } from './static-component';
import { DynamicComponent } from './dynamic-component';
import { Skeleton } from './skeleton';
export default function Page() {
return (
<div>
<StaticComponent />
<Suspense fallback={<Skeleton />}>
<DynamicComponent />
</Suspense>
</div>
);
}
The idea:
- Google bot and users see main content very quickly (static shell).
- Dynamic parts don't block rendering and are streamed down later.
3.1. Practical Application
You can apply Partial Prerendering for:
- Blog pages: main content is static, "related posts" block is dynamic.
- Dashboard: static layout + menu, dynamic data tables.
- Marketing landing page: static hero section, dynamic testimonial/metrics.
4. Performance & Core Web Vitals Improvements in Next.js 14
Besides flagship features, Next.js 14 also improved:
- Reduced ~53% memory usage in some workloads.
- Smarter caching for data fetching.
- Smaller bundles, especially when combined with Server Components.
If you care about:
- PageSpeed / Lighthouse / Core Web Vitals for SEO.
- Time-to-interactive on mobile / 3G.
... then:
- Leveraging Server Components + Server Actions,
- Limiting heavy logic on client,
- And properly separating static/dynamic with Partial Prerendering
will bring clearer effectiveness than just build-time optimizations.
5. Should you upgrade to Next.js 14 now?
Upgrade early if:
- You are already using Next.js 13 App Router.
- You want to leverage stable Server Actions and faster Turbopack dev.
- You have a blog/portfolio/landing page needing SEO & speed optimization (like
newnol.io.vn).
Consider if:
- Old project running large Pages Router, many plugins/custom Webpack.
- CI/CD, monitoring, error tracking systems aren't ready for major changes.
Safe Upgrade Strategy:
- Create new branch, upgrade Next.js to 14.
- Enable Turbopack for development first, keep old production build.
- Start refactoring pages to App Router + Server Components if not used yet.
- Use
PageSpeed InsightsandLighthouseto compare before–after.
6. Quick FAQ about Next.js 14
Is App Router mandatory in Next.js 14?
No, but most new features (Server Actions, Partial Prerendering…) are only in App Router. If it's a new project, start straight with App Router.
Do Server Actions replace REST/GraphQL entirely?
No. They are great for UI-driven mutations inside Next.js apps, but you still need "standard" APIs if:
- You have mobile apps / other services calling the same backend.
- Need public API for third parties.
Conclusion
Next.js 14 isn't just a "for fun" update, but a major step to:
- Push more logic to server (Server Actions, Server Components).
- Increase dev speed (Turbopack).
- Improve user experience & SEO (Partial Prerendering, Core Web Vitals optimization).
If you are building a portfolio, technical blog, or light–medium production apps, upgrading and gradually applying these features will bring clear benefits in speed, DX, and Google search rankings.
Tags: Next.js, React, Web Development, JavaScript, Performance


