Whenever WordPress performs an update to the core software or a plugin, your website will enter maintenance mode. This means that a message will be displayed when someone tries to access your website, letting the user know that the website is temporarily under maintenance. Working on updates without putting your website in maintenance mode could lead to unhappy visitors and unwanted errors.
In some situations, you can be left with the dreaded scenario of having WordPress get stuck in maintenance mode. It is a common scenario, but the reasons are varied and you need to learn a few things about it before doing anything. All Content Management Systems have their ups and downs, and this one is the most widely-spread WordPress problem. Worry not. The information you will find in this article should offer the easiest WordPress fix for it. Continue reading to learn more.
First of all, you should understand what WordPress maintenance mode is. Whenever a website requires updates, it should be taken down until the changes are implemented and brought back online once the update is properly installed. Otherwise, user actions taken on the site while updates are being performed may lead to corrupted data in your database. To safely update, the website will enter a state that is called maintenance mode. This mode replaces your main website with a page that shows a message to let users know about the situation.
The WordPress maintenance mode is an automated feature of the CMS. Each time you run a general WordPress update, the mode will activate without you having to do anything. WordPress’ core updates are mostly related to security and fixing bugs, so they are indeed absolutely required. You certainly can’t skip them for fear of having your WordPress stuck in maintenance mode.
Besides software updates, there are two other reasons why people use the WordPress maintenance mode:
Sometimes, people use the WordPress maintenance mode when they do website redesigns. The WordPress maintenance mode page can be customized and turned into a coming soon page. This is often used to build interest around the rebranding. In any case , the first two reasons are the most common ones.
Even though the WordPress maintenance mode works well in most cases, there are times when it gets stuck. When you decide to update a theme or a plugin, WordPress will automatically put your site into maintenance mode. Updates shouldn’t take longer than a few minutes to install. If the process gets interrupted and the request is not performed correctly, you can have your WordPress in maintenance mode. The causes behind this interruption can be diverse: a connection error, a browser bug, closing the update page during the process, and other small technical details.
Another cause could be related to attempting to update a plugin to a version that is not compatible with your theme or your WordPress version. The process can go wrong if the plugin you are trying to update doesn’t go well with other add-ons that you’ve previously installed. Simply closing your browser by mistake in the middle of the update process can lead to having your WordPress getting stuck in maintenance mode.
Regardless of the cause, there are some simple fixes that you can try.
When WordPress is stuck in maintenance mode, a file is created in the root directory of the CMS on your computer. Normally, the file is deleted once the update is completed. When the update is not completed successfully, the file remains there. So WordPress can get stuck in maintenance mode even though the file is no longer there. Luckily, there are easy solutions.
If the update didn’t complete successfully, the .maintenance file will still be present in the root folder of your WordPress directory. You will have to remove that file manually. To do so, follow the steps listed here:
Once you delete the .maintenance file, the website should go back to normal immediately. If you still encounter problems, try clearing the browser cache and/or your WordPress cache.
If you have your WordPress stuck in maintenance mode because you’ve tried to update a plugin or a theme and it was not the appropriate thing to do (perhaps the plugin or theme is incompatible with your WordPress version), you will need to follow these steps instead:
Performing backups of your site regularly is a surefire way of keeping everything in order. Before making any changes to the site, save a backup somewhere handy. To avoid having your WordPress stuck in maintenance mode, you may want to update plugins one by one and refresh the page after each update was completed to make sure everything works as it should. Follow these steps to ensure that the plugins or themes you want to install work well with your WordPress site:
Executing multiple operations at once may lead to getting your website stuck in WordPress maintenance mode. Be patient and run the updates one at a time, even though you may want to get it over with faster.
The issues with WordPress maintenance mode can be averted if you follow the prevention methods listed here. It’s better to sidestep any potential problem rather than fixing it. Luckily, in this particular situation, fixing the issue is not that difficult either. Having your WordPress stuck in maintenance mode is not a problem that requires day to fix, but users may want to access your site at that very moment and they can get frustrated when they are greeted by a maintenance message. Arm yourself with this knowledge so that you can fix this issue quickly whenever it presents itself.
If you enjoyed reading this article on how to fix the WordPress stuck in maintenance mode, you should check out this one about how to fix the WordPress missing a temporary folder.
Interesting read: A Comical Guide to Webpack, Vue.js 2, Gulp and WordPress
Free cheat sheets available
Subscribe to download a set of cheat sheets for CSS, JS, and HTML
You'll receive an email with the cheat sheets in an instant.