flâneur — a map of the web's best reading

Routing: Error Handling | Next.js

nextjs.org · 1,303 words · saved by 2 readers

Handle runtime errors by automatically wrapping route segments and their nested children in a React Error Boundary.

This page is also available as Markdown at /docs/app/getting-started/error-handling.md . For an index of Next.js documentation , see /docs/llms.txt . Copy page Error Handling Last updated March 25, 2026 Errors can be divided into two categories: expected errors and uncaught exceptions . This page will walk you through how you can handle these errors in your Next.js application. Handling expected errors Expected errors are those that can occur during the normal operation of the application, such as those from server-side form validation or failed requests. These errors should be handled explici

Explore this link on the map →

saved by

related reading