Updated
May 31, 2024
Webflow's default domains concept has some peculiarities.
While it's not technically required, if you skip setting a default domain, you'll likely face a series of issues. Here's a breakdown of what I've seen.
What does default domain do on a single domain site?
Let's suppose you have only one custom domain on your site. It has the "naked domain" domain.com, and also your "www" subdomain www.domain.com.
Let's further suppose you set the "www" subdomain as the default domain, as recommended by Webflow.
When you have a default domain set
- Any requests to
domain.comget redirected towww.domain.com - Webflow works properly, with any DNS
When you have NO default domain set
- Some site owners will experience errors like double
www.wwwprefixes, or infinite redirects. - Your
sitemap.xmlmay containdomain.com, orwww.domain.com, unpredictably.
It's possible to make domain.com the default domain, but only in a special DNS configuration that requires support for CNAME flattening. Most DNS providers don't support this, but some, like Cloudflare, do.
What does default domain do on a multiple-domain site?
Let's suppose you have two domains, domainA.com, and domainB.com on your Webflow site.
When you have a default domain set
If you set www.domainA.com as the default domain-
- Any requests to
domainB.com,www.domainB.com, ordomainA.comget redirected towww.domainA.com - Webflow works properly, with any DNS
- Your
sitemap.xmlwill containwww.domainA.com, consistently.
When you have NO default domain set
- Some site owners will experience errors like double
www.wwwprefixes, or infinite redirects. - Your
sitemap.xmlmay containdomain.com, orwww.domain.com, unpredictably. - Your
sitemap.xmlmay containdomainA.com,www.domainA.com,domainB.com, orwww.domainB.com, unpredictably.
