The Complete Guide To Creating A WordPress Multisite Installation

WordPress introduced their multisite feature back in 2010 in WordPress 3.0. It replaced the older system.

Once the feature is activated on your website, multiple websites can be created from the same WordPress installation. Essentially, one set of WordPress core files powers many websites. Plugins and themes are also shared, however each website has unique directories for media uploads. The same database is also used for all websites, however separate tables are created for each website.

In this article, I would like to speak about the benefits of WordPress multisite and show you how you can activate this feature.

The Benefits of WordPress Multisite

Multisite is a powerful WordPress feature that can be used by small, medium, and large websites. It lets you create multiple virtual websites from one WordPress installation. This lets you turn your website into a network of websites.

With one main installation, you only have to update WordPress, and your themes and plugins, once. Multisite gives you access to all network websites directly through the WordPress admin bar. Bear in mind, however, that sites can only be located at one domain, or on subdomains of your main domain. You cannot use different domain names for network sites. It all has to be located at one domain.

Users can be shared across many websites. Rather than create users for two, three, or more websites; you can assign a user to as many websites as you like. This is particularly useful for administrators and staff. Multisite also allows you to grant access to users to create their own websites. This is the same feature that is used by WordPress’s own network

In short, multisite has a lot of practical uses.

A company can use multisite to make an employee an administrator of their company blog and give them full control over content and users. However, they could avoid any problems associated with novice users by restricting them from modifying themes and plugins

Multisite is also great for creating unique sub sections of your website. For example, you can host your main website at the root of your domain and your directory at directory.yourdomain.com or yourdomain.com/directory/. You could also use multisite for discussion forums, support desks, online shops, and more. Each area of your website can be styled in a unique way that distinguishes it from the main website.

As you know, it can be time consuming managing multiple WordPress websites effectively. That is why many people use services such as . When it comes to managing websites, multisite offers many of the same benefits a a WordPress management service offers.

You will be pleased to hear that WordPress multisite is quick and easy to install. Without further ado, let us take a closer look at what you need to do to activate multisite on your website.

How to Install WordPress Multisite

Multisite can be installed on your existing WordPress installation. The only limitation is that it does not work with the default permalink structure; since WordPress needs to be able to add the correct name to sub directories and subdomains.

If you have never used multisite before, it may be prudent to activate multisite on a test website first. This will allow you to get an understanding of how multisite can be set up and prevent you from misconfiguring your live website.

When you do go to activate multisite on your live website, make a point of backing up your files and database before you begin. This will allow you to roll back to a previous version of your website if anything goes wrong.

Those of you who are activating multisite on a fresh WordPress installation have nothing to worry about as you can simply delete your data and re-install WordPress 🙂

Thankfully, there is not much that can go wrong during installation as multisite is very easy to set up.

The first thing you need to do is add the following line to your wp-config.php file. It can be placed anywhere above the /* That’s all, stop editing! Happy blogging. */ line.

/* Multisite */
define( 'WP_ALLOW_MULTISITE', true );

Failure to add the code above will stop you from accessing the network setup page.

You will see this error message if you don’t enable multisite in your wp-config.php file.

Once you have enabled multisite through wp-config.php and saved the file, you will see a new option in your tools menu entitled “Network Setup” (located at www.yourdomain.com/wp-admin/network.php).

A setup page for your network will now be displayed in your main menu.

The network setup page will help you install multisite. Before proceeding with the installation, you need to deactivate all of your WordPress plugins. This is a precautionary measure that avoids any conflictions occurring.

You need to deactivate all plugins in order to proceed with the installation.

You can then proceed to the installation page.

At this stage, you may see a warning message that advises you to change your site url to yourdomain.com instead of www.yourdomain.com. This is to avoid any links having the www prefix. Note that you can still install multisite if this message is displayed.

The “Create a Network of WordPress Sites” page.

If you do remove the www prefix from your site url, the warning will disappear.

The server address warning will disappear if you change your site url.

You will notice in the image above that another warning is displayed because my test website is installed in a sub directory (i.e. mydomain.com/wordpress/). This means that any network websites I create will also have to be installed in a sub directory.

The message you will see if your existing website is installed in a sub-directory.

If WordPress is installed in the root of your domain, you may receive a warning that states that your network must use sub-domains. This will be displayed if your WordPress website is older than one month.

WordPress forces you to choose subdomains after one month to avoid any permalink confliction between pages and sites that can occur with sub directory installations. For example, it would stop a page at www.yourdomain.com/news conflicting with a site located at www.yourdomain.com/news.

I understand WordPress’s reasoning for this, though I think it would be better if they simply warned users of this risk, but still gave users the option of choosing a sub directory installation instead of a subdomain. This would allow WordPress users to change the permalink of pages before installing multisite. It is also worth noting that the same kind of problem can arise if someone adds a site with the same name as an existing subdomain.

The message you will see if your existing website is installed in the root of the domain.

I installed multisite on a few existing websites of mine, therefore I was only given the option of using a subdomain or sub directory.

If you activate multisite on a fresh WordPress installation (i.e. less than one month old), you will see an option to choose either subdomains or sub directories.

WordPress allows you to choose a subdomain or sub directory.

After deciding on whether to use a subdomain or sub directory structure (or had it decided for you), you can enter your network details. All you need to do is enter the name of your network and admin email address.

You only need to complete two simple fields in the installation page.

Once you click the install button, WordPress will add the necessary multisite tables to your WordPress database. You will then be taken to the next part of the installation. In this step, you will be required to add a piece of code to your wp-config.php file and your .htaccess file.

If you backed up all of your website files and database previously, you will already have a backup of your wp-config.php and .htaccess file. If you haven’t backed them up by this stage, make a point of doing it now. This will help you revert back to a normal WordPress installation later.

Your website’s wp-config.php and .htaccess files need to be updated.

The code that needs to be added to these files depends on your existing website structure; and whether you are using a subdomain or sub directory structure for your network.

Remember to add the above code to your wp-config.php file before the /* That’s all, stop editing! Happy blogging. */ line. It is best to place the code below the multisite definition line you added to the file previously.

The code that I had to add to my .htaccess website can be seen below. As you can see, the code takes into account that my test website was installed in a sub directory named wordpress. The code you need to add to your .htaccess file will be different.

Please be aware that the above code needs to replace any existing WordPress rules in your .htaccess file. It should not just be added to the file It needs to be added between the # BEGIN WordPress and # END WordPress tags.

* Note: I shared examples of the code you will need to add to your website to help you understand what needs to be added to your files. Do not copy and paste the above code into your own files. You need to use the unique code WordPress gives you. The code above is merely for illustration purposes.

Once you have updated your wp-config.php and .htaccess files, you should reload your website. You will be asked to login again. Once you have done this, you will be taken to your network dashboard.

With one installation, I could not visit a network site I created as the page was caught in a redirect loop. I resolved this issue by simply deleting the code in the .htaccess file and restarting the installation process.

This error was not caused by WordPress multisite. The error occurred because I did not remove code correctly from the .htaccess file after uninstalling and reinstalling multisite. The redirect problem I experienced is a reminder that whenever you experience a problem during the installation process, the best thing to do is retrace your steps and start again 🙂

Configuring Network Subdomains

In the installation guide above, the process of setting up a multisite network that uses subdomains is exactly the same as setting up a multisite network using directories.

However, subdomains requires a little more configuration after you have followed the above steps.

The first thing to do is check with your hosting company to verify that your hosting account supports subdomains. You also need to ensure that WordPress is installed in the root of your domain, as subdomains do not work when WordPress is located in a sub directory.

Next, you need to map each subdomain to your WordPress installation i.e. the same directory as your website’s wp-config.php file.

There are a few ways to do this. one of the following methods:

Configuring wildcard subdomains

Configuring virtual hosts, specifying the same document root for each

Creating addon domains or subdomains in cPanel or in a similar web hosting control panel

Creating a wildcard subdomain through your hosting control panel is one of the easiest ways to handle this issue. Every hosting control panel I have ever used has a dedicated page that allows you to create and manage subdomains.

The screenshot below highlights what the subdomains menu link looks like in cPanel.

In most hosting control panels, there is a dedicated page to managing subdomains.

To create a wildcard, all you need to do is add an asterisk (*) as the subdomain. You also need to specify the document root i.e. the location of your WordPress installation.

By default, cPanel will add the correct path to your home directory; however you may have to specify this manually in other hosting control panels.

Creating a wildcard subdomain will only take you a minute.

If you already use subdomains, you probably do not want to use a wildcard; as it would inadvertently redirect your existing subdomains.

For example, if your forums are located at forums.yourdomain.com and your help desk is located at support.yourdomain.com, you cannot use a wildcard subdomain as it would redirect those domains to your home page. Therefore, you need to create a subdomain manually for each website you add to your network.

This should not be a problem if you are creating all sites in the network yourself (i.e. you do not allow users to create network sites). It is, at best, a minor inconvenience.

You can create subdomains manually for each site.

As long as you point your subdomains to the location of your WordPress installation; WordPress will ensure that everything works correctly.

Changed your mind about which set up you are using? Don’t worry. WordPress allows you to switch from a subdomain configuration to a sub directory configuration; and vice-versa.

All you have to do is change the SUBDOMAIN_INSTALL call in your wp-config.php file.

If you want to use subdomains, change SUBDOMAIN_INSTALL to true:

define( 'SUBDOMAIN_INSTALL', true );

If you would prefer a path based network that used directories, change SUBDOMAIN_INSTALL to false:

define( 'SUBDOMAIN_INSTALL', false );

Your .htaccess permalink code will also have to be updated if you do make a switch. Therefore, be sure to copy the code from the network setup page (found under the settings menu in the network admin area). Then replace the previous code in .htaccess with the new updated code.

Your New Multisite WordPress Network

When you log back in, WordPress will redirect you to your network dashboard at http://www.yourdomain.com/wp-admin/network/. Your original website dashboard will still be visible at http://www.yourdomain.com/wp-admin/.

Let’s look at your new network admin area.

The first thing you will notice is how different the dashboard looks. It now displays a dashboard widget that lets you search for users and websites. There are also links to create a new user and create a new site.

You can manage all users and websites via the admin area.

The admin bar displays a network admin dropdown menu that links to the main areas of the network administration area. This includes sites, users, themes, and plugins.

A menu is also displayed for your main website underneath. Links include the site dashboard, new post, manage comments, and visit site.

These network menus are displayed on every site on the network. This allows you to change from one website to another with ease.

You can access all network websites through the WordPress admin bar.

The sites page lists all of the sites in your network. For each website, it details the path name, the date of the last update, the creation date, and the users who are assigned to that website.

The sites page is a practical way of viewing all sites in the network.

The users page shows you when a user account was created and with what sites they are associated. WordPress also creates a new user group called “Super Admin”.

While administrators have full permissions to modify the website they are assigned; super administrators have admin privileges for all websites in the network. Your own account will automatically be upgraded to the super admin role once you install multisite.

The users page highlights what websites a user is associated.

The network theme page looks different to the main themes page of a regular WordPress page. In many respects, the themes page works in the same way as plugins do. Each theme can be enabled or disabled for the network. Any themes that had been installed on your website before multisite was activated will be listed on this page.

The network theme page lists all of your installed WordPress themes.

By default, site administrators cannot install themes or plugins. They can only activate a theme or plugin from a list of the themes and plugins you enabled for the network.

Only network enabled themes are displayed to website admin.

The plugin has full support for multisite. It can be used to grant additional permissions to site administrators. Using User Role Editor, I was able to give myself permission to manage the network, manage network options, manage network plugins, and manage network themes.

User Role Editor allows you to enhance the permissions of administrators.

By default, User Role editor allows site administrators to modify their own permissions (as shown in the above screenshot). You obviously need to trust a site administrator completely before offering them this level of control.

If you want to activate User Role Editor on your network, but do not want to allow site administrators to modify their own permissions; then you need to visit the User Role Editor settings page and deselect the option entitled “Show Administrator role at User Role Editor”.

This allows site administrators to modify user permissions of all user group permissions below them; however it ensures they cannot grant themselves the ability to modify your network settings, themes, and plugins.

Ensure you configure user role editor correctly in the network admin area.

The network plugin system works in the same way as themes. You need to activate a plugin for the network in order for it to be made available to all site administrators. This is useful if you want to avoid people activating plugins that use up a lot of resources.

Plugins need to be activated for the network in order for site admin to use them.

The settings menu displays a link to a network setup page. This page provides a handy reference of the code that you previously added to your website’s wp-config.php and .htaccess files (note that the network setup page will no longer be displayed in the tools menu of your main WordPress installation).

I will show you the network settings page in more detail in the next section 🙂

The network settings menu.

At the bottom of the network admin menu is an updates menu. The available updates page is exactly the same as the one on a regular WordPress website. It allows you to update WordPress, themes, and plugins.

The available updates page is identical to the one you will find on a regular WordPress installation.

There is also an option to . This will go through each site on your network and update their core files. It processes five websites at a time.

It is a useful feature that allows you to quickly update all websites in your network at the click of a button.

The Upgrade Network option makes upgrading WordPress a breeze.

Configuring Your Multisite Installation

The network settings page controls how your network is set up. At the top of the page is the operational settings area. This allows you to modify the network title and admin email that you defined when you first set up multisite.

You can change your network title and admin email at any time.

The registration settings area lets you control what users can do. When you initially set multisite up, registration will be disabled. You can change this so that anyone can register or so existing users can add new websites. Alternatively, you can allow users to register and create a new website. This is the way a blog network such as WordPress.com is configured.

Registrations can be limited to certain domains. This is a useful feature for companies. For example, Carpetcleaninghaddontownship could limit registrations to those who sign up with an @elegantthemes.com email address.

Open networks can also ban domains. This may be necessary if you are receiving a lot of spam registrations from one specific domain.

If you desire, new users can register and add new sites to your network.

The new site settings area lets you modify the email template that is sent to users when they create an account. The email that is sent to them after they have created their site can also be amended.

You can also change the content that is used for the first post, page, comment, comment author, and comment url.

New site settings allows you to modify the content that is added to a new site.

In the last section, WordPress lets you control the total storage space that is available for sites. The maximum file upload size and the type of files that can be uploaded, can also be adjusted.

Limiting the amount of storage for new sites is important if you want to keep storage and bandwidth under control.

These are the only settings multisite offers. It is quite surprising when you think about it. Particularly when you consider that multisite is powerful enough to host a network of hundreds, or even thousands, of websites.

Perhaps it is this simplicity that makes WordPress multisite so powerful. What do you think?

Adding a New Site to Your Network

All you have to do to add a new site to the network is complete three fields. You need to confirm the site address, the site title, and the admin email.

With a sub directory configuration, the name you enter will define the path of the sub directory e.g. www.yourdomain.com/news/. With a subdomain configuration, it will define the subdomain i.e. news.yourdomain.com

If a user in your network has the same email address as the admin email you define, they will be added as an administrator of that site. If not, WordPress will create a new user account and then email the administrator their login details.

Adding a new site to the network only takes a few seconds.

Once you have added your site, it will be listed in your sites page. There are quick links on this page that allow you to visit the site dashboard and visit the front end of the website.

You can also deactivate the site, mark it as spam, or archive it. Deactivating a site will remove it from public view, while archiving will allow the public to continue to view the website, but stop the site administrator from updating it i.e. it becomes read only.

Note that moderation links such as spam, deactivate, delete, etc; are not available for the main WordPress installation. Of course, if your main website was deleted, the whole network would crumble 🙂

The sites list page is essential for managing your network sites.

Clicking on the edit link will allow you to modify site details. The info tab displays the site domain, path, registration date, and the date of the last update.

Moderation checkboxes can be found at the bottom that allow you to deactivate, delete, spam, and archive the website. There is also an option entitled mature which allows you to designate the website as adult content. This will stop the site from being listed publicly on your network.

Important site settings can be changed from the info tab.

The users tab lets you see all the users that are assigned to a site. You can edit and delete users from this page. There is also an option to quickly change the user group of a user.

Existing users from your network can be assigned to the site on this page. New users can also be added.

The users tab allows you to manage all users for a particular site.

The themes tab shows how all the sites that are enabled and disabled for a site. You may recall the main themes tab that I spoke about earlier which allows you to enable and disable themes for the whole network. This tab allows you to overwrite those network settings and enable or disable a theme for a specific site.

Themes can be enabled and disabled for a site via the themes tab.

The site settings page lists all settings for a site. It works in the same way as the hidden WordPress options page (i.e. the one at www.yourdomain.com/wp-admin/options.php).

All settings can be modified through the settings tab.

How to Uninstall Multisite

You may find that multisite does not fit your requirements. Fear not, as multisite is very easy to deactivate. All you have to do is work backwards and remove the changes you made earlier.

There are three steps you need to do follow to remove multisite:

Remove the multisite code from your wp-config.php file

Remove the multisite code from your .htaccess file

Remove multisite data from your website database

Remove media files that have been uploaded to network sites

Once you have completed all four steps, your website will be a regular WordPress website once again.

Please note that only the first two steps need to be performed in order for your website to return to a normal WordPress website.

If you are considering adding multisite again in the future, but want to change back to a regular WordPress website in the meantime, you may want to keep all network data in your database.

In a future re-installation of multisite, WordPress will give you a warning if network data already exists, and advise you to remove network tables before proceeding with the installation. This warning can be disregarded as you would not be clicking on the install button and adding new tables to your database. You would simply be re-enabling multisite and changing your permalink structure once again.

WordPress warns you if you have already installed multisite.

I recommend removing all multisite data from your website if you have no intention of activating multisite on your website again.

Let us look closer at what you need to do to remove multisite.

Step 1: Remove the Multisite Code From Your wp-config.php File

The first thing you should do is remove the code you added to your wp-config.php during the installation process. There are two ways to do this.

One way is to simply upload your backed up wp-config.php file to overwrite the one in your server. The other is to delete the code from the file directly.

The code you added to your wp-config.php file earlier should look something like the code below. Simply remove this code and then save the file.

You may recall that we did not add the above code to the .htaccess file. This code actually replaced the previous code that was in between the # BEGIN WordPress and # END WordPress tags.

To remove the multisite code, all you have to do is delete all of the code between these tags. Then visit your website permalink settings page (www.yourdomain.com/wp-admin/options-permalink.php) and save your permalink settings. This will add the correct permalink code back to your .htaccess file.

Step 3: Remove Multisite Data From Your Website Database

In total, multisite adds six tables to your website database when you activate multisite.

The tables are:

wp_blogs

wp_blog_versions

wp_registration_log

wp_signups

wp_site

wp_sitemeta

If your database prefix for WordPress tables has been configured differently in wp-config.php, the names above will be slightly different. For example, if your prefix is abc, the first table in the above list would be abc_blogs.

Please note that if are enabled on your network, you will also have to delete the table wp_sitecategories (check your database for the wp_sitecategories table if you are unsure as to whether it is enabled). For the rest of this section, I will assume that you do not have this additional table added to your database, though be sure to remove this table if it is present 🙂

In addition to the above six tables, multisite also adds two fields to the wp_users table; spam and deleted. These should also be deleted if you want to completely remove multisite from your website.

Last but not least, you need to remove the tables that WordPress adds for each of network site. In total, nine tables are added for each website you add to your network.

Data can be removed from your database using a database management tool such as phpMyAdmin. This can easily be located through your hosting control panel.

You will find phpMyAdmin listed on the main dashboard of cPanel.

Once you are logged into your database management tool, click on the correct database table for your website.

The tables can be deleted via the structure interface, or via an SQL query. If you want to delete the tables via the structure interface, click on the six tables that you need to delete.

As a reminder, these tables are : wp_blogs, wp_blog_versions, wp_registration_log, wp_signups, wp_site, and wp_sitemeta.

Select all multisite tables from the database.

Next, scroll down to the dropdown option at the bottom of the page and select DROP.

Drop the tables to remove all data.

You will then be asked to confirm the deletion of the tables. Take this opportunity to double check that you selected the correct tables for deletion.

Confirm that the six tables should be dropped.

Tables can also be removed by executing the SQL query below. Be sure to adjust the code below to match the table prefix you use on your database.

You can do this in phpMyAdmin via the SQL tab at the top of the page. Other database management tools have a similar option for executing SQL commands.

Tables can be deleting using an SQL Query.

Next, confirm that you want to drop the tables.

You need to confirm that you want the tables deleted.

You will be advised if your query was successfully executed. Don’t worry, you will not run into any problems if you followed the steps above correctly 🙂

You will see a message like this if the query executed successfully.

The last thing you need to do is delete the spam and deleted fields from your wp_users database.

Multisite adds two additional fields to your wp_users database.

You can do this by executing the SQL query below. Again, make sure you change the prefix of the users table if your website database uses a different prefix.

ALTER TABLE `wp_users` DROP `spam`, DROP `deleted`;

If you installed WordPress multisite, but did not add any additional sites, then you have nothing left to do. Your website will now be clear of all multisite data.

If, however, you did add one or more sites to your network, you still have a little work to do.

Whenever you add a site to your network (not counting the original installation), WordPress adds nine new tables to your database.

The tables are:

wp_2_commentmeta

wp_2_comments

wp_2_links

wp_2_options

wp_2_postmeta

wp_2_posts

wp_2_terms

wp_2_term_relationships

wp_2_term_taxonomy

Each additional site in your network will add nine more tables using your database prefix and blog id. For example, the third website would start with wp_3_, the fourth would use wp_4_, etc.

You therefore need to remove all instances of the nine tables noted above. That means you have nine tables to delete if you added one website to your network, eighteen tables if you added two websites, twenty seven tables if you added three websites, and so on.

If you delete a site through the sites page, WordPress will delete all tables associated with a site. This is the simplest and most practical way of deleting site data.

However, if you have uninstalled multisite, you will be unable to remove site data this way. You will therefore have to delete the data manually through your database management tool (e.g. phpMyAdmin).

The process is the same as last time. You simply select the table rows that need to be deleted and then scroll down to the bottom of the page and select DROP from the dropdown menu.

Drop the tables for all the sites on your network.

If you prefer, you can delete the tables by running an SQL Query. Be sure to modify the query for your website database prefix and the correct blog id of the tables you are removing:

Once you have deleted all network site tables, your website database will be clear of all multisite data.

Step 4: Remove Media Files That Have Been Uploaded to Network Sites

I was initially baffled as to where WordPress stores media files that are uploaded to a network site. Mainly because I was unable to find any documentation about this issue online.

After uploading some files to a test site I created on my network, I soon figured out how multisite handles images, videos, and other uploaded files.

The first thing I noticed is that any files that are uploaded to your main website, will continue to be stored in the /wp-content/uploads/ directory using a date structure system. For example, www.yourdomain.com/wp-content/uploads/2014/05/elegantthemes.jpg.

This is good news as it means that media uploads to your main website will always be stored in the same way; whether multisite is activated or not.

Uploads to network sites are handled differently.

Media files can be found in the sites sub directory.

When the first media file is uploaded to one of your network site, WordPress will create a directory within the uploads directory entitled “sites”. A sub directory is also created using the blog id. Two more sub directories are created for the year and month. Files are therefore stored using the same path structure as your main website, with /sites/{blog_id}/ before date and month.

For example, in a site entitled news, which is the first site in a network, the elegantthemes.jpg image would be saved to www.yourdomain.com/wp-content/uploads/sites/2/2014/05/elegantthemes.jpg.

Please note that this is not the image location that WordPress shows in the media library. Since network sites are created virtually, WordPress states that the image is located at www.yourdomain.com/news/wp-content/uploads/sites/2/2014/05/elegantthemes.jpg.

After uploading the elegantthemes.jpg file, I deleted the site I had uploaded to. Deleting a site completely removes all information about images from your website database. That is, the files will be completely removed from your WordPress media library.

Unfortunately, while deleting a site will delete the corresponding meta information for media files from your database, WordPress does not delete the actual files from your uploads directory. Therefore, you need to manually delete any uploaded media files.

It is easy to locate media files that were uploaded to network sites.

If you are uninstalling multisite, simply go to www.yourdomain.com/wp-content/uploads/ and delete the sites directory. This will delete all the images that were uploaded to your network sites.

If you only want to delete media files for a specific site you have deleted, but want to keep multisite activated, then you need to delete the directory that relates to that site. Remember, images are stored in a sub directory using the blog id.

Therefore, you would delete www.yourdomain.com/wp-content/uploads/sites/2/ to delete all media files uploaded to site 2 and you would delete www.yourdomain.com/wp-content/uploads/sites/15/ to delete all media files uploaded to site 15.

Once you understand how images are stored in a multisite installation, deleting images and other media files from your server is a piece of cake 🙂

WordPress Multisite in Action

I thought it would be good to show you a few examples of multisite in action to illustrate what it can do.

As you know, multisite is the basis of the hosted blogging service; however it is also used by many large corporations and high traffic websites.

The New York Times uses multisite to power . All blogs are hosted on subdomains.

New York Times powers a large network of blogs with multisite.

The whole website is also powered by multisite. It uses sub directories and a huge amount of custom themes to manage the many areas of the website.

Once you delve into the different shows and blogs, you realise how big the BBC America website is.

The large USA based electronic retailer uses WordPress multisite to power the blogs for over one thousand of their stores. This is a sub directory installation that uses the same design for all store blogs.

Best Buy illustrates how useful WordPress multisite can be for companies.

Kevin Smith’s uses multisite to display custom designs for many different shows and events. It uses a sub directory structure.

SModcast Internet Radio shows that multisite is not just for blogs.

Graphics powerhouse Adobe power with WordPress multisite. It has a sub directory structure with custom themes for many areas of the website.

Adobe uses multisite for its huge network for blogs.

Overview

I hope you have found this guide on activating WordPress multisite useful.

In preparation for this guide, I installed and uninstalled multisite on three of my websites (two live websites and one test website). I repeated this process on my test website over a dozen times. This allowed me to understand how multisite works and helped me write a better guide.

When I write tutorials such as this, I make a point of testing every major feature I can. This ensures that I do not just take the word of others that something works, or that something does not work.

I do not profess to be an expert on WordPress multisite. Therefore, if you believe that any part of my tutorial is inaccurate or misleading, please let me know in the comment area below. I will do my best to explain myself more clearly, and if needs be, correct any mistakes I made.

Multisite is a feature that makes the WordPress platform even more powerful. It is straight forward to set up and I really loved how intuitive it is to navigate between network websites.

Normally, I talk about the strengths and weaknesses of a product or service in my articles. Although I did install multisite on a live website, I did not go any further than testing that everything was set up correctly.

Therefore, I was not in a position to see what works with multisite, and what did not. I would really have to use multisite for a few weeks on a live website to get a clearer view of the limitations of multisite. Since all data is stored in one database, I suspect that many technical solutions and workarounds exist for large networks to ensure that they run efficiently. However, the fact that multisite powers blog networks with thousands of blogs highlights that it can be done.

Be sure to subscribe to the Carpetcleaninghaddontownship blog as in my next article, I will be sharing with you all some great multisite plugins.

For more information about creating a multisite network of websites, please refer to the resources below 🙂

– Requirements and restrictions of using multisite.

– WordPress’s guide to installing multisite on your website (it’s short and sweet!).

– A good guide on how to set up wildcards for a subdomain multisite configuration.

– Useful tips on administrating a multisite network.

– Details of what tables and fields multisite adds to your website database.

Article thumbnail image by Mert Toker / shutterstock.com

By Kevin Muldoon

Kevin is our resident tutorial master. He has years of experience with WordPress, and is a professional blogger with a special interest in social media, internet marketing and web design.

It depends. I always think it’s best to build a site on a sub domain first anyway, but multisite is great when you’re planning on turning out a lot of sites with similar specs – ie: use the same themes or plugins. It’s important to determine your needs.

One issue I take with something I saw in this article (which may have been addressed later, I didn’t read the whole thing) but it said that you cannot use unique domains as the address, only the sub domain. Well, while technically true, you can actually map unique domain names to the sub domain within the multisite installation. Takes very little skill. Research network domain mapping.

Another great post! I installed my first multisite for a client last month. She wants to translate her site into several languages. I assume multisite is the way to go. I will put the French site in subdirectory /fr , German in /gr , etc.

I’ve never done site translation implementation before. That would be a good topic for blog if enough interest. We haven’t finished the English site yet, but when we do, I will be doing a lot of Google searching to learn more on using .PO and .MO language files, and other requirements.

Thanks again for this post!

Ash
May 28, 2014

Did you take a look at generally the widest WP use for multi-lingual sites.

I just installed the free plugin – Google Translation. Easy to use and seems to do a good job translating the pages – my client will have to tell me how good the translation is, she speaks 6 languages – I speak 1. This plugin may do the job for my needs. It is a basic 6-8 page site (no blog).

I see the downside to having multiple sites in different languages is if you make a change, you have to update all the sites.

With Google Translation I was able to choose which flags to display and not show the Google branding. I put it in my header so it shows on all pages. Select a language and it translates the whole site.

But I will still be interested in your upcoming post.

Ash – I looked into the WPML plugin and was going to go back to it… if my client isn’t happy with Google Translation.

Thanks!
Bob

Mike Childs
May 28, 2014

You can use the “WordPress MU Domain Mapping” plugin to map registered domain names to your multisite network. For example if you don’t like the subdirectory name bigblog1.mymutisite.com, you can register the domain name bigblog1.com and map it to your network. Then all your users have to do is type in .

You may have raised the bar with this one, Kevin. I like the best buy example because I have been talking with a client about doing something similar but on a much smaller scale. I will have to come back and read this a second, and possibly third time to absorb it all though. This tutorial truly is a wealth of information.

While technically true, the real world situation is that by using the WordPress MU Domain Mapping plugin you can map the subdomain or subdirectory URL to the desired URL. That, in effect, is what’s happening on WordPress.com when someone pays to have their own URL instead of myblog.wordpress.com.

Wow, this is a great resourse, i only have one request, and is about plugins for multisite, don’t have a y especific in mind, but something like plugins you must have on a multisite installation. Thanks 🙂

My next article focuses on multisite plugins that you will find useful 🙂

Danny
May 28, 2014

Hello:

I am developing a site for my church and we just signed up for a new VPS server. I am currently developing website using our dedicated IP, since the domain name is still attached to the shared hosting site. Is there a way to easily change the IP address to the domain name once we are ready to go live?

I can change the IP to a domain name quite easily on a regular WordPress install but I don’t see that ability to do that with Multi Site.

I haven’t did this before with a multisite, but surely most settings will change automatically once a site domain has changed. All you would have to do is reset the permalinks. Though I’m not sure I understand the problem fully.

This is an extremely well written and complete guide on multi-site. Thank you!!! I wish this had been available when I tried and failed to create / move a multi-site.

Kevin, can you do a blog sometime on how to MOVE a multi-site? That’s where I got confused and had to revert to my backup of a regular site. Had no luck whatsoever moving it with Duplicator, but then I’m very new to WP and still have everything to learn about sql databases.

It’s not something I have done yet. I imagine that the process is similar to moving a normal WordPress website, though you may have to reset permalinks again (in theory, you wouldn’t have to).

Nukeface
June 16, 2014

Been doing that a bit lately for a current project. Moving a multisite install is no issue. Say you have:

site1.dev.example.com
site2.dev.example.com

and now you want to go live, from you dev.example.com, which was actually a virtual localhost defined in the hosts file of Windows (just a random stab at your issue).

To move the site to a live environment, such as

site1.example.com
site2.example.com

do it in 2 major steps. First, copy/paste all of the files to your live environment, which is the easiest step.

The second step requires a few steps:
1 – back up your database into a single something.sql file
2 – open the sql file in your favorite editor (notepad++/phpstorm/etc), something with a search & replace function
3 – search for (in the quotes) “.dev.” (include the dots!)
4 – replace all with “.”
5- save file

Now go to your PHPMyAdmin on your live environment and import the .sql file.

That should be it.

Of course you should’ve walked through Kevin’s article above to make sure your live environment supports subdomains and such.

before you write this article, I had to install multisite on 25 May 2014, how do I submit my web results? Among wordpress multisite + elegant design themes? I want my website at elegant themes review on the blog elegant themes to be an encouragement for all friends ..

This is a fantastic article on multisite setup. I have always contemplated installing multisite wordpress but had second thoughts due to potential of coming across problematic plugin functionality if switched to multisite. It would be great if something can be said about the usage of which plugins are great for multisite.

hi..thanks for the article..i followed ur instruction i can able to create site but if i create the new site the visit link which shows the error “The requested URL /wordpress-test/test/ was not found on this server.”.plz help me

Great article Kevin!
I have a suggestion for a future blog post. Could you explain how to create a new WordPress website that can then replace an existing website? For example, a company already has a website and is looking to change it’s website to something new. As a web designer how would I go about doing that so I can create the website using WordPress and then swap it out with the existing website data? I hope that makes sense.
The Carpetcleaninghaddontownship blog keeps getting better and better 🙂

WordPress lets you make changes to inactive themes through the theme editor, however it is not really practical beyond basic edits.

For a complete relaunch of a website, I would do all development on a test website. Once everything is ready, simply transfer the theme over and any new pages, posts, images etc, that need to be displayed with the new theme. 🙂

I SOOOOO need to do this & I have only 4 sites. It would be so much easier to update a plugin … like I just did … doing it once and having it fixed on all the sites instead of having to log into each one.

I’ve set up a new multi site install, and the front and back end of the main site works perfectly, but when I create a new sub domain site, both that site’s dashboard and front end take me to 404 page.

I’ve installed several multi sites before, and have never had this issue. Any ideas?

Neither set up is better than the other. They are different things. A sub directory is part of your main website, and search engines treat it as such. A sub domain is treated as a separate entity from your main website; therefore could have different page rank, search engine rankings etc.

For SEO, subdirectories offer more SEO to the main domain name, whilst sub domains are seen by Google as their own site, thus being more independent with their SEO functions, so it depends what you want.

This is the best explanation I’ve seen on this. Any idea where I can get a good rundown of which hosting platforms work best with MS? I know my current Dreamhost plan either doesn’t work or is too difficult for me to set up.

This is a great piece, Kevi, and the amount of time and effort you put into surely comes through. I still have a lingering concern, however, mainly because I’ve read perhaps too much on this topic.

It seems there are some strong recommendations against using multisite for a variety of reasons–including that it could create a number of possible security holes.

If you or anyone else can comment on the difference between sharing multiple installations and users within a single database vs. creating true multisite, that would be incredibly helpful.

I have been debating this for a while and it seems like multisite would fit my situation well. At the moment I have roughly 6 different installs (on subdomains), each of which serves a specific purpose, such as community, shop, crowdfunding, events, content, etc.

One theme simply can’t deliver all the features I need, so I’ve been forced to do a lot of work adapting theme headers/footers in an effort to create a relatively common look.

In the future I MAY want to open the doors to bloggers, but I’m moving slowly. I have 30,000 members and can’t imagine the admin requirements if even 1/1000th of them wanted to create blogs.

In any case–can you or anyone comment on the arguments of one approach vs. another?

I wasn’t aware of any security flaws of multisite. What do you mean by the difference between a single database and true multisite? Do you mean creating websites individually against using multisite?

Kevin

Arthur
June 21, 2014

I suspect Sean is thinking of how Drupal does multisite. Each site has its own directory structure and separate database. The CMS software, any additional modules/plugins and themes/templates sit in separate directories and are accessible to all the sites you want to instantiate. This may be the only area (at least the only one I can think of) where Drupal is cleaner, simpler and more obvious than WP.
I can’t comment on security flaws, but from a security risk standpoint a single database is worrisome. If unauthorized access is gained, it’s access to all sites, not just one. Then there is some additional risk simply related to the much larger size of the single db. In fairness, I seem to recall a comment about the possibility that some of the large deployments you mention may use custom databasing techniques.

I always look forward to reading your articles as they are always very well-written and illuminating – thanks!

With that in mind, you’ll understand that I’m hesitant to suggest that you’re not quite right about themes and plugins being the same…

As I understand it, themes do have to be enabled as you say.

Whereas with plugins you’re activating (rather than enabling) them. Usually Network Activated plugins won’t show up in the available plugins list on sites at all (as they’re activated already by the superadmin).

If you don’t Network Activate it, it does appear in each site’s available plugins list.

…which is why the plugin “Multisite Plugin Manager” which you’ve mentioned in your subsequent post is so useful.

Hope I got this right – I know that it was thoroughly baffling the first few times I tried to get my head around it when I came across it!

Ahhh yeah I may have explained that poorly (or misunderstood it when I wrote it). Enabling a plugin will simply allow network users to select it. Is that correct? haha I’m starting to confuse myself now! 🙂

So, I’ve not had a chance to fire up a multisite install (not easily done on the iPad!), so this is from memory from testing it before my previous comment…

I have a feeling that installing the plugin as super admin at the network level will “enable” the plugin to be activated by all site admins.

That’s not what you’d expect and is kind of unexpected behaviour, but I think I saw a thread about that fact on make.wordpress.org in the last week or so hoping to try and make it a little less confusing.

I’m looking at this very thing myself at the moment. Having done an audit of a large multi-site (a local government intranet site), it appears the following is the case:

Activating a plugin at network level activates it for the whole network ie all sites. None of the subsites can see it or amend settings etc for it.

Plugins not activated at network level can be activated by one or more sites.

On the site(s) I’m auditing, I cannot see any plugin that is not activated at the network level that is not available to every site. This could be for one of the following reasons:

All plugins have been installed by Super Admin or any plugin added by a site admin makes it available to all sites. I would suggest the later is the case as there is only 1 plugins folder and therefore only one install of a plugin can exist.

Thanks Kelvin for this great tutorial. My question is about Blog subscriptions. Is there a way i can have a blog subscription that works all round the multisites? that is one blog subscription that notifies my subscribers of updates on all my multisites?

Helms
June 19, 2014

Hi Kevin,

Is there any way to limit the number to monthly visitors per site in Multisite, either via plugin, nginx, etc.?

Thank you for this excellent article, I followed it to the letter and had no problem setting up a Multi-Site.

QUESTION: I have a domain that has WP installed, and it already has a couple sub.domains attached with WP and a few Directories or sub directories installed with WP. I like to set this up as Multi Site and use the directory option. If I do will the wp directories become part of the Multi Site (don’t care about the subdomains) if I set it up that way. I am hoping so, or do I need to delete the sub domains and (backup) the sub directories first? Please Help.

To Clarify: If I set up Multi Site on the main domain, will the subdirectories I already have.. automatically become part of Multi-Site so I can manage those in the main back office as well?

vitisaureus
July 14, 2014

Detailed, however, one thing I missed. Is it possible to use multisite with different languages on each site?
I would not use a main language site, but equally organised subdomain sites in different languages, and different look. Having only a language-selector welcome page at mydomain.com, where flags point to subdomains.
Is that possible with multisite?

I am running a wordpress mulitiste, and everything went well until i had to change the domain (from sever address to my ‘real’ domain).
I used your article as a reference and i think i did everything that is necessary, but now when i enter my URL my browser can’t connect to the site because it ‘redirects into an infinitie loop’?

I checked every single file and went through all sql tables, i have no idea what i did wrong? Maybe if you have an idea or suggestions, that would be awesome and huuugely appreciated!!!

Thanks for the post. Also you can install WordPress Multisite on a new installation via softaculous with 1 click.

diedmin
August 8, 2014

I recieve this message frmo my wordpress instalation

Note: Please make sure the Apache mod_rewrite module is installed as it will be used at the end of this installation.
If mod_rewrite is disabled, ask your administrator to enable that module, or look at the Apache documentation or elsewhere for help setting it up.

Thank you for such a great article, however, my need is slightly different and I was wondering if any of you would have some thoughts on this:

I have one site (site1) with content created every week and I need to setup a second site (site2) which should partially feed from site1 -partially as in “only posts from certain categories”. Is this possible?

The reason being that site1 is a magazine and site2 will be a sort of ‘digest’, so to speak. Needless to say the wp theme on site2 shall be different from that used on site1.

Any thoughts?. Thanks a lot

Ravi
August 14, 2014

A perfect solution in a sequence and all worked like a charm !
Only need a proper wordpress knowledge, in order to achieve this.

I’m dearly hoping you can help: I’ve gone through the process of installing the multisite clear through to the new .htaccess code AND the new config.php code, BUT, when I log back in, I don’t see “My Sites” (only the single site name) and when I go to Tools > Network Setup I get the message: “Warning: An existing WordPress network was detected.”

Okay. But what I want IS the multisite. So now what do I do? Curious I’m not given an option that says “re-enable multisite” or something similar.

Can you point me in the right direction to complete the multisite installation?

Many thanks for your time and assistance.

Cheers,

Tim

Alok Bhardwaj
September 16, 2014

Kevin,

This is simply a great article. With the help of this, I was able to transform my default installation to a multisite. USP of your article is indepth details and easy language.

Like Johnathan I faced the same problem, for both dashboard and website error 404 appears. What do you mean about modifying permalinks in .htaccess file? would you please explain it more?

Also, since my website is more than several years old, I didn’t have choice to select between sub-domain or sub-directory. I prefer to have sub-directories but new sites are only created as sub-domains. How can I change this?

Hi John,
The issue that you mentioned is precisely what’s happened to me and I can’t seem to figure out the solution. When you type my URL without the www. it sends you to the network site. When you type my URL with the www. it’s just fine. I tried to follow the article to see if I can get the solution, but I can’t quite get to how to fix it. Any suggestions are greatly appreciated!!

Jim
October 11, 2014

Can this be done? multi-site wp for a main domain and a addon domain? and if so what complications exist if my main domain is https: (ssl) and my addon domain is http:

Brad
October 12, 2014

I just wanted to say thanks for a great explanation. I’d always considered multisite too complex to try but after coming across your article I put a test site and 3 subdomains up in no time with the only glitch being the way the cpanel install handled its subdomains (they’re virtual and just use directories) but after referring to your article again I fixed it in no time.

Thank you very much for full informative article. Please help me I have one problem with my wordpress. I do all steps that you have explained but Multisite is not enabled. [the multite icon is not displaying on the left top] What can I do now. Please reply.

Fabian
October 27, 2014

Hi and thank you so much for this awesome instruction. Im going to set up a multisite for a company, which has several locations and i want to set up a different site for each location. Can you tell how i can set up a landing page, where only the logo, the companies slogan and a dropdown menu is shown, where the visitor can choose, which one of the companys sites he /she wants to visit? For example: Company has 4 locations (tokyo, New York, London, Berlin) und the visitor can choose which location of the company he wants to visit?

JP
November 13, 2014

Thank you very much for such a detail guide!!! I could get my site running using multisites.

Fantastic article. I wish I’d seen this before my days and days of frustration. I never did get it set up and finally asked my host (wpmu-hosting.org) a desperate question about it. Lo and behold, it turns out that’s part of the service.

I could have saved weeks and all the hair I pulled out. Do yourself a favor and ask if your host will do it for you. If not, then this article is absolutely one of the best I’ve seen on the matter.

Ernes
November 23, 2014

Is this recommendation valid for the WordPress 4.0.1 version?

Since on the wp-config.php row 61 says:

*You can have multiple installations in one database if you give each a unique
* prefix…

First, thanks for all the práctical info. Second, I have a problem using the Network Shared Media plugin: it simply does not shows when I want to use the images from my main spañish site to be the same in my english translation site. The plugin is network active but I dont know why is not show when I want to put images already uploaded in my new site. Thanks alot!

It’s a great posting bro. A few days ago, I had succeeded in creating wordpress multisite. But now, I would like to add sites in the subdomain. for example, subdomain.example.com/site1, how to configure it?

Great article. REALLY helpful. I had begin to build a new site using multisite and have decided it wasn’t the best choice for me. What will happen when to all the plugins installed through multisite once I convert back to a normal wordpress instance? Thanks for your help

Cassy
February 1, 2015

Hi Kevin,
This is simply amazing !

I have a simple question :
I’m thinking of moving my current website into a network.
But I will need to redirect the main url mydomain.com to mynewdomain.com, and keep the subdomains independently visible like mydomain.com/2014 mydomain.com/2015 mydomain.com/2016 …

What a very enlightening article. I started out not knowing a thing about “Multisite”, (or my other research ‘BuddyPress’?) … which all started from ecommerce ‘MarketPress’ saying they are compatable with the above.

But now – even though I won’t know all the “ins and outs” – I know more than when I started, and can see the potential of this. For example, a membership site where one theme / colours is used throughout, but each author is responsible for the content of their own section (site) .

I have bookmarket the page so I can come back again. Just a pity it’s not in a PDF so I can reference if from desktop!

Oh well … onwards and upwards with the research! (And thanks again for the info)

Mike
February 5, 2015

Hi, great article, I wonder if anyone can help me with the following related problem.

I have a WP Multisite installation using a domain reference . I now want to launch the site using the domain mysite.com.

Is there a way of doing this without editing the database files as this is something I’m not comfortable with. I have moved lots of other WP sites from Domain References which is straight forward, but this is the first Multisite I have worked on and didn’t realise that it was more involved.

Adrimar
February 10, 2015

i did all the steps, but after creating a site, I tried to access the dashboard, but an error page is shown that says: page is not available. What do I have to do to fix it?

Virginia
February 26, 2015

In need of a lot of help I deaigned a web page on WordPress and I would like to make another one for my husbands business but I don’t know how to add the address site. It keep showing the address site from the first site I made.

I am in the process of building a multi-site now. For some reason I was thought that I couldn’t use Multi-site with Buddypress. This will be great for my members and it will be making my site multifunctional. Thank you Carpetcleaninghaddontownship!

Paul Williams
March 23, 2015

Hi Kevin, firstly, this is the most comprehensive and brilliant article I have come across on Multisite, fantastic. I note that you say you can either choose sub-domain or sub-directory, and and the Best Buy example uses the sub-directory installation. I’ve checked their site and noted that you have and , where 577 and 1115 are the sub-directory / store identifier. No probe there, but… they are on a stores.bestbuy.com sub-domain. How is this achieved for them to have both? (hands-up, you got me…. WP newbie!). best regards, Paul

Gypsycanyon
March 24, 2015

Thanks for the great article. I read several trying to figure out how the file structure for the sub-domains worked and where the images were and you are the only one that explained it. I am a “lifetime” Carpetcleaninghaddontownship subscriber and feel silly that I didn’t check here first. Awesome job, keep the tutorials coming!

What a complete guide. It is really professional. I love it.I have only one question. If wordpress blogs can be assigned to multiple subdomains, then I think we can run it on subdomains of other domain using CNAME to the assigned subdomains of existing domain, can’t we? Just though. Thanks..

Because my WP installation exists already for more than 6 months (but I have newest version of WP 4.2.1) I am forced to use subdomain in Multisite installation. I can avoid it in wp-config.php by adding of „define( ‘ALLOW_SUBDIRECTORY_INSTALL’, true );“ What are the risks of this step? Or what are the risk to let default subdomain’s Multisite installation on my existing website?

I have my website about high-speed rail in Czech and I would like to add English version. I thought about this solution: in Czech and in English but Multisite installation force me to have . I hope that after installation old Czech version will survive under with all of external backlinks.

Because my WP installation exists already for more than 6 months (but I have newest version of WP 4.2.1) I am forced to use subdomain in Multisite installation. I can avoid it in wp-config.php by adding of „define( ‘ALLOW_SUBDIRECTORY_INSTALL’, true );“ What are the risks of this step? Or what are the risk to let default subdomain’s Multisite installation on my existing website?

I have my website in Czech and I would like to add English version. I thought about this solution: (dot)cz in Czech and (dot)cz/en in English but Multisite installation force me to have (dot)cz . I hope that after installation old Czech version will survive under (dot)cz with all of external backlinks.

I just have a question regarding multi-site in general. Say for example, I have a website that offers a service, but I want certain details to be different for different markets – would/could I use multisite to cater for that? for example us.example.com and uk.example.com. I suppose the question then is, how would I set up each site to be exactly the same as my original site so that I can then go into each site and make the minor modifications particular to it (i.e. to make it particular to that market). So, how would I do that?

Also, is there a way to set up a system such that a user, when he types into his/her brower, automatically gets re-directed to us.example.com or uk.example.com depending on location?

Appreciate your help!

James Chou
July 13, 2015

Thank you for this guide. I was able to convert my website to a multisite by follow your well written instruction.

I have created the multi site website in wordpress ,
1)i want to create the separate database for separate site
2),but when user registered the user credential should be same for all the site and also when he login one site he should able access other site also . please
3) when he logout ,he should not able to access other site also,and he should logged out from all the site also,