React 19 Server Components vs Client State Management
A practical mental model for when to use Server Components, Server Actions, and client hooks.
The Shift in Mental Model
In React 18 and 19 App Router architecture, the default boundary moves to the server.
Component Rule Matrix
| Requirement | Component Type | Implementation |
| :--- | :--- | :--- |
| Database access / Secret keys | Server Component | async function Page() |
| Interactive state (useState) | Client Component | "use client" |
| Event handlers (onClick) | Client Component | "use client" |
| Server Mutations | Server Action | "use server" |
// Server Action Example
export async function likeArticle(postId: string) {
"use server";
const session = await auth();
if (!session?.user) throw new Error("Unauthorized");
return await db.like.create({
data: { postId, userId: session.user.id }
});
}
Performance Takeaways
- Zero Bundle Impact: Dependencies imported exclusively in Server Components add 0 bytes to the client JavaScript bundle.
- Streaming Suspense: Wrap heavy async database queries in
<Suspense>to send instant shell HTML to the browser.
Lead Software Architect, Writer & Thinker exploring Technology, Science, Code, Ideas, and Words.
More from CODING
I Stopped Asking AI to Write My Code — This Workflow Worked Better
AI can write code faster than most beginners. That doesn't mean you should let it write everything. A better workflow is to make AI handle repetition while you keep control of the decisions.

Discussion (0)
Sign in to join the discussion, reply, and tag authors.
No comments yet. Be the first to start the discussion!