When You MUST Use Client: Interactivity
What you'll learn: You'll understand exactly when React forces you to add 'use client' — any time you need state, effects, or user interaction.
The Server's Limitation
Server Components run once on the server and produce output. They can't "remember" anything between renders, can't respond to clicks, and can't run side effects. They're like a one-way street: data flows in, HTML flows out, done.
The moment you need interactivity — something that responds to the user or changes over time — you've crossed into territory that requires JavaScript running in the browser.
The Client-Only Features
If your component uses any of these, you must mark it (or its parent module) with 'use client':
useState— managing any kind of local state (counters, toggles, form inputs)useEffect— running side effects after render (timers, subscriptions, browser APIs)- Event handlers —
onClick,onChange,onSubmit, etc. - Other hooks that manage state —
useReducer,useRef(for mutable values),useContext(when reading from a provider)
The Mental Model
Think of it this way: if a component needs to "remember" something between renders or "react" to user input, it needs a brain that stays alive — that's the client runtime. Server Components have no memory and no ongoing lifecycle.
Buttons that toggle visibility? Client. Forms that track input? Client. Components that fetch data on mount with useEffect? Client. A static blog post with no interaction? Server is perfect.
Key Takeaway: Any component using useState, useEffect, event handlers, or stateful hooks requires 'use client' — interactivity lives in the browser, not on the server.