How to host sub domain in sub directory?

Namaste🙏, I want to host my dashboard in example.com/dashboard. I have built dashboard in Svelte and I want to use some other website builder for main page (example.com). So, how can I do it in Cloudflare Pages? I am just beginner to Cloudflare ecosystem😀
17 Replies
Soham
Soham10mo ago
Set the name of the dashboard file to dashboard
Vignesh Aithal
Vignesh Aithal10mo ago
How can I redirect it to subdirectory?
Soham
Soham10mo ago
So you want example.com/dashboard to go to dashboard.example.com?
DeviAI
DeviAI10mo ago
No he want it to redirect to example.com/dashboard.
Soham
Soham10mo ago
Then they can use a redirect rule
Vignesh Aithal
Vignesh Aithal10mo ago
I want to use two different technolgies in example.com and example.com/dashboard When users visit example.com/dashboard I want to show users my Svelte app. And when they visit example.com I want to show a Webflow website I tried Redirect but it's not working. I don't know why
Soham
Soham10mo ago
Wait so the user types in dashboard. Example.com, and you want it to go to example. Com/dashboard?
Vignesh Aithal
Vignesh Aithal10mo ago
I want to do it like Supabase, where they host their dashboard in subdirectory(supabse.com/dashboard).
justboereh
justboereh10mo ago
@iamvignesh it’s probably better to have a dashboard subdomain instead of path so you can use weflow for the home pages and svelte for dashboard pages. afaik i don’t really think it’s possible to combine those two together
Soham
Soham10mo ago
Just call the main page of the dashboard "dashboard" and it'll show up as that
Vignesh Aithal
Vignesh Aithal10mo ago
How? I am not getting it
Soham
Soham10mo ago
What does it show up as when you load the dashboard?
Vignesh Aithal
Vignesh Aithal10mo ago
Yeah, but I thought a sub directory would be better Currently I have hosted in subdomain called dashboard
Soham
Soham10mo ago
Is the page of the dashboard called something like index.html?
Vignesh Aithal
Vignesh Aithal10mo ago
I have built it in Svelte, so its +page.svelte
Soham
Soham10mo ago
What if you try use a transform rule
Vignesh Aithal
Vignesh Aithal10mo ago
Ok, I will try and see