firebasednsfirebase-hostingsquarespace

Firebase website working only without the 'www'


I have a firebase web app, and I connected it to a custom domain bought with Squarespace. The issue is, when I go the the site: example.com, it works, but when I append 'www' to the domain: www.example.com, it doesn't work, it just loads. I'm on Safari.

Here are my DNS records for the domain:

DNS Records

Any ideas how I can fix this?


Solution

  • It seems like you have set up your custom domain to work without the "www"
    So, you need to create a CNAME record for the "www" subdomain:

    Host: www
    Type: CNAME
    Data: your-firebase-app.firebaseapp.com
    Replace "your-firebase-app" with the actual name of your Firebase app.

    Go to the Firebase Console, select your project, and navigate to the Hosting section. In the "Custom Domains" tab, make sure you have both the "example.com" and "www.example.com" domains added. This changes can take some time to propagate across the internet.