In essence it is just the same as a normal plugin but with some differences. The main difference being that you can’t enable or disable them via WP admin. It is enabled as long as the directory
wp-content/mu-plugins contains the plugin file(s). Secondly, you can’t see the plugin in WP admin and it can’t easily be updated. Updates can only happen manually. And lastly, Must use plugins also load before normal plugins and always in alphabetical order.
Otherwise it comes down to use cases and preferences. Do you want some code to always run? Then must use plugins is the way to go.
For more detailed information about must use plugins, check out the official documentation.
How to add a must use plugin
If you already have a must use plugin PHP file you can go ahead and log into the server via SFTP. From here you navigate to
~/public/wp-content/mu-plugins and simply place the PHP file inside. If you do not see the
mu-plugins directory you can usually right click and create directory with the same name.
You can also do this by SSH which also is a bit faster. Only thing you need to do is log into the server and use one of our built-in text editors right away. For example:
Add your code and save. Use this command to create the directory should it not exist:
And as always, should you have any additional questions please don’t hesitate to contact our support chat at servebolt.com!
Give us your feedback on this article
Want to speed up your site, easily?
Set up your site on Servebolt, free of charge for 60 days, and see for yourself how fast it can be on our extremely fast hosting.
A faster site converts better, ranks better on Google, and is better for the climate.