This question already has answers here:
Redirect to Firebase Hosting custom domain
(3 answers)
Closed 3 years ago.
I am hosting a site on Firebase hosting. It has a default URL of myapp.firebaseapp.com. I have configured a custom URL for my app and it is sub.domain.com. The issue i am having is that both are still accessible. Users can access the app from myapp.firebaseapp.com and sub.domain.com. I need users to only be able to access sub.domain.com.
Is there a way to turn off the default domain within the Firebase console or do i need to accomplish this with a rewrite or a redirect?
Any help would be greatly appreciated. I searched around and was not able to find any information regarding this issue. Below is a screenshot showing that both domains are configured correctly.
I think your only option (at least for now) is to use to redirect the users. You could redirect your users from default to the custom url using simple Javascript. That could be done by getting the host (window.host), checking if it is the default or the custom url and redirecting if necessary.
Your default domain could not be turned off. The only option is not make it public at the moment.
Or you can tweak a cloud function that will redirect your functions to new custom domain.
Related
I have an app in Amplify that currently has a custom domain attached. I can access the app fine, all seems to be working good on this, but I just tried accessing the default Amplify subdomain (master.something.amplifyapp.com) and this works also.
I would like to either remove this subdomain or redirect it to the custom domain so that users can only access the app from the custom URL.
Looked through documentation, other questions online and cannot seem to find anything related to this. I only found a delete-domain-association page, but unsure if this is actually the way to do it https://awscli.amazonaws.com/v2/documentation/api/latest/reference/amplify/delete-domain-association.html
Below is how the app looks in domain management:
Is there a best practice on how this should be done? Should it be redirected, should it be removed or something completely different?
Thank you! I appreciate any comment
I have tried looking for similar questions and through documentation.
I have a Firebase project with Hosting enabled. My default url (given by Firebase) is
<PROJECT_NAME>.web.app. How can I also deploy to dashboard.<PROJECT_NAME>.web.app? I want authenticated users to be able to see this special dashboard.<PROJECT_NAME>.web.app url.
Whenever I try adding this as a custom domain, Firebase asks me to add some stuff regarding to web.app, which I can't.
Note: I am using React for my project.
You don't get any control over the web.app subdomain that's automatically created for your project. That is entirely managed by Google. If you want to customize a domain, you will have to register one of your own and manage its DNS for use with Firebase Hosting as described in the documentation.
I am quite new to firebase dynamic links, I was trying to create a firebase dynamic link with a subdomain let's say: apple.page.link, but then it showed an error this subdomain cannot be used by anyone? So what does that mean, are there some certain types of subdomain only that I can use? Do I need to have my own website to create firebase dynamic links?
When adding a subdomain, you need to verify the root domain first.
Please refer to the Firebase Subdomain official documentation:
https://firebase.google.com/support/troubleshooter/hosting/dns/subdomain
👋 I'm hoping to use Firebase to create an application that will allow users to make their content accessible via a custom domain. This is probably best described as a similar setup to how WordPress Multisite Domain Mapping works where there would be a main site, domain.com and many subsites based on their content customdomain.com mydomain.com anotherdomain.com.
The domains (100+) would point to the same codebase + Firestore, but based on the domain - would serve different content. All content swapping would be stored within a cloud function to serve the appropriate site.
I did see this domain limit exceeded FAQ but I wasn't sure if that applies to what I'm attempting to do at a DNS level.
I'm currently doing this in an older version of the app with DigitalOcean and an individual CloudFlare site that points to the same server, but it's a major pain to setup Page Rules, SSLs, etc instead of something that could hopefully be automated.
Thanks for any info!
I'm trying to use firebase with different subdomains, but serving the same content.
I've managed to redirect subdomains, but I need to stay routed to it.
When I type for exemple: subdomain.mydomain.com, I'm being redirected to mydomain.com.
I need it to stay on subdomain.mydomain.com.
The subdomain will be created dynamically.
For reference, see the answer from Chris at How do I make a custom subdomain on Firebase?
As it stands this is not currently possible, although it seems to be an often requested feature that they are working on.