Next.js Discord

Discord Forum

Dynamic nested routes

Unanswered
Valentinh posted this in #help-forum
Open in Discord
Hello Everyone!

I'm exploring dynamic routing with multiple levels in Next.js 13 and could use a bit of guidance.

Here's what I'm aiming to achieve with the routing: /teams/[teamTypeSlug]/[teamSlug]

I attempted the following directory structure, but it seems like I'm missing something:

teams/
    [slug]/
        page.tsx
        [slug]/
            page.tsx


I get a 404 error page when I go to /teams/[teamTypeSlug]/[teamSlug]

I've scoured the internet for solutions but haven’t found the right fix yet. 😕

Could anyone shed some light on how to set this up correctly? 🙏

Thank you so much in advance!

2 Replies

Giant panda
You haven't explained what the error is.
@Giant panda I get a 404 page