Isomorphic, Universal, and SEO — Concept Overview
Isomorphic JavaScript running the same on server and client, and the server-side rendering principles that make SEO possible for modern JS apps.
Restored from a 2020-04 archive. Preserved with the terminology and perspective of that time.
Isomorphic
"Isomorphic" describes JavaScript code that behaves identically on both server and client.
For example, jQuery on the client and jQuery loaded by Node.js on the server expose the same API. It isn't perfectly identical, but the backend and frontend can use the same API and get the same result.
Universal
As JavaScript began running not just on servers and browsers but on many other devices, some community members started preferring the term "Universal" over "Isomorphic".
Most modern JavaScript platforms render into markup like <div id="app"></div>. Templates and components are all compiled into a single JavaScript bundle, and at render time the bundle is parsed and the resulting markup is appended to the predefined mount point.
The problem: an initially empty HTML is invisible to SEO crawlers.
SEO (Search Engine Optimization)
SEO is the practice of structuring web pages so they rank high in search engine results. The core approach is to place relevant keywords appropriately and earn incoming links from other sites — Google and its peers treat link popularity as a trust signal.
Korean portals like Naver apply their own ranking rules, sometimes flagging globally optimized pages as spam in favor of their in-platform blog content. To reach Naver users, content often needs to live on a blog-style CMS rather than a plain web document.
SEO Implementation Example
Build components that can run on both server and client. On the server, use renderToString to produce real HTML markup in the response. That markup is then delivered to the client — crawlers see a fully rendered page.
When the user navigates (e.g. from the list to post 77 on /bbs/77), the router (like react-router) handles it seamlessly. Server-side processing returns the markup for /bbs/77; the client's React then hydrates and takes over. Direct URL access to /bbs/77 also works because the server produces the same markup.
SSR Fundamentals
1. Search Engine Optimization
React and other JS-heavy apps produce empty <div id="root"></div> shells unless the JS engine runs. Client-only rendering means crawlers without JS support see empty pages. Google has a JS-capable crawler, but Naver and others may not.
SSR makes the initial HTML readable to every crawler.
2. Performance
SSR delivers pre-rendered HTML to the client, so users can see content before JavaScript finishes loading and hydrating. Perceived load time drops significantly.
3. Mitigating Server Load
Server-side rendering shifts work from client to server, which raises CPU usage. ReactDOMServer.renderToString is synchronous and blocks the event loop during rendering.
| Tool | Description |
|---|---|
| rapscallion | Async renderToString, Promise-based, per-component caching |
| hypernova | Airbnb's render cluster — separate rendering server, multi-process |
| react-router-server | Async SSR with promise-based data loading |
4. Meta Tags Only
Instead of full SSR, you can inject route-specific meta tags on the server so crawlers pick up basic page info. Especially useful for social media sharing previews.
Guestbook
Leave a short note about this post
Loading...