How do I define a path based on user account name

Hi- I am using external database (Supabase) and am using slug to fetch the correct data from the external database. The way I envision is to capture the slug from the url path. For example: www.creatorbackstage.co/c/[user_slug]

However, I am currently encountering a bit difficulty of setting up the [user_slug] in the url path. It seems the best I could do is sending a parameter. Is there a way to define the path instead?

Hi! You can definitely set up a path-based slug in Bubble instead of sending it as a parameter. You’ll just need to use “path parameters” by making the page a reusable, slug-driven page type.

Here’s how to do it:

  1. Make the page a “thing” page
    Set the page’s content type to User or whatever data type your slug belongs to.
  2. Use the built-in “slug” field
    Bubble automatically lets you load a thing via its slug.
    So if your page type is User and a User has slug = “john-doe”, then:
    www.creatorbackstage.co/c/john-doe
    will load that User as the page’s thing without needing a parameter.
  3. Routing trick
    Create a page called c and set its content type to User → now /c/[slug] works by default.
  4. If using Supabase
    Since the User data isn’t stored in Bubble, you can still use the URL path slug by doing:
  • On page load → “Get path segment #2
  • Use that value to fetch the correct record from Supabase.
    You don’t need to set a Bubble thing — just read the slug from the path.

Key point: Bubble won’t generate the slug for external DB objects, but it will let you read the path like /c/whatever-slug and use that in your API call.

Thanks! So if I use the external database, do I just use the WF “go to external website” and write the URL manually?

No, you don’t need “Go to external website” at all. That’s only for leaving your app.

Since you’re using Supabase as an external collection via Bubble’s Data → External collections

sorry- do you mind elaborating more on where to find what you are describing?

I’m trying to add a second path (e.g., a slug coming from Supabase to the url), but not sure how to attach it, except for use “go to an external website” and manually write the url there.