App Router

acme.com
/
children

Not Found

  • not-found.js file is used to render UI when the notFound() function is thrown within a route segment.
  • In this example, when fetching the data we return notFound() for Categories and Sub Categories that do not exist. This renders the closest appropriate not-found.js.
  • Note: not-found.js currently only renders when triggered by the notFound() function. We're working on support for catching unmatched routes (404).