February 14, 2022

How JavaScript Frameworks Changed Website Archiving Forever

blog image

The Web That Used to Be Simple

In the early 2010s, most websites worked in a straightforward way. A visitor typed a URL into their browser, and the browser sent an HTTP request to a web server. The server, running PHP, ASP.NET, Ruby on Rails, or a similar technology, assembled a complete HTML page and sent it back. The browser received a fully formed document with all the text, images, and layout instructions already present in the HTML source code.

Archiving these websites was relatively simple. A web crawler could request each URL, receive the complete HTML response, download the associated stylesheets and images, and store everything in a WARC file. The archived page looked essentially identical to the live page because the content existed entirely in the server’s response. The challenge was mainly one of scale and completeness: following every link, capturing every resource, and storing everything correctly.

This era of server-rendered HTML was the foundation on which early web archiving technology was built. Tools like Heritrix (developed by the Internet Archive), HTTrack, and wget could traverse a website’s link structure, download pages, and produce usable archives. The technology worked because the web followed a simple model in which the server did the work and the browser displayed the result.

The arrival of JavaScript frameworks changed that model.

The Client-Side Revolution

The transformation began in the early 2010s and accelerated rapidly. AngularJS appeared in 2010. React was released by Facebook in 2013. Vue.js followed in 2014. Within a few years, these frameworks and their successors had changed how enterprise websites were built.

The new model inverted the traditional approach. Instead of generating complete HTML pages, the server now sends a minimal HTML document, often containing little more than a single empty <div> element and a reference to a JavaScript bundle. The JavaScript code executes in the visitor’s browser, makes API calls to fetch data, and constructs the page content in real time.

Here is what the HTML source of a modern React application often looks like:

<!DOCTYPE html>
<html>
<head>
  <title>Our Company</title>
  <script src="/static/js/bundle.js"></script>
</head>
<body>
  <div id="root"></div>
</body>
</html>

The entire visible content of the website, including the navigation, text, images, and interactive elements, is generated by JavaScript after the page loads. Viewing the source code shows an empty page, because the content is assembled by code running in the browser.

Why Traditional Crawlers See Nothing

The implications for web archiving were significant. A traditional HTTP crawler sends HTTP requests and stores the responses. When it requests a URL from a modern single-page application, it receives the minimal HTML shell shown above and stores that shell in a WARC file. When someone later opens the archive, they see an empty page.

The crawler worked as designed and captured what the server returned. The problem is that the server’s response is not the website. The website only takes shape when JavaScript executes in a browser environment.

This was far from an edge case limited to a handful of experimental websites. By the mid-2010s, major enterprises were rebuilding their web presence with these frameworks. Corporate sites, e-commerce platforms, financial service portals, news organisations, and government agencies all adopted client-side rendering, and the web as a whole was moving toward a model that traditional archiving tools could not handle.

Single-Page Applications: An Even Deeper Challenge

JavaScript frameworks also changed the concept of a “page” itself.

In a traditional website, every page has a unique URL, and navigating to that URL triggers a full page load from the server. In a single-page application (SPA), the initial page load is the only full load. After that, navigation happens within the browser. When a user clicks a link, JavaScript intercepts the click, fetches new data via API calls, and updates the visible content without the browser requesting a new page from the server.

The URL in the browser’s address bar may change (using the History API), giving the appearance of traditional navigation, yet from a network perspective no new page was requested. For a web crawler that discovers pages by following links and requesting URLs, an SPA can appear to be a single page with a single URL, even if it contains hundreds of distinct content sections.

Archiving a modern website therefore required more than downloading pages. It meant simulating user interaction: clicking navigation elements, waiting for content to load, scrolling to trigger lazy-loaded resources, and tracking client-side route changes.

The Rise of Browser-Based Archiving

The web archiving industry responded by rethinking how websites are captured. The answer was browser-based archiving. Instead of lightweight HTTP crawlers, archiving systems began using full browser engines to render websites as a human visitor would experience them.

Browser-based archiving works by controlling an actual web browser, typically a headless (no visible window) instance of Chromium or Firefox. The archiving system navigates to each URL, allows the JavaScript to execute, waits for the page to render fully, and then captures the complete state of the page, including all dynamically generated content.

This approach addresses the core problem of client-side rendering. Because the archiving system runs the same browser engine that real visitors use, it sees the same content. React components render, Vue applications initialise, and Angular modules load and display data. The archive records what was actually visible rather than the raw HTML shell.

Ongoing Complexity

Browser-based archiving did not settle the matter permanently. The web continues to evolve, and each new technique that makes websites more dynamic also makes them harder to archive.

Lazy Loading

Modern websites defer the loading of images and content until the user scrolls to them. An image below the fold does not exist in the page until the viewport reaches it. An archiving system must simulate scrolling behaviour, moving through the entire page, pausing to let content load at each position, and capturing resources as they appear.

Infinite Scroll

Some pages have no defined end. Social feeds, product listings, and news streams load additional content indefinitely as the user scrolls. An archiving system must determine how much content to capture and set reasonable boundaries for what constitutes a complete capture.

WebSocket Connections

Real-time features like live chat, stock tickers, and notification systems use WebSocket connections that maintain persistent, bidirectional communication between the browser and server. Content delivered through WebSockets is not part of a traditional HTTP request-response cycle, which adds complexity for capture systems that must record all content sources.

Service Workers

Service workers are scripts that run in the background, intercepting network requests and serving cached responses. They can significantly alter how a website loads and behaves, serving content that differs from what the server would normally return. An archiving system must account for service worker behaviour so that the captured content accurately reflects the live site.

Client-Side Routing with Dynamic Data

Modern frameworks combine client-side routing with dynamic data fetching in complex patterns. A single page component might make multiple API calls based on URL parameters, user state, and browser capabilities, assembling content from various sources. Capturing the complete state requires the archiving system to understand and reproduce these data-fetching patterns.

Framework-Specific Rendering Patterns

Next.js, Nuxt.js, and similar meta-frameworks have introduced hybrid rendering strategies. Some pages are server-rendered, some are statically generated at build time, some are rendered on the client, and some combine all three approaches. An archiving system must handle each rendering strategy correctly, which requires a detailed understanding of how modern web frameworks deliver content.

How Aleph Archives Handles the JavaScript Challenge

Aleph Archives has been archiving websites since 2010. We followed the shift to JavaScript frameworks from the beginning and have continuously developed our technology to keep pace.

Our archiving platform uses full browser-based rendering to capture each website as it actually appears. When we archive a React application, our system executes the JavaScript, waits for all components to render, handles asynchronous data loading, and captures the complete visual and interactive state of every page.

Rendering JavaScript is only the first step. Our system also handles lazy loading by simulating scroll behaviour across entire pages, and it manages client-side routing by discovering and navigating all internal routes. It captures resources loaded through dynamic imports, WebSocket connections, and service worker caches, and it produces ISO 28500-compliant WARC files with SHA-256 and RIPEMD-160 cryptographic verification.

After fifteen years of continuous development, our technology handles the full range of modern web complexity. We actively track and address each new JavaScript framework, rendering pattern, and browser feature. Because web archiving is our only business, adapting our capture technology to changes in the web is our main engineering priority rather than one item among many.

The Lesson for Organisations

If your website is built with React, Angular, Vue, Next.js, Nuxt, or any modern JavaScript framework, your choice of archiving provider matters more than ever. A provider using traditional crawling technology may be capturing empty shells instead of complete pages. A provider that has invested in browser-based archiving will capture your website as it actually appears.

The gap usually becomes visible only when the archive is needed, in a compliance audit, a legal dispute, or an internal review. At that point, an empty HTML shell provides no usable evidence, while a complete and faithful reproduction of the website does.

If you want to verify how your website is being archived, contact us for a complimentary assessment. We will show you what your current archive captures and what it might be missing.

See the Most Complete Web Archives in Action

Schedule a 15-minute demo to discover how Aleph Archives automates regulatory web archiving for your organisation.

See the Most Complete Web Archives in Action