What Server-Side Rendering Actually Means
You'll learn the core definition of SSR: rendering React components to HTML strings on the server before the browser ever sees them.
The Core Concept
Server-Side Rendering (SSR) means your React components execute on the server, producing HTML markup that gets sent to the browser as a complete page. Instead of shipping an empty HTML shell with a JavaScript bundle that builds the page in the browser, the server does the rendering work first.
Think of it like a restaurant: Client-side rendering is ordering ingredients delivered to your home—you cook the meal yourself. SSR is ordering a fully prepared meal—it arrives ready to eat, though you might add garnish (interactivity) after.
What Actually Happens
When a request comes in:
- React components run on the server
- They produce HTML strings (not DOM nodes)
- The server sends complete, populated HTML
- The browser displays content immediately
- JavaScript hydrates the page later for interactivity
The user sees meaningful content before JavaScript downloads or executes. This contrasts with traditional SPAs where users stare at spinners while JavaScript builds the entire page.
Why "Rendering" Is the Key Word
The term "rendering" here means the same process React always does—taking your JSX and creating output. The difference is where: server vs browser. The component logic runs server-side, accessing backend resources directly, then converts to HTML for transmission.
SSR doesn't mean "no JavaScript"—it means HTML first, JavaScript later. The page works immediately, then becomes interactive.
Key Takeaway: Server-Side Rendering means React components execute on the server to produce HTML strings sent to the browser, enabling users to see content before JavaScript loads.