SPA, MPA or Server-Rendered: Choosing a Web App Architecture
A plain comparison of multi-page apps, single-page apps and server-side rendering with hydration: what each costs in SEO, speed, complexity and team skills, and the hybrid options that often win.

The web app architecture you pick in the first week decides how many codebases you maintain, whether search engines can read your pages without extra work, and who you can hire to change the product three years from now. It is usually argued as a framework question, React or no React. The real question is simpler: where is the HTML produced?
Below are the three common answers, the hybrids between them, and five checks that turn the decision into an afternoon's work.
Three places to build the page
- Multi-page application (MPA). The server builds a complete HTML page for every request. Laravel with Blade templates, CodeIgniter views and WordPress themes all work this way. JavaScript is added where a page needs it.
- Single-page application (SPA). The server sends one nearly empty HTML shell and a JavaScript bundle. The browser draws every screen and fetches data from an API as JSON. React, Vue and Angular are the usual tools.
- Server-side rendering with hydration (SSR). A JavaScript framework runs on the server to produce real HTML for the first request, then the same code starts up in the browser, attaches itself to that HTML and behaves like an SPA from then on. Next.js and Nuxt are the best-known examples. Static generation is the same idea done once at build time.
How the three compare
| MPA | SPA | SSR with hydration | |
|---|---|---|---|
| First page load | Fast, the HTML arrives ready to read | Slower, scripts must download and run before content appears | Fast to appear, usable once the scripts have started |
| Moving between screens | A full page request each time | Immediate, only data is fetched | Same as an SPA after the first load |
| Public pages in search | Works with no extra effort | Depends on the crawler running JavaScript | Works with no extra effort |
| Codebases | One | Two, an API and a client | One or two, plus a Node.js process on the server |
| Hosting | Any PHP host | An API host plus static files | A Node.js server or a platform built for the framework |
| Best suited to | Content sites, stores, admin panels, most business software | Tools people keep open for hours behind a login | Public, content-heavy products that also need app-like interaction |
Search visibility depends on the first response
A crawler that receives finished HTML can index it straight away. A crawler that receives an empty shell has to run your JavaScript first. Google does this: its documentation describes crawling, rendering and indexing as separate phases, with pages queued for rendering after they are fetched. The same documentation still calls server-side rendering or pre-rendering a good idea, because it is faster for users and crawlers and because not every bot runs JavaScript. The details are in Google's JavaScript SEO basics.
That last point is the practical one. Most link-preview fetchers, the ones that build the card when someone pastes your address into a chat or a social post, read the raw HTML only. In a plain SPA every route shares the shell's title and description, so every shared link looks the same.
If you do build public pages as an SPA, three things are not optional: real paths through the History API instead of # fragments, a genuine 404 status for pages that do not exist, and a unique title and description per route.
The opposite mistake is just as common. If the whole product sits behind a login, search engines never see it, and SEO should carry no weight in the decision.
Speed means two different numbers
One number is how long the first screen takes to appear and respond. The other is how long each action takes after that. An MPA wins the first, because the browser can paint HTML as it arrives. An SPA wins the second, because moving between screens needs a small data request and no new page.
SSR tries to win both and pays for it with hydration. The page looks ready when the HTML lands, but buttons do nothing until the JavaScript has downloaded and run, and the browser repeats work the server has already done. Google's article on rendering on the web notes that this can hurt responsiveness even while it improves the first paint. On a mid-range phone the gap between "looks ready" and "is ready" is easy to notice.
Two more things follow. An SPA's bundle grows with every feature unless someone splits it by route. And an MPA's full page loads cost less than people assume when the server answers quickly and static files are cached.
The cost that is missing from the diagram
An SPA is two applications. Compared with a server-rendered app, you take on:
- routing in two places;
- validation twice, in the client for the user's benefit and on the server for safety;
- authentication across the boundary, with tokens or cookies, CORS and CSRF to get right;
- state held in the browser that has to be kept in step with the server;
- two deployments that must stay compatible, since a tab left open since yesterday still runs the old client against the new API.
In return you get an API, which is valuable if a mobile app or partner integration needs one anyway. SSR adds its own items: a Node.js process to run and monitor, code that must behave the same in two environments, and bugs where server and browser disagree about the markup.
Team shape matters as much as technology. A PHP team can ship and maintain an MPA alone. An SPA needs people who are good at front-end engineering, not back-end developers who tolerate it. Three developers split across two codebases move more slowly than three in one.
Hybrids that take most of the benefit
Islands of JavaScript in server-rendered pages
Keep the MPA and mount a Vue or React component only where a screen earns it: a booking calendar, a drag-and-drop board, a price calculator. Everything else stays simple HTML.
HTML over the wire
Livewire in Laravel, Hotwire and htmx let the server render fragments of HTML that a small script swaps into the page. You get live validation, filters and modals without writing an API. The limit is that every interaction is a round trip to the server, so this approach does not suit offline use or heavy in-browser tools.
Inertia
Inertia keeps Laravel's routes and controllers and renders pages as React, Vue or Svelte components, all in one repository and without a separate API. It can also render on the server. The Laravel frontend documentation sets out this option next to Livewire. The trade-off is that the front end is tied to that back end, and no public API falls out of the work.
Split by area
Serve the marketing site, pricing and documentation as server-rendered or static pages, and run the application itself as an SPA on its own subdomain behind the login. Each part gets the architecture that suits it.
Five checks that settle most web app architecture decisions
- Must the important pages rank, or look right when shared? Then the server has to send real HTML: an MPA or SSR.
- Is the product forms, lists and reports, or a tool people manipulate? Forms and lists suit an MPA with one of the hybrids. Editors, boards and real-time dashboards justify an SPA or Inertia.
- Do you need the API anyway? If a mobile app or third parties will use it, part of the SPA's cost is already being paid.
- Must it work offline or on poor connections? That points to an SPA built as a progressive web app. We compare that route with native apps in progressive web app or native app.
- Who maintains it in three years? Choose what that team is fluent in, not what the launch team found interesting.
When the answers are mixed, start server-rendered with Livewire or Inertia. Moving one screen to a richer client later is a contained job. Removing an SPA that turned out to be unnecessary is a rewrite.
When a second opinion pays for itself
A small team building a conventional product can make this call with the checks above. It is worth an outside review when the product has both a public side that must rank and a complex application behind it, when a mobile app is planned and the API has to serve both, or when an existing SPA has become slow to change and you are deciding whether to keep it. Architecture is the first conversation in our web application development projects. Where a JavaScript front end is the right call, we build it as Laravel with React or Vue, and where the interface needs a contract other systems can rely on, the work starts with API design.
Frequently asked questions
Is server-side rendering the same thing as a multi-page app?
No. Both send finished HTML, but an MPA builds a new page on the server for every navigation, while SSR with hydration sends HTML once and then hands control to a JavaScript application in the browser. SSR therefore carries the client-side code and complexity of an SPA as well.
Can the architecture be changed later?
In one direction, fairly easily. A server-rendered application can gain API endpoints and richer screens one at a time. Going from an SPA back to server rendering means rebuilding every screen, so it is rarely done unless the product is being rewritten anyway.
Where does WordPress fit in?
A standard WordPress site is a multi-page application: PHP builds each page on the server. Running WordPress as a content API behind a JavaScript front end turns it into the SPA or SSR model, with the same gains and costs described here. Our article on headless WordPress covers that case.
Add worldwincoder.com as a preferred source on Google, or open this article in your AI assistant to use it as a source.
