Lesson 2.211mIntermediate14.5k students
The "use client" boundary
The directive does not mark one component as interactive — it marks the entry point to a client subtree. Everything imported below it goes to the browser too.
This lesson sits in Server and Client Components, part of Next.js App Router in Depth. It assumes what came before it and leads directly into the next lesson in the module.
In this lesson you will
- Place the directive at the boundary, not on every file
- Push interactivity to the leaves to keep the bundle small
- Spot the accidental import that drags the server tree client-side
Pro tip
If a whole page turned into a client component, look for one interactive import near the top of the tree.
Resources
Your notes for this lesson will appear here.