# Single-Page Application (SPA)

> A web app that loads one page once, then changes it with JavaScript.

**Field:** Software Development  
**Category:** Web Development  
**Also known as:** SPA, Single Page App

## Think of it like

Think of it like a puppet show with one stage. The puppets change, but the stage stays put.

## Definition

A single-page application loads one web page once and then changes it with JavaScript. When you click a link, the app swaps out part of the page instead of loading a new one. It asks the server only for data, not for whole pages. This makes moving around feel fast, like a phone app. The first load can be slow, because the browser must fetch all the code first.

## Example

Lucy's email in the browser is an SPA. When she opens a message, only the middle part of the screen changes.

## Why it matters

SPAs feel smooth and quick once loaded. Many web apps are built this way.

## Common mistake

Making a simple content site an SPA. Search engines and slow phones both handle plain pages better.

## Three principles

- **One page.** Loaded once, then changed.
- **Data, not pages.** Only data comes from the server.
- **Slow first load.** All the code comes up front.

## Related terms

- [Client-Side Rendering (CSR)](https://learn.benibix.com/term/development/client-side-rendering)
- [Server-Side Rendering (SSR)](https://learn.benibix.com/term/development/server-side-rendering)
- [Web Routing](https://learn.benibix.com/term/development/routing)
- [Web Application](https://learn.benibix.com/term/development/web-application)
- [Single-Page Website](https://learn.benibix.com/term/design/single-page-website)

## Told apart from

- [Single-Page Website vs Single-Page App](https://learn.benibix.com/compare/single-page-website-vs-single-page-application): People think a one-page website is a single-page app, and it is not. A single-page website is a design choice: all the content sits in one long scroll. A single-page app is a way to build a web app, where the page swaps its parts without loading a new page. An app built that way can have hundreds of screens.

---

Source: https://learn.benibix.com/term/development/single-page-application
Author: Behnia Zarei (a developer in Vienna, Austria, who builds and teaches data, AI and business intelligence at BENIBIX)
Publisher: BENIBIX Learn (https://learn.benibix.com/)
Last updated: 2026-11-19
Licence: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Quote freely with attribution.
