WordPress Multisite is a great feature of WordPress. But it’s not always the right feature.
I just disabled Multisite on my personal blog. I used it for the wrong reasons back in the day, and have either deleted or moved the sites in the network. It was time to disable Multisite completely.
There isn’t much documentation on this, and none that’s totally thorough. Here are the primary steps, in order of how you should disable Multisite to really get rid of everything:
Remove any remaining sites
Remove all sites from your Multisite installation, other than your main site, by going to My Sites > Sites in the WordPress admin. If you need to move a subsite to its own WordPress install, that’s out of scope from this article, but also possible if you roll your sleeves up.
Remove unwanted users
Remove any users you don’t want to have access to your website anymore. Just because you delete a site doesn’t delete users associated with that site, because the users in Multisite are global. So you’ll want to clean up your user accounts by going to the Users section of the admin.
Remove Multisite lines from WP Config
Your wp-config.php
file will have some lines that are the key to enabling Multisite. They will look very similar to these:
You need to remove these lines from WP Config, which requires FTP access.
[gist id=”b876ad16df0630ee2046″]
Restore .htaccess to a single site setup
Next can be a tricky part. You’ll want to remove the Multisite language from your .htaccess
file if your hosting environment is Apache based (versus Nginx). A simple, default WordPress .htaccess
file looks like this in most instances.
[gist id=”f864ac72304394f6dae4″]
However, your install could also have additional (legitimate) lines that have been added by plugins, especially if you have caching plugins enabled.
Therefore, keep an eye out for lines of code that are commented, which plugins should use to denote the beginning and end of their custom code. For instance, custom .htaccess
lines from WP Super Cache are wrapped by lines that say # BEGIN supercache
and # END supercache
.
Drop Multisite database tables
Now your site should function normally in non-Multisite mode, but you still have some cleanup to do. The first step is to delete, or drop, Multisite specific database tables.
wp_blogs
wp_blog_versions
wp_registration_log
wp_signups
wp_site
wp_meta
If you are using the domain mapping plugin, you will also be able to drop the following two tables:
domain_mapping
domain_mapping_logins
You can do this from within phpMyAdmin if you have cPanel access with your host.
Delete Multisite specific plugins
I had a number of Multisite specific plugins to do things like map domains, clone subsites, and others. Now is a good time to go through your list of plugins and delete what you no longer need.
As a sidenote, some of these plugins (like the domain mapping one I specifically noted above) create their own tables. So if you have other tables created by plugins that you just deleted, you may want to drop those as well. But be careful to confirm that the tables you are dropping are no longer needed.
Another place where you may have a Multisite specific plugin or two is the mu-plugins
folder. This folder now stands for “must use” and holds single file plugins that cannot be activated or deactivated. If they are in the mu-plugins
folder of wp-content
, they are active. Multsite plugins are sometimes required to be placed here.
So, inspect your mu-plugins
folder in wp-content
and delete what you don’t need.
Remove unnecessary folders from wp-content
A step many people forget is to remove unnecessary folders from the wp-content
directory. Multisite creates a folder titled blogs.dir
in wp-content
. When Multisite is enabled, the blogs.dir
directory has folders for each site where uploads for that site are stored. So we can delete blogs.dir
now.
Reactivate plugins that were previously network activated
This is a step that is easy to miss. I had a number of plugins network activated because I knew I’d use them on any site I had on the network. Well, when you disable multisite, you remove the network activation features, and those plugins are now inactive on your main site. So you need to go back and activate those you still want to use.
As another sidenote for the interested reader (not specific to this tutorial), if you ever have a network activated plugin and want to network deactivate it but still keep it activated on sites currently using it, Konstantin Kovshenin has you covered.
Enjoy your cleaned up WordPress installation
Congratulations, you are done! You have successfully deactivated WordPress Multisite, and you’ve probably give your website some needed spring cleaning while you were at it.
Hi,
thank you for this great and informativ tutorial.
I have only one problem, when I delete folders wich you us menchioned, than the connection to the database ist lost and wordpress miss this folders in a error messages.
In my MySql Database I have tabels whit wp_4_ in the table name, which I think this is the multipage site and normal wp_ tables, wich are the origin tables.
To you now what is going wron?
All the best Theo
thanks!
I am having trouble finding the Multisite specific data tables. I use Cyberduck as an FTP client, is that the same as phpMyAdmin? Bluehost integrates phpMyAdmin in its cPanel, so I am confused as to how to access my data tables. Do I just go to my FileManager and try to find the datatables there? I tried that, but cannot seem to to wp-blog, etc…
I am having trouble finding the Multisite specific data tables. I use Cyberduck as an FTP client, is that the same as phpMyAdmin? Bluehost integrates phpMyAdmin in its cPanel, so I am confused as to how to access my data tables. Do I just go to my FileManager and try to find the datatables there? I tried that, but cannot seem to to wp-blogs, etc…