Are you looking to set up and install a WordPress multisite network? WordPress comes with the built-in ability to create multiple sites using the same WordPress installation.
The WordPress multisite network is used by blogs, schools, and businesses that need to run separate sites but want to manage them from a single dashboard.
In this article, we'll show you how to properly install and set up a WordPress multisite network.
Since this is a comprehensive article, there is a sort of table below for easier navigation by topic.
WordPress Multisite Network Basics
* What is a WordPress Multisite Network?
* Benefits of using a WordPress multisite network
* Disadvantages of using a WordPress multisite network
* Who needs a WordPress multisite network
WordPress Multisite Network - Installation and Setup
* WordPress Multisite Network Requirements
* Choosing a domain structure for a multisite network
* Setting up replacement subdomains
* Enabling WordPress multisite networking features
* Setting up a WordPress multisite network
WordPress multisite network - configuration
* Configure network settings
* Opening a multisite network for registration
* New site settings
* Upload settings for multisite network
* Plugin settings
Setting up default content, themes and plugins
* Adding new sites to the WordPress multisite network
* Adding themes and plugins to the multisite network
* Adding default content to new sites
Troubleshooting and FAQs
* Troubleshooting WordPress multisite network issues
* Frequently asked questions about the WordPress multisite network
What is a WordPress Multisite Network?
A WordPress multisite network allows you to run and manage multiple WordPress sites or blogs from a single WordPress installation.
It allows you to instantly create new sites and manage them using the same username and password. You can even allow other users to register and create their own blogs on your domain.
The WordPress multisite network comes with advanced settings that you can use to customize each site/blog on your network.
Benefits of using a WordPress multisite network
In many situations, a WordPress multisite network can be more beneficial than managing multiple standalone WordPress sites. Here are a few benefits of using a WordPress multisite network:
* As a network administrator, you can easily manage multiple sites from a single control panel.
* Each site on the network can have its own administrators, and they will only be able to manage their own site.
* You can install plugins/themes and activate them on multiple sites with just one download.
* A multisite network also makes it easier for you to manage updates. You only need to update your WordPress, plugins or themes on one "master" installation.
Disadvantages of using a WordPress multisite network
Creating a WordPress multisite network is not always useful when managing multiple sites. Here are some disadvantages you should keep in mind before setting up a multisite network:
* All sites online share the same resources. This means that when your network is down, all sites within the network go down.
* It is not easy to manage traffic and server resources for entry-level users. In the event that one of the sites receives unexpected traffic, it will affect all other sites on the network.
* In case one site gets hacked, it means all sites on the network will be hacked.
* Some WordPress plugins may not work well on a multisite network.
* The WordPress multisite network is not supported equally by all web hosting providers, which limits your options. This will be discussed later in the article.
Who needs a WordPress multisite network?
Just because you manage multiple WordPress sites, doesn't mean you have to use a multisite network.
There are independent tools for managing multiple WordPress sites from a single dashboard. Tools like InfiniteWP or iThemes Sync make it easy to maintain multiple sites under one control panel, without switching from one site to another.
Here are a few situations when creating a multisite network makes sense:
* Magazine site with different sections managed by different teams
* Business site with subpages for different locations and branches
* Government and nonprofit sites can use WordPress multisite for different departments, locations, and regions
* Your network of blogs running on multiple subdomains
* Schools and colleges that allow students to create their own blogs on school servers
WordPress Multisite Network Requirements
All sites on a WordPress multisite network share the same server resources. This means that the most important thing you need is good WordPress hosting.
If you plan to have a few sites with low traffic, then shared hosting will probably suffice.
However, due to the nature of a multisite network, as your sites grow you will need VPS hosting or a dedicated server.
In addition to web hosting, you'll need a basic knowledge of how to install WordPress and edit files using FTP.
Choosing a domain structure for your multisite network
On a WordPress multisite network, you can add new sites using subdomains or subdirectories.
Example subdomain:
http://site1.example.com
Example subdirectory:
http://example.com/site1/
If you choose subdomains, then you will need to configure backup subdomains on your server. We'll show you how to do that in the next step.
On the other hand, if you choose subdirectories or URLs based on your multisite network path, then you can skip the next step.
Setting up backup subdomains
If you choose to use subdomains for sites on your multisite network, then you will need to set up backup subdomains for your multisite network.
To do this, you must first log into the cPanel control panel of your WordPress hosting account. After that, you need to scroll to the Domains section and then click on the Subdomains button.
Note: Depending on the web hosting service, your cPanel dashboard may look slightly different from the image above. That's what cPanel looks like on Bluehost. On the next page, you need to enter * in the subdomain field and select your main domain from the dropdown menu.
Cpanel will automatically detect the initial document and display it in the box below. Then click the Create button to create a backup subdomain.
Enabling the WordPress Multisite Network Option
The multisite network option is built into every WordPress installation. All you have to do is install and set up WordPress as usual. After that, you just need to enable the multisite option.
You can also enable the multisite option on any existing site. Before enabling multisite, don't forget to make a complete backup of your site.
To enable multisite, connect to the site using an FTP client or cPanel file manager, then open the wp-config.php file and edit it.
You need to add the following code to your wp-config.php file just before the following line of code. That's all, stop editing! Happy blogging. */ line.
/* Multisite */
define( 'WP_ALLOW_MULTISITE', true );
Once done, save and re-upload your wp-config-php file to the server. This code simply enables the multisite option on your WordPress site. After enabling it, you need to set up a multisite network.
Setting up a WordPress multisite network
Now that you've successfully enabled multisite on your WordPress site, it's time to set it up.
If you are setting up a multisite network on an existing site, then you need to deactivate all plugins on your site.
Simply visit the Plugins » Installed Plugins page and select all plugins. In the drop-down menu, you need to select Deactivate and then click the Apply button.
You can now go to the Tools » Network Setup page to configure your multisite network.
On the network setup screen, you will see a notice that you need Apache's mod_rewrite module to be installed on your server. This module is installed and enabled on all the best WordPress hosting providers.
The next thing you need to do is tell WordPress what domain structure you will use for your sites in the network, eg. subdomains or subdirectories.
After that, you need to provide a name for your network and make sure that the email address in the network administrator is correct.
Click the Install button to continue.
WordPress will now show you some code to add to your wp-config.php and .htaccess files, respectively.
You can use an FTP client or the file manager in cPanel to copy and paste the code into these two files.
After that, you will need to log in to your site again to access the multisite network.
Configuring network settings
Now that you've set up your multisite network, it's time to configure your network settings. You must go to the Network Dashboard to change network settings, add new sites, or configure other settings.
When you move your mouse over the My Sites section in the toolbar, a popup will appear and click on Network Admin » Dashboard.
This will take you to the multisite network control panel. You will notice that there are new menu items for multisite network management. You'll also see the Right Now dashboard widget, which allows you to create new sites and add new users.
To configure the network settings, you need to click on the Settings link in the side menu.
The first option on the network settings page is to set the site title and email address administrator. These fields will be automatically filled with the network address and email address of the administrator that you entered during setup.
Opening your multisite network for registration
The Registration Settings section of the Network Settings page is probably the most important thing in setting up your network.
User and site registrations are disabled by default online.
You can choose to open a site for a new registered user or to allow existing users to create new sites or to allow both.
If you are opening a multisite registration network, you can check the box next to the Registration Notification option to receive email notifications every time a new user or site is registered.
If you want to allow individual administrators to add new users to their sites, then you can select the checkbox next to the Add New Users option.
The Limited Email Registration option allows you to limit user or site registration from email addresses from specific domains. This is especially useful if you want to allow only people from your organization to register and create users or sites.
Similarly, you can also ban certain domains from registration.
New site settings
The New Site Settings section allows you to configure default options for new sites on your multisite network.
In these settings you can change the welcome email and the content of the first default post, page and comment.
As a network administrator, you can change these settings at any time.
Uploading settings for your multisite network
It's important to watch your software resource usage. Under the Upload Settings section, you can limit the total amount of space the site can use for uploads.
The default value is 100MB, which is probably good for at least 100 photo uploads. You can increase or decrease this space depending on how much disk space you have.
The default file types for uploading are images, audio, video and pdf files. You can add additional file types if you want, such as doc, docx, ott.
After that, you can choose a file size limit, so users can't upload huge files to the server.
Setting the plugin menu
Then, you can proceed to the menu setting. You can approve the admin menu for the plugins section of your multisite network.
Enabling this will display the plugin menu for the respective site administrators. They can activate or deactivate the plugin on their individual sites, but they cannot install new plugins.
When you are satisfied with your settings configuration, be sure to click the Save Changes button.
Adding new sites to your WordPress multisite network
To add a new site to your WordPress multisite network, simply click on the Sites sub My Sites » Network Admin menu in the admin toolbar.
This will show you a list of sites on your current multisite installation. By default, your primary site is listed as the only site in a multisite network.
To add a new site, click the Add New button at the top.
On the Add New Site page, you need to provide the site address. You don't need to type the full address, just the part you want to use as a subdomain or subdirectory.
Then you need to add the title of the site and enter the email address of the site administrator.
You can add an administrator email address that is different from the one you currently use to manage your multisite network.
If the email address is not currently in use by a user, WordPress will then create a new user and send the username and password to the email address you entered.
When you're done, click the Add Site button.
The new site will be added to your multisite network. As a network administrator, you will also receive an email about the registration of the new site.
If you have created a new user, that user will receive an email with instructions for setting up a new password and login.
Adding themes and plugins to a multisite network
By default, administrators of individual sites in a multisite network cannot install themes and plugins independently.
As a network administrator, you can install the appropriate plugins and themes so that they are available for all sites on your network.
Installing themes on your multisite network
To add topics, go to the page My Sites » Network Admin » Themes.
On this page, you will see a list of the currently installed themes on your WordPress multisite network.
You can make a topic available to other sites by clicking the Network Enable link below that topic. You can also disable a topic by clicking the Network Disable link below that topic. Note: The Network Disable link will only be displayed when the theme is enabled.
To add a new theme, you need to click the Add New button at the top of the screen and then install the WordPress theme as you normally would.
Once the new theme is installed, you'll be able to make it available to other sites in your network using the Network Enable link.
Setting the default theme for your multisite network
After you add several themes, WordPress will still activate the default WordPress theme for each new site.
If you want a different theme to be the default theme for the new site, then you need to add the following code to your wp-config.php file.
// Setting the default theme for new sites
define( 'WP_DEFAULT_THEME', 'your-theme' );
Replace your-theme with the name of your theme. You will also need to use the names of the folders that the theme resides within, which you can find out by looking at the /wp-content/themes/ folder.
Installing plugins for your multisite network
Similarly, you can visit the page My Sites » Network Admin » Plugins to install plugins and click the Network Activate link below each plugin to activate them on your multisite network.
Below are a few basic WordPress plugins we recommend for every site:
* WPForms – the best WordPress contact form plugin, which allows you to quickly create a beautiful contact form using a drag and drop builder
* Yoast SEO – the most comprehensive WordPress SEO plugin, which can help you attract more visitors from search engines
* SeedProd - site administrators may want to see the site under construction page until the site is complete. SeedProd allows them to add nice landing pages coming soon or nice pages the site is under maintenance
* WP Mail SMTP – WP Mail SMTP helps you solve the problem when WordPress does not send emails using the SMTP server, which are important because the site registration message is sent
Note: If you previously enabled the Plugins Menu option for site administrators in the network settings, then they can activate or deactivate the installed plugins themselves. Site administrators cannot delete or install new plugins themselves.
Adding default content to multisite sites
WordPress allows you to edit some default content for each site on your multisite network. You can go to the page Settings » Network Settings and add them to the New site settings section.
You can edit the default article, page and comment content. We recommend that you replace the default content with something more useful for your site administrator.
What if you want additional default content to be added to each new site?
WordPress does not provide the ability to create additional default content for new sites. If you want to do this, you will need to add custom code to the WordPress multisite network.
In this example, we will add a new default page that will be created for each new site.
add_action('wpmu_new_blog', 'wpb_create_my_pages', 10, 2);
function wpb_create_my_pages($blog_id, $user_id){
switch_to_blog($blog_id);
// create a new page
$page_id = wp_insert_post(array(
'post_title' => 'About',
'post_name' => 'about',
'post_content' => 'This is an about page. You can use it to introduce yourself to your readers or you can simply delete it.',
'post_status' => 'publish',
'post_author' => $user_id, // or "1" (super-admin?)
'post_type' => 'page',
'menu_order' => 1,
'comment_status' => 'closed',
'ping_status' => 'closed',
));
restore_current_blog();
}
You can use the same code with a few modifications to create default articles for new websites. Look at the following code:
add_action('wpmu_new_blog', 'wpb_create_my_pages', 10, 2);
function wpb_create_my_pages($blog_id, $user_id){
switch_to_blog($blog_id);
// create a new page
$page_id = wp_insert_post(array(
'post_title' => 'A sample blog post',
'post_name' => 'sample-blog-post',
'post_content' => 'This is just another sample blog post. Feel free to delete it.',
'post_status' => 'publish',
'post_author' => $user_id, // or "1" (super-admin?)
'post_type' => 'post',
));
restore_current_blog();
}
Troubleshooting WordPress multisite network issues
The most common problems with setting up a WordPress multisite network are due to incorrect configuration of backup subdomains and domain mapping issues. Make sure your web hosting provider supports backup subdomains before setting up a multisite network.
The following are some other frequently asked questions and how to solve them quickly and easily.
Troubleshoot login issues when installing a multisite network
Another common problem is that when using a WordPress multisite with subdirectories, some users are unable to login to their sites control panel after adding the necessary code to the wp-config.php file.
To fix this, try replacing the following line of code
define('SUBDOMAIN_INSTALL', false);
in the wp-config.php file with the following line of code
define('SUBDOMAIN_INSTALL', 'false');
WordPress Multisite Network FAQ
Many users ask a lot of questions about the WordPress multisite network and how to use it more effectively. The following are the most frequently asked questions and their answers.
1. Can I manage my site better within a multisite network?
The answer to this question usually depends on your usage. For example, if your sites are not interconnected, you would be better off with a multi-site management tool like InifiteWP.
If you manage multiple sites for e.g. restaurant chain, university or news portal, then WordPress multisite will be more useful to you.
2. Does WordPress Multisite make my sites faster?
Once again, it depends on several factors. Better WordPress hosting with a server that has a lot of resources will allow your multisite to be faster, but with those resources, your single site would also run fast.
However, on shared hosting, any spike in traffic will increase memory usage and slow down all sites on a multisite network simultaneously.
3. Can I add an online store to a WordPress multisite network?
Yes, you can add an online store to a WordPress multisite network. You will most likely use an eCommerce plugin such as WooCommerce for this, which is compatible with the WordPress multisite network.
4. Can I install 'x plugin' on my WordPress multisite?
Some WordPress plugins may not be compatible with the WordPress multisite network. Usually, the authors of those plugins mention this on the plugin page, so you can avoid installing a plugin that might not work on a multisite network. However, if it is not mentioned, then it is assumed to be compatible with a multisite network.
5. How can I share user logins and roles on a multisite network?
By default, a user who is registered on one site cannot register or be added to another site on the same network. This is because they are already registered in the shared WordPress database. However, they do not have user role privileges on other sites.
You can use independent plugins like WP Multisite User Sync to synchronize users across the network. However, you have to be careful, because you can end up giving someone admin privileges on the site.
We hope that this article helped you learn how to install and set up WordPress multisite network and in case you have additional questions about WordPress multisite network and the possibility of creating sites in general, you can contact us at this link, to get answers to your questions.
Text taken from wpbeginner.