In essence, it is just the same as a normal plugin but with some differences. The main difference is 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. Lastly, Must use plugins 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 are 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 a directory with the same name.
You can also do this by SSH which also is a bit faster. The 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!