DEV Community

Cover image for An overview of Next Route Groups
Gabriel Penteado
Gabriel Penteado

Posted on • Edited on • Originally published at gabripenteado.Medium

An overview of Next Route Groups

Next Route Groups are a way to organize routes in the app directory without changing the URL paths. By enclosing a folder name in parentheses, you can create a Route Group that helps keep related routes together. This allows for better organization and management of routes within the app.

next-route-groups

In this example, (admin-routes) (auth-routes) (client-routes)
are route groups. they are grouped together for better organization, without altering URL structure.

The URL path to the unauthorized page will be only /unauthorized .

Next Route Groups enables you to organize your content logically, create nested layouts, and maintain a clean URL structure.


Thank you for reading.
If you liked this article shared it!
I appreciate your feedback.

Top comments (0)

nextjs tutorial video

📺 Youtube Tutorial Series

So you built a Next.js app, but you need a clear view of the entire operation flow to be able to identify performance bottlenecks before you launch. But how do you get started? Get the essentials on tracing for Next.js from @nikolovlazar in this video series 👀

Watch the Youtube series

👋 Kindness is contagious

Explore a sea of insights with this enlightening post, highly esteemed within the nurturing DEV Community. Coders of all stripes are invited to participate and contribute to our shared knowledge.

Expressing gratitude with a simple "thank you" can make a big impact. Leave your thanks in the comments!

On DEV, exchanging ideas smooths our way and strengthens our community bonds. Found this useful? A quick note of thanks to the author can mean a lot.

Okay