Announcements

Next.js 16.3 Preview Focuses on Turbopack Memory and Build Optimization

Next.js 16.3 Preview introduces memory eviction for development servers, persistent build caching, and an experimental native Rust React Compiler.

A
AIDeveloper44 Team
June 30, 2026·5 min read
Next.js 16.3 Preview Focuses on Turbopack Memory and Build Optimization

Next.js 16.3 focuses on compiler performance, memory eviction, and caching in Turbopack.

TL;DR
  • Turbopack memory eviction in dev mode reduces RAM usage by up to 90% by offloading cache to disk.
  • Persistent file system caching is now available for production builds, significantly lowering compile times.
  • An experimental Rust-based React Compiler replaces the Babel transform, offering 20-50% faster compilation.
  • Next.js 16.3 adds Vite-compatible import.meta.glob support for pattern-matching module imports.

Vercel has released the Next.js 16.3 Preview for public testing, with a stable release planned in the coming weeks. While previous updates focused on routing and AI integrations, version 16.3 targets the performance of the Turbopack bundler. The latest iterations introduce architectural changes designed to reduce CPU and memory usage, accelerate build times, and streamline the runtime experience for developers managing large repositories.

Development Server Memory Eviction

Turbopack operates on a model of incremental compilation, meaning it caches previous work to avoid recompiling unchanged files. Historically, this design traded memory usage for CPU efficiency. The system kept cached data in active memory, which caused consumption to scale linearly with the number of routes visited during a development session. When combined with other concurrent development tools like language servers, linters, and typecheckers, this caused high memory pressure on local machines.

Next.js 16.3 addresses this limitation by introducing memory eviction for the development server. By building upon the file-system persistence introduced in version 16.1, Turbopack can now automatically remove cached results from active memory and offload them to disk. This prevents unbounded memory growth during long-running sessions.

According to Vercel's benchmarks, this results in up to a 90% reduction in memory usage after compiling 50 routes. For example, local development memory for the Vercel dashboard dropped from 21.5 GB to 2 GB, while nextjs.org decreased from 4,600 MB to 840 MB. Memory eviction is enabled by default in 16.3, provided the development filesystem cache is active. It can be deactivated for debugging purposes using the turbopackMemoryEviction: false configuration.

Persistent File System Cache for Production Builds

The persistent disk cache, previously limited to development environments, has been extended to the next build command. This feature allows production builds to utilize previously computed work, directly reducing the time required to compile static assets.

Initial data from Vercel's internal sites indicates measurable improvements. Cached build times for nextjs.org dropped from 21 seconds to 9.2 seconds, and vercel.com/geist improved from 30 seconds to 5.5 seconds. This update is particularly relevant for Continuous Integration (CI) environments, as developers can persist the .next directory across pipeline runs. When Turbopack detects the cache at the start of a build, it reads the disk entries before compiling new modifications. This feature is opt-in and requires setting turbopackFileSystemCacheForBuild: true in the Next.js configuration.

Diagram: Turbopack architecture showing memory eviction and persistent disk caching flows.

Integration of the Native Rust React Compiler

Next.js 16.0 introduced stable support for the React Compiler via a Babel transform. However, relying on JavaScript execution resources to process the transform introduced a bottleneck in larger repositories. Following the React team's release of a native Rust port of the compiler, Next.js has integrated it directly into Turbopack.

By moving the compiler execution out of the Node.js event loop and into native Rust code, Vercel reports compilation speed improvements of 20% to 50% on large React applications. This integration remains experimental in 16.3. Developers can test it by enabling both reactCompiler: true and turbopackRustReactCompiler: true in their configurations.

Vite-Compatible import.meta.glob Support

Version 16.3 adds support for import.meta.glob, a Vite-compatible API that permits developers to import multiple modules using pattern matching (e.g., import.meta.glob('./posts/*.mdx')). This removes the need to hardcode file names when fetching sets of related documents, such as blog posts or product markdown files.

The API returns an object where keys are the file paths and values are asynchronous loader functions, though it also accepts an eager: true parameter to import matches immediately. The implementation relies on Turbopack's file watcher, meaning that adding or removing a matched file will instantly trigger recompilation in development mode. The feature works exclusively with Turbopack and is incompatible with --webpack builds.

HMR and PostCSS Configuration

Hot Module Replacement (HMR) subscriptions have been streamlined in 16.3. Turbopack now consolidates multiple subscriptions into a single track for chunks loaded on a page. This specific adjustment has reduced development server cold start times by over 15% in complex applications.

Runtime payload sizes have also been optimized. Turbopack no longer ships generalized runtime code to every route. Instead, it conditionally delivers features like WebAssembly loading, workers, and top-level asynchronous modules only when a route explicitly requires them.

Finally, for monorepos requiring distinct CSS processing pipelines, 16.3 introduces the experimental turbopackLocalPostcssConfig option. This allows Turbopack to resolve package-level PostCSS configurations rather than strictly falling back to the project root, providing finer control over CSS module transformations across disparate workspace packages.

Enjoyed this?

Get more posts like this delivered to your inbox.