Subdomain with BSS hosting

Hello!

I was wondering if it’s possible to make a subdomain in my BSS project that is hosted with BSS hosting. And if so, how do I do it? I know that I have to set a DNS record, but that’s as far as my knowledge on this subject goes, haha.

Thank you!

If your domain is example.com and you want to add sub.example.com
you can do it like this

Step 1:

Set up the Subdomain in Cloudflare DNS
Log in to your Cloudflare account and select the domain you want to work with.

Go to the DNS tab.

Add a CNAME record for your subdomain pointing to your main domain.

Type Name Target TTL Proxy Status
CNAME example.com sites.bootstrapstudio.io Auto Proxied
CNAME sub.example.com example.com Auto Proxied

Step 2:

Create a Page Rule for URL Forwarding
Go to the “Page Rules” tab in Cloudflare.

Click on “Create Page Rule.”

Enter the URL pattern for the subdomain:

URL Pattern Settings
sub.example.com/* Forwarding URL 301 to https://example.com/sub/$1

The $1 at the end captures and appends any path or parameters from the original request to the new URL.

Save and Deploy the page rule.

Page Rule Priority: Ensure the page rule for forwarding the subdomain is the first in the list if you have multiple page rules.

1 Like

Thanks! But wouldn’t this be pointless if at the end it will still just be redirected to a place in the normal domain?

The example above show you how to if you only want to dedicate one slot to your domain and subdomain.
If you want each subdomain to have their own slot of the 5 you get with bss hosting you can do like this

Type Name Target TTL Proxy Status
CNAME example.com sites.bootstrapstudio.io Auto Proxied
CNAME store.example.com sites.bootstrapstudio.io Auto Proxied
CNAME blog.example.com sites.bootstrapstudio.io Auto Proxied
CNAME portfolio.example.com sites.bootstrapstudio.io Auto Proxied

In this example you have one slot over for a .bss.design domain

1 Like

Great! Now I understand how it works! Thank you!!

1 Like