ExperienceProjectsBlogsAboutContact

New Features in Next.js v15

Next.js v15 introduces a range of significant updates, focusing on performance, developer experience, and alignment with the latest React features. Here's a breakdown of the most notable additions and changes:
August 5, 2025

1. Full Support for React 19 (Release Candidate)

Next.js v15 aligns with the React 19 Release Candidate, bringing its new features and improvements to the framework. This includes:

  • New Hooks:
    • useActionState: Helps manage and display the state of ongoing server actions in the UI.
    • useFormStatus: Ideal for tracking form submission states in real-time, allowing for UI updates like disabling a button during submission.
  • Owner Stacks: Improved error debugging with higher fidelity into where errors are originating, pinpointing the exact subcomponent responsible.

2. Updated Caching Strategies (Breaking Changes)

To provide more predictable behavior and better performance, Next.js v15 changes default caching behaviors:

  • No More Automatic Caching for fetch and Route Handlers:
    • fetch Requests now default to a no-store strategy. Explicit cache parameters are required to enable caching.
    • GET Route Handlers are no longer cached by default. You can opt into caching using export dynamic = 'force-static'. Special Route Handlers like sitemap.ts, opengraph-image.tsx, and icon.tsx remain static by default unless they use dynamic functions.
  • Client Router Caching Adjustments:
    • Page components are no longer cached by default in the client router, ensuring real-time data updates during in-app navigation.
    • The experimental.staleTimes flag is still available for manual configuration of client-side caching.

3. Asynchronous Request-Specific APIs (Breaking Changes)

Several request-specific APIs are now asynchronous, which is a breaking change but allows for better performance by enabling components to be pre-rendered:

  • cookies()
  • headers()
  • draftMode()
  • params (in layout.js, page.js, route.js, etc.)
  • searchParams (in page.js)

Codemods are available to help automate the migration of existing synchronous usages.

4. Introducing the New <Form> Component

Next.js 15 introduces an enhanced <Form> component that extends the traditional HTML <form> element with:

  • Prefetching: Improves navigation speed.
  • Client-side Navigation: Seamless transitions between pages.
  • Progressive Enhancement: Forms remain functional even if JavaScript isn't loaded.

5. Turbopack: Turbocharged Development and Builds

Turbopack, Next.js's next-generation bundler, sees significant advancements:

  • Stable for Development (next dev --turbo): Provides blazing-fast local server startups and quicker code refreshes.
  • Alpha for Production Builds (next build --turbopack): Now passes all integration tests, aiming for stable production use in future releases.
  • Performance Improvements: Reduced memory usage and accelerated build times, especially on multi-core CPUs.
  • Tree Shaking: New capabilities for removing unused code.

6. Improved Error Debugging

Debugging has been significantly overhauled for a more intuitive and efficient experience:

  • Redesigned Error UI: Clearer and easier-to-understand error messages in both the terminal and browser overlay.
  • Focused Stack Traces: Filters out noise from third-party dependencies, focusing on your application code.
  • Component-Level Precision: Leverages React's "owner stacks" to pinpoint exact error sources.
  • Consistent Error Formatting: Identical error formatting across standard and Edge environments.

7. Static Route Indicator

A new visual indicator helps developers quickly identify which routes are static during the development process, providing insights into the application's structure.

8. Experimental unstable_after API

This experimental API allows developers to execute server tasks after a response has finished streaming to the user. This is useful for non-critical tasks like logging, analytics, or other system synchronization that shouldn't block the primary response.

9. ESLint 9 Support

Next.js 15 introduces support for ESLint 9 while maintaining backward compatibility with ESLint 8. This update, along with eslint-plugin-react-hooks v5, further improves code quality.

10. TypeScript in next.config.ts

The next.config.js file now supports TypeScript, allowing developers to create next.config.ts files and benefit from TypeScript's type checking for configuration options.

11. Stable Instrumentation and onRequestError Hook

Instrumentation is now stable with the introduction of the register() API, allowing for performance monitoring, error tracking, and deep integration with observability libraries. A new onRequestError A hook is also introduced, particularly in collaboration with Sentry.

12. Other Notable Changes

  • revalidateTag: Can now pass multiple tags at once.
  • images.remotePatterns.search and images.localPatterns: New configuration keys for next/image for better control over image compression restrictions.
  • Cache-Control Header Management: More control over the Cache-Control header, which was previously rigidly overwritten.
  • next/dynamic Caching: Modules are now cached and reused, rather than being reloaded each time.
  • Node.js Middleware (Experimental): Support for Node.js runtime in Middleware.
  • Deployment Adapters (Alpha): Enables creation of custom deployment adapters for finer control over build and deploy targets.
  • Deprecations: Node.js 18 support and AMP are deprecated.

These updates aim to make Next.js even more powerful, performant, and developer-friendly.

Thank you

sonjoybarman

Image