Back to blogs
What's New in Nextjs 15 - A Comprehensive Overview
Jatin Rai's avatar
Jatin Rai

5 days ago3 min read

Nextjs 15React 19Dev ToolsFullstack DevelopmentPerformance optimizations

What's New in Nextjs 15 - A Comprehensive Overview

Next.js continues to evolve as a go-to React framework for developers, and version 15 is packed with innovative features that enhance performance and improve development workflows. This release has made updates across server-side rendering, caching, and more, building on the solid foundation of Next.js 14. Here's a breakdown of what's new in Next.js 15 and how these changes can impact your projects.

1. Enhanced Async Request APIs

One of the major updates in Next.js 15 is the move to asynchronous access for server-side requests. Traditionally, data like cookies, headers, and params were fetched synchronously. Now, these can be accessed asynchronously, which improves server performance by separating data fetching from rendering. Here's an example:

import { cookies } from "next/headers";

export async function AdminPanel() {
  const cookieStore = await cookies();
  const token = cookieStore.get("token");
  // Your logic here
}

This update lets pages render without waiting for all server data to be fetched, potentially leading to faster load times.

2. Revamped Caching Model

Caching has been rethought in Next.js 15. Unlike previous versions where caching was default for fetch requests and GET route handlers, the new model requires developers to manually set caching rules. This change enables precise control over caching behavior:

fetch('https://api.example.com/data', { cache: 'force-cache' | 'no-store' });

This approach offers more flexibility and can be optimized for specific use cases, but be aware that existing code might need updating to accommodate these changes.

3. Compatibility with React 19

Next.js 15 introduces support for the React 19 release candidate, aligning with the latest React features, especially within the App Router. This compatibility allows developers to take advantage of new optimizations React offers. However, for stability, the Pages Router still relies on React 18, which is a detail to keep in mind as React 19 remains experimental.

4. Improved Developer Tooling

Next.js 15 comes with several developer-friendly tools, such as:

  • The @next/codemod CLI: This tool automates upgrades and configuration adjustments, simplifying the process of moving between versions.
  • Static Route Indicator: A visual indicator for distinguishing between static and dynamic routes in development. This can be disabled in the nextConfig file if desired:
const nextConfig = {
  devIndicators: {
    appIsrStatus: false,
  },
};
export default nextConfig;
  • New next/form Component: This new addition extends the HTML form element, making it easier to create forms with built-in support for client-side navigation and prefetching.

5. Bundling and Turbopack Enhancements

With Turbopack becoming more stable in this version, Next.js 15 promises a smoother development experience. Running next dev --turbo now improves local server startup times and supports code updates with Fast Refresh, all designed to make development more efficient.

For those concerned with production readiness, Turbopack is still recommended for development, with full production capabilities expected in future updates.

6. New Experimental Features

Next.js 15 also introduces after() an experimental API that allows scheduling tasks after rendering completes. This API can be useful for logging, analytics, or other non-blocking tasks that benefit from being processed post-render:

export function after() {
  // Scheduled work here
}

This feature is experimental, so it may evolve in future releases as feedback is gathered.

Is Next.js 15 Right for You?

Next.js 15 brings forward-thinking updates to streamline development and maximize performance. However, with some breaking changes, it's essential to assess how these new features might impact your current codebase. If you're ready to experiment with React 19 features, and your project could benefit from async server handling or caching control, then Next.js 15 could be a worthwhile upgrade.

Conclusion

Next.js 15 exemplifies the framework's commitment to modernizing the developer experience with advanced, flexible features. By embracing asynchronous data handling, manual caching controls, and new tooling options, this release is well-suited for developers aiming to push performance boundaries while taking advantage of the latest in React.

As always, remember to check out the official documentation for in-depth information on these features.

Thank you for reading!