How to Put WordPress into Maintenance Mode

Updated on By

Do you need to put your WordPress website in maintenance mode? Maintenance mode quickly notifies your clients that you’re offline for website maintenance rather than seeing a broken site. It also enables you to perform any maintenance errands in one piece.

WordPress ranks as the most popular website builder in the world. It powers over 33% of the websites on the internet. It is available in two forms: CMS (content management system) and blog hosting service.

WordPress began in 2003 as a simple blogging platform and grew into a CMS and an app development framework. It is an open and free software that you can use to create any type of site that you wish. This includes blogs, online stores, business, and membership websites.

We’ll guide you through a straightforward tactic of putting your WordPress website in maintenance mode. We shall also demonstrate how to make the maintenance mode more enjoyable, useful, and user-friendly.

WordPress Site Maintenance

When you build your website, you need to regularly check it for errors and issues. You also need to keep it relevant and updated. Website maintenance boosts constant traffic growth, fortifies your Google and SEO rankings, and keeps your website vigorous.

This is important for business owners or online store sites to attract new clients and retain existing ones. It is also a decent platform for offering new products, services, and information. Sometimes, this service requires a website maintenance plan that includes the site’s WordPress plugin, themes, and the core.

WordPress also offers site monitoring and backups in its site maintenance package. In this article, we shall discuss these factors in length to ensure that you are fully acquainted with site maintenance, WordPress maintenance mode, and other critical factors therein.

WordPress M.M. (Maintenance Mode)

When you want to make small changes to your WordPress site, you don’t have to interrupt its normal functioning. However, if significant changes are involved, the website must be taken offline and become inaccessible for users for some time.

In an ideal world, your site would not encounter any stoppages. In the event that you want your website to go offline, using a professional phrase such as ‘be back soon’ serves the purpose. This way, you do not risk your client’s info and investment by running a website that has broken down.

What Needs to Happen to put WordPress into Maintenance Mode?

As opposed to a broken website, WordPress maintenance mode lets you show a user-friendly notice to your clients. It also enables you to conduct maintenance tasks safely to ensure that those interested in accessing the site do so successfully.

You can enable WordPress M.M. on your site via four main procedures:

1. Using the in-built WordPress maintenance mode feature.
2. Adding custom code to show a maintenance page.
3. Enabling maintenance mode via your .htaccess file.
4. Using a maintenance mode plugin from WordPress.

Typically, maintenance mode is used by existing websites for two main reasons. These are:

When you need to make changes to your website’s design, WordPress theme, or content.

While making some changes with your site in operation may seem less of a big deal. It may affect your user experience and potentially throw them off. Some people can exit your site by thinking that you have been hacked or that your website is broken.

Although some users might return, most will proceed to the next website.
Moreover, some maintenance mode page designs might include email forms. This way, you can still communicate with your audience while experiencing interruptions.

When you want to mend a significant bug problem that can influence your user’s data.

If you experience a major security bug problem, it is recommended that you take your site offline. This is advisable even for no-logs policy websites.

What’s the logic? Some hackers can insert links that direct users to phishing sites with potential scamming activities. Hence, it is wise to take your site offline and initiate the maintenance mode as you perform your modifications.

Although you might dismiss clients for a while, you will retain your status. When the problems have been solved, you can have your site up and running again.

Other than the two listed and explained reasons, there is another one that is linked to new sites. It is known as the Coming Soon page. It helps you create hype for your yet-to-launch website using a similar plugin or code.
You just modify the page content to specify that the page is coming soon other than using the general maintenance page. With that, you can undertake your administrative tasks regarding your site’s performance. This makes your site fully functional and usable to your clients.

When and Why your Website needs to be in WordPress Maintenance Mode?

Typically, you can decide to customize your WordPress site without having to enable the maintenance mode. You can publish new content, update plugins and themes, and do minor modifications without any stoppage.

Yet, sometimes you might need to develop your site for an extended period. This includes instances where you need to set-up a new theme manually, or want to configure a new plugin that modifies your website’s behavior.

During maintenance, your site might appear broken to your clients for some time. If your website has massive web traffic, it will not be favorable for your clients to notice it. Such cases create a terrible user experience, giving your brand a poor impression.

Setting up a staging site is a common approach to dealing with the situation. It allows seamless site maintenance under a test environment. This pushes the modifications to your live website after completion. Some WordPress hosting firms, including WP Engine, Bluehost, and SiteGround, offer one-click staging sites.

Setting up the maintenance mode using staging sites is mostly for a short period. In the event that the staging site is not in use, your website must be under maintenance mode since you are making changes on the live site. This way, you can solve the lousy user experience issue.

Enabling the maintenance mode on your WordPress website prompts a user-friendly notice directing users to other useful sites. That gives you enough time for website maintenance, especially for non-techs.

WordPress clients with coding skills can use a different approach to put a website into maintenance mode. It involves adding a piece of code to the site’s PHP file in the WordPress core. This snippet of code can be obtained from the WordPress codex. It gives a prompt when a visitor accesses the website.

When maintenance is completed, the code snippet is deleted and the site reverts to normal. People can now access your website even better.

Using a Theme or Plugin

Using a code for your website maintenance mode is a courteous alert for what’s happening in the administrative blocks of your website. This approach is, however, not the most effective when it comes to business keeping conversations. Using a maintenance mode theme or plugin is way much better.

These maintenance mode plugins let you create visually-attractive splash pages where you can insert social media links and email forms. Some of the accessible and top maintenance mode plugins for WordPress include:

  • Coming Soon and Maintenance Mode
  • Minimal Coming Soon Maintenance Mode
  • Under Construction
  • Elementor

1) Coming Soon and Maintenance Mode Plugin

The Coming Soon and Maintenance Mode plugin is substantially customizable. It includes a countdown feature as well. It is an excellent option when you want to quickly set-up a splash page that guides your clients to your social media accounts.

Customization such as size, position, and font color are all pro version features. If you wish to add a progress bar, countdown box, or sign up form for the mailing list, you need to upgrade to the plugin’s pro version.

Plugin Features:

  • Upload a Business Logo
  • Connection to Social Media Accounts
  • Include an SEO meta description and a title

2) Minimal Coming Soon and Maintenance Mode Plugin

This plugin provides a very smooth and state-of-the-art maintenance page option. Search engines can sneak into your site whereas the splash page is noticeable by your visitors. The plugin also offers countless options that will deliver a unique appearance to your maintenance page.

You can use the plugin like a Stealth Login Page. It enables you to build a custom WordPress login URL. However, ensure that you input that custom URL when setting up your basic settings for this type of plugin.

If you don’t do that, you may find yourself shut out of your website. In the maintenance mode, the general wp-admin URL will be inaccessible.

Plugin Features:

  • Organize the order of header, logo, opt-in form, text, and custom code.
  • Content overlap option
  • Fully responsive.
  • The style opt-in form to your favorites (font, button size, and more).
  • Include Analytics code to track user behavior.
  • Upload a favicon, logo, and background image.
  • Develop existing subscriber lists via the MailChimp API.
  • Include custom CSS or HTML.
  • Multiple text selections (positioning, color, size, and more)

3) Under Construction Plugin

This is a WordPress free plugin. It enables you to build a maintenance page even without any tech skills. You just need to select a theme, link social media accounts, and add some details concerning the page. With this, you can have a functional maintenance page as soon as possible.

Your visitors will not see errors or blank pages but a landing page with a great look and feel. Whether you want your site to be under construction or to deactivate the maintenance mode when finished, this plugin simplifies it all for you.

If you choose the end time and date, the plugin will do it all and let you concentrate on critical matters on the website. When using the plugin, you can either select a theme from its library or personalize your maintenance page if you like it customized.

4) Elementor as a Mode Plugin

Like ‘Coming Soon mode,’ Elementor contains an integrated and utterly free maintenance mode feature. You can use the Elementor feature to create your ‘Coming Soon’ pages and maintenance mode. It is fast, user-friendly, and has an impressive and personalized outcome.

When you set on the Elementor’s Maintenance Mode, your website communicates to your search engines. It brings up a notification that it is temporarily offline for maintenance. It achieves this by sending HTTP 503, the temporary maintenance response.

Consequently, search engines recognize to return after a while to check if the website has gone back online. Alternatively, when you set Elementor to ‘Coming Soon,’ search engines receive a notification from your site that things are running normally. This way, they can index the site, as usual, achieved by returning the HTTP200 response.

Learn more about the Elementor page builder

Taking a WordPress Plugin Out of Maintenance Mode

In terms of maintenance plugins, they too can get stuck in maintenance mode. This may be in the event that they have a caching plugin installed, or your host is utilizing a caching layer. In such a scenario, all you need to do is clear your host’s cache or the caching plugin’s cache.

Typically, your host will include a button in the WordPress Admin that says ‘Clear Cache.’ When you finish maintenance work, it is safe to deactivate and uninstall the plugin.

Using a .htaccess File

The .htaccess file denotes a robust site file that commands complex configurations on your site. On Apache-running servers, the .htaccess file lets you adjust your site’s setting without editing server configuration files.

While the files are a potent tool for server management, it can be complicated. Therefore, ensure that you are well-versed with modifications before you begin to edit the .htaccess files. Since the information contained in the .htaccess can be used to compromise your servers, they are always hidden.

You can access .htaccess files in your site’s public_html folder from the file manager of your hosting account, or your FTP client. When you open the files, copy and paste the code.

The code will redirect your entire homepage web requests to a maintenance.html file that you must have created first. This will act as your temporary homepage stand-in. Pay attention to the %{REMOTE_ADDR} section. This is where you substitute the number with your IP address.

It will allow you to access the site anyhow.

The most popular uses of the .htaccess file include

  • Adding redirections for specific URLs
  • Avoid hotlinking
  • Loading custom error pages (e.g., 404 pages)
  • Forcing your site to utilize HTTPS rather than HTTP
  • Password-protect specific directories on your server

If your .htaccess file isn’t in your public_html folder, consider checking ‘Show Hidden Files’ button. Remember that you can employ different directories via multiple .htaccess files. Notionally, you can create a .htaccess file in any directory on your server by making and uploading a simple text file.

You are aiming to cut the number of .htaccess files on your server for many configurations that may delay your server. When your server notices a .htaccess file in a directory, it seeks the file extension in the entire parent directories. This increases server resource usage as the prominent .htaccess files come first.

Using the WordPress Maintenance Mode

When it comes to employing a fast and upfront website maintenance mode for WordPress, WordPress M.M. is amongst the most downloaded plugins. Designmodo crew, a web design blog, creates this free plugin.

You can add the maintenance page to your site to notify your visitors about the work in progress. Alternatively, you can include a ‘coming soon’ page for a new site. Those users with administrative rights are allowed full access to the website, plus the front end.

When you activate the plugin, it sends your site into maintenance mode. From here, you can set a value and unit for info, or use a date with a countdown timer for visitor info. The plugin works well with WordPress multi-site installs. However, it is important to note that it may be uneven with caching plugins.

Currently, the plugin includes more than 600k active installs with a 4/5-star rating. The WordPress M.M can be downloaded by searching it from the dashboard (Add New plugins) or its repository.

Below are the features of WordPress M.M.:

  • Subscription form
  • Countdown timer
  • Fully customizable (change fonts, backgrounds & colors)
  • Impressive design
  • Contact form
  • Works well with WordPress theme
  • Coming soon page
  • WordPress Multisite
  • SEO options
  • Landing page templates
  • Dismiss URLs from maintenance
  • Social media icons
  • Ready GDPR
  • Bot functionality (collects emails efficiently and responsively)

Using Custom Functions

My ‘Custom Functions’ is user-friendly, with an intuitive user interface WordPress plugin. It allows you to quickly and securely add your custom PHP code to your WordPress website. You include it directly from the WordPress admin area without using an external editor.

It is an ideal and straightforward tool to use as your site’s functionality plugin, a necessary tool for your website and authors alike. To add the custom PHP function, you do not need to edit the .php file of your plugin files or theme.

You only need to add your custom PHP in the plugin page field. It will do the rest of the tasks for you. The plugin will automatically add your PHP code to your site without changing your theme files or slowing down your site.
Since the Custom Functions plugin works entirely autonomously with the theme, it is compatible with any theme of your choice. This is irrespective of whether it has a functions.php or not. As such, it will not affect the code copied on the plugin page even when you edit the contents of the functions.php file theme or change it completely.
This is particularly useful when updating plugins or themes as your custom PHP code can never be overwritten. No matter the number of times you switch or upgrade your plugins and themes, your custom PHP code will always be functional.

The plugin page includes CodeMirror-powered code editor. It has options such as line numbering, syntax highlighting, and many more.

Features of Custom Functions

  • Intuitive design
  • Works well with all WordPress themes
  • Lightweight and speedy
  • Right to Left (RTL) compatible
  • Secure code with employing clear coding standards
  • Ready translation
  • Works seamlessly in any modern browser (cross-browser compatible)

Custom Functions Key Functions

  • Assesses the entered codes for critical errs
  • Insert custom PHP code into the website
  • Active line highlighting
  • Easy disable option for WSOD
  • Line numbering
  • The editor supports Tab identification
  • Code syntax highlighting
  • Can temporarily disable all custom PHP code

Custom Functions Pro Features

  • Well documented
  • Fifty-six syntax highlighting themes
  • Can easily customize the code editor by choosing the preferred settings
  • Can use shortcut keys on both PC and Mac for the commands Replace, Search, and more
  • Unlimited number of function fields
  • Toolbar with useful buttons like Redo, Undo, and more
  • Auto backup for all functions to a downloadable text file
  • No ads on the settings page
  • Separate deactivation and activation of functions

Creating Your Page

You might notice that lots of WordPress websites include different layouts for unalike pages. A custom page lets you have a unique design in appearance from WordPress’s regular pages. It also enables you to create pages and posts.

Your WordPress theme controls your page’s appearance via the page.php template file. While not all pages are similar, the template influences all WordPress single created pages in any form. Minimal changes in their appearance and layout can make them more useful and unique.

Building a WordPress custom page template requires basic HTML, PHP, and CSS skills.

1. Open a plain text editor (such as Notepad) on your PC and add this code snippet in the blank file at the top.
The code tells WordPress that this is a template file that should be known as CustomPageT1. Give your template any name that works for you. After adding the code snippet, save the file under any name on your desktop, with .php as the file extension.

The next step requires you to connect to your site via an FTP client.

2. When connected, enter your child theme folder (current). In it, you will find /wp-content/themes/directory. Then, upload your custom page template file to your theme.

3. Log in to your WordPress Admin Area and create a new page. Visit ‘Page Editing,’ scroll down to ‘Page Attributes,’ where you will find a template drop-down menu. Click on it to select the template you created.

If you modify the template and visit the page, you will see a blank page where you begin to edit your custom page template.

How to Edit Your Custom Page Template?

Your custom page template resembles any other WordPress theme file where you can add any PHP code, HTML, or template tags. To make the creating process easy, copy the existing page template provided by your theme.
1. Launch your FTP client and click on the theme folder. You will find a page.php file that you will download to your PC.

2. Open this page.php file in an editor such as notepad. Copy all the content apart from the header section.

3. Launch your custom page template file and paste for a striking appearance.

4. You can now save your custom page template file and upload it back to your theme folder via FTP. Visit the page you built through the custom page template. It will resemble the other WordPress pages.
From here, you can continue to edit your custom page template file and customize it as you wish. You can add content by editing your page in the WordPress page editor screen.

What Happens If You Get Stuck in WordPress Maintenance Mode?

If you ever experienced the WordPress stuck in maintenance mode, then I’m sure you know just how annoying it is. Typically, this state occurs when you are bringing a bunch of plugins or themes, or the core WordPress files up-to-date.

Your website is wedged in the updating process and leaves you staring at the website maintenance screen. When WordPress gets stuck in maintenance mode, it does not represent an error but rather a notification page.

When making updates on your site, WordPress automatically creates a temporary .maintenance file in your site’s root folder. The file automatically deletes itself to disable the maintenance mode after a successful update.

If your WordPress hosting server has a slow response or low memory problems, your updates will break and interrupt the process. Your site will move from maintenance mode to normal but still retain the screen, which you can only remove manually.

If you get stuck in the WordPress maintenance mode, you have to fix this error.

Fixing the ‘Stuck in Maintenance’ Error

The easiest method to get your website out of maintenance is by deleting the maintenance file. You must connect your files via FTP to locate your website’s root folder. Alternatively, you can find them in your website’s hosting settings.

If the WordPress root directory contains no such file, ensure that you check your FTP’s client option to display the hidden files. The FileZilla client can show hidden files in the menu bar – select server> Force Showing Hidden Files.

When you remove the maintenance file, your site should exit maintenance mode.
The WordPress maintenance mode page will also be removed from your site.

What If there’s No Maintenance File?

If you access the hidden files but still can’t find the .maintenance file in your root directory, there are some other methods you can use to solve the problem.

First, rename your ‘plugins/’ folder to ‘_plugins/’ and try to access your website. If the trick works, retitle the folder back to ‘plugins/.’ You can try to disable each plugin on your website and re-enable them until your website breaks over to locate the hitch plugin.

If the site is inaccessible even after you rename the plugins folder, deactivate your WordPress theme by renaming the folder as mentioned above. When you find the problem plugin or theme, you install the plugin update manually for appropriate functioning.

Should the maintenance error continue, you can try one more trick of updating the ‘wp-activate.php’ file. The file is located where you found the .maintenance file.

1. Open the file using the file manager of your WordPress hosting firm, or download the file to your PC using FTP. You will find this code snippet:

define (‘WP_INSTALLING, true)
and change true to false
and the code will resemble

define (WP_INSTALLING, false)

2. When you complete making the variations, save and re-upload the file into a similar place via your FTP client. If the changes are made using your host’s file manager, just save the file. With that, your website is now out of the maintenance mode.

This problem can be prevented from recurring by performing a few errands. As mentioned above, getting stuck in WordPress M.M results from low memory problems and slow server connections.

The easiest way to avoid this is by upgrading to a managed WordPress hosting provider with a higher performance or plan. If you are unable to upgrade to a better hosting provider or plan, try to update plugins and themes one at a time other than in bulk.

While you may want to update in bulk because it seems more natural, any delayed connection can take your site to maintenance mode. Therefore, it is important to make your updates single to avoid needless conflicts.
Overall, you should begin by ensuring that you start creating regular backups for your website before you begin updating. You can employ WordPress plugins to create restore points that will direct you to the last day it was in proper functional status.

This approach does not necessarily offer a prevention tactic for remaining in the website maintenance mode screen. Yet, it is a viable solution in case you get stuck.

Compatibility Problems with WordPress

You can also ensure that your WordPress website is up-to-date, and the plugins you pick to update work well with your WordPress version. Luckily enough, WordPress includes a feature that notifies you about the compatibility of your WordPress plugin. You will find this information on the Updates screen.

The rules are easy to follow:

  1. Do not update a theme that is not 100% compatible with the version of WordPress that you have.
  2. Always ensure that you perform your tests in a controlled environment.
  3. Use a dedicated maintenance plugin that allows you to surge discussions.
    This way, you will be able to create a hype for your brand while still maintaining your visitors.

Wrapping Up

Knocking your website into WordPress website maintenance mode has several uses. It’s not set aside only for doing core and regular updates. It is a valuable technique for making core changes to your site’s functionality or design.
Whether you are doing simple plugin updates or making complete site changes, maintenance mode is a useful tool in your developer’s toolkit. That way, your website users can get information on any ongoing maintenance activity.

Maintenance mode adds more trust in most of your clients as they can wait for you to finish your errands for the website to get up and running. From using a .htaccess file to custom functions to maintenance and plugins or themes, you can communicate effectively to your users.

Getting stuck in maintenance mode is common. You can solve the problem by either upgrading your hosting services or increasing memory to avoid the interruption. Website maintenance mode can help businesses keep their conversion rates even when their site is offline.

Further reading:

Share This Post:
Disclosure: This page contains external affiliate links that may result in us receiving a commission if you choose to purchase mentioned product. The opinions on this page are our own and we don't receive additional bonus for positive reviews.