I have moved a site (www.example.com) to a multisite installation. The path is 'sites/www.example.com'. I am reading that adding the 'www' to the sites folder is a no-no.

www.example.com - Works but..

example.com - Doesn't.

I tried creating a symlink 'example.com -> /home1/username/public_html/sites/www.example.com/

also, tried adding "$sites['example.com'] = 'www.example.com';" to my sites.php, but..nothing.

If I rename the folder to 'example.com' all of the paths in the database will be broken. Any ideas?

  • It's weird. it worked for me either way, both with sites/www.example.com and sites/example.com. What's in your htaccess? And does it work for you the other way around (except for the paths, of course, but does the site works)?
    – Mołot
    Sep 30, 2015 at 22:36
  • What are on the vhost? Which ip/url resolves when you try www.example.com or example.com?
    – gerzenstl
    Sep 30, 2015 at 23:09
  • Sorry guys! It looks like the nameserver wasn't pointing correctly. Thanks gerzenstl for your suggestion to look at what ip/url it resolves to!
    – Three_cs
    Oct 1, 2015 at 21:26

1 Answer 1


Rename the folder to example.com, create a 'sites.php' file in /sites, then add the following:

$sites = array (
  'www.example.com' => 'example.com',

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.