Create a subdirectory under /app that still gets rendered on the root URL. Is that possible?
Answered
Laysan Albatross posted this in #help-forum
![Avatar](https://cdn.discordapp.com/embed/avatars/5.png)
Laysan AlbatrossOP
├── home
│ └── page.tsx
by default, this page can be accessed with rooturl/home
but it would be great if it's possible to keep the file where it is but render it directly with rooturl
│ └── page.tsx
by default, this page can be accessed with rooturl/home
but it would be great if it's possible to keep the file where it is but render it directly with rooturl
11 Replies
![Avatar](https://cdn.discordapp.com/avatars/484037068239142956/44415017de6fed2ccd5d44b4b2051ac0.webp?size=256)
joulev
Use route groups like app/(group1)/(group2)/page.tsx then it’ll still be in /
![Avatar](https://cdn.discordapp.com/embed/avatars/5.png)
Laysan AlbatrossOP
you mean app/directory1/directory2/page.tsx? Because that would lead to the content being available on baseurl/directory1/directory2/page.tsx, doesn't it?
Or only when the directory contains a page.tsx? Is that the key difference?
![Avatar](https://cdn.discordapp.com/avatars/484037068239142956/44415017de6fed2ccd5d44b4b2051ac0.webp?size=256)
joulev
Route groups. With the ( )
Answer
![Avatar](https://cdn.discordapp.com/avatars/484037068239142956/44415017de6fed2ccd5d44b4b2051ac0.webp?size=256)
joulev
Read the route group docs for more information
![Avatar](https://cdn.discordapp.com/embed/avatars/5.png)
Laysan AlbatrossOP
so name the directory with ()
yesss thank you so much.
![:galactic_brain:](https://cdn.discordapp.com/emojis/767753315512614913.png)
![Avatar](https://cdn.discordapp.com/embed/avatars/5.png)
Laysan AlbatrossOP
So I know should have the possibility to render page.tsx on the rooturl, but use a completely independent layout file for it. At least that's what I hope.
![Image](https://cdn.discordapp.com/attachments/1201480984244277279/1201495997629607996/route_groups.png?ex=65ca0758&is=65b79258&hm=3143d64cd7138ffe3e79e6ef3f160dd3fd3aecb3b5a3dfbf4e9878b3ddf17d1e&)
![Avatar](https://cdn.discordapp.com/embed/avatars/5.png)
Laysan AlbatrossOP
okay no. ^^ no matter where I put it, it's still a child of the RootLayout. (obviously)
fck it, I'll find a way.