Using www along with non-www for main domain in multisite installation

Your nginx configuration is fine, you just need to edit the site name in your Multisite settings in the Sites section, and perhaps run a search-replace across the entire database to replace non-www with www links. I’m not sure, but you might additionally need to create a redirect for your non-www domain, although last time I tried that it magically worked on its own.

That said, the only legit reason to use WWW is when a service won’t host your DNS or you choose not to host your DNS with that service, and the DNS is dynamic due to load balancing and whatnot. In that case the only option is to use a CNAME entry, and CNAME entries can only be applied to subdomains. Google App Engine was like this for a very long time until they started hosting DNS for their customers.

error code: 523