LIFE TANRIKULU
Take a fresh look at your lifestyle.

What is WordPress Maintenance Mode? How to use?

WordPress maintenance mode It is a feature used when your site is not yet active or when work is carried out.


If you are just creating your site or want to make a major update, it would be a logical move to use WordPress maintenance mode to prevent your visitors from encountering errors. To do this, you can use WordPress maintenance mode plugin or html ready themes. You may also see WordPress under construction.

How to create wordpress maintenance mode in this guide? How is the design done? I have given detailed information about it. You can find details about using WP Maintenance Mode by reviewing the information below.

How to Enable WordPress Maintenance Mode?

1. Maintenance Mode Add-on

This method is for those who want to activate WordPress maintenance mode without touching a single line of code.

All you have to do WP maintenance mode plugin download and install. After activating, you need to configure the settings of the plugin. To do this, go to the tab on your left and Settings -> WP Maintenance ModeSelect .

On the settings page, you will see 5 tabs: General, Design, Modules, Manage Bot and GDPR.

wordpress maintenance mode plugin
wordpress maintenance mode plugin

We will discuss all the tabs and some important options in the following sections.

General (General)

In the first part, we will talk about the General tab. At the top of the General tab you will find Status. To activate this plugin and put your website in WordPress maintenance mode, you need to change it to Activated. Under Status you will see Bypass for Search Bots feature. If you change this option to Yes, search engines will be able to access your website during maintenance.


Next, there are Back end Role and Front end Role options. In these you can choose which user roles your backend will reach when it is in maintenance mode. If you do not set this, only the Administrator will have access.

Design

The Design tab is where you will create an eye-catching landing page. To start creating the landing page, you can go directly to the Title (HTML Tag) option. In this section, add the heading and text of your landing page along with the title.

When you're done with the message, you can change the background of your maintenance page. For example, you can change its color or go further and use a picture as a background.

Modules

In this tab you can set the countdown timer. Set the start and end time. Additionally, you can ask your visitors to subscribe to receive notifications when your site is live again.

The next option in the Modules tab is where you can configure your social networks. All you have to do is place your social media account link. The plugin will automatically display the social media button icon on the page.


Manage Bot

The next useful tab is the Manage Bot tab. This tab allows you to add a chatbot to your landing page. Thus, you can maintain interactive communication with your visitors even though you are in maintenance mode. You can give the bot a name and even add an avatar.

GDPR

If you want to ask your visitors to subscribe on your landing page, you need to set up your GDPR tab. GDPR stands for General Data Protection Regulation. Since you collect the data of your visitors, you need to activate it.

When you are done with your preparations, click the Save settings button and visit your website.

2. Using Function

This method requires editing the functions.php file. before proceeding Backup your WordPress site I highly recommend getting it.

Remember the default maintenance page that is automatically set up by WordPress when your site is under maintenance? You can manually put your WordPress into maintenance mode and customize the page without any additional plugins.

All you have to do is insert these lines of code into your theme. functions.php add to the end of the file:


// Activate WordPress Maintenance Mode
function wp_maintenance_mode() {
if (!current_user_can('edit_themes') || !is_user_logged_in()) {
wp_die('<h1>Under Maintenance</h1><br />Website under planned maintenance. Please check back later.');
}
}
add_action('get_header', 'wp_maintenance_mode');

Change the text between quotation marks on line 4 to customize the maintenance message.

3. Editing .htaccess

This method requires making changes to the .htaccess file. before proceeding .htaccess We recommend that you back up your file.

Also, keep in mind that if you use this method, you won't be able to access your WordPress admin dashboard as all requests will be redirected to the maintenance.xml file.

You can find the .htaccess file in the root directory of your website. Just name your current .htaccess file .htaccess_default , create a new file named .htaccess and add the following code snippet:

RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_URI} !^/maintenance\.html$
RewriteRule ^(.*)$ https://example.com/maintenance.html [R=307,L]

Now there is a maintenance message in the root of your website. maintenance.html create file.

What is WordPress Maintenance Mode?

WordPress maintenance mode is a state you apply to inform your visitors about maintenance on your site. It is a page or a message that replaces your main website. On this page you can add an estimate of when your website will be available.

WordPress in this process wp_maintenance It will use the (ing) function and create a .maintenance file containing the maintenance message. WordPress will delete this file when the maintenance process is complete. Your website should be back to normal.

When to Use WordPress Maintenance Mode?

wp maintenance mode
wp maintenance mode

First, you don't need to activate your maintenance mode every time you make a change. Like updating your content, fixing minor bugs or changing theme colors.

#Related Content: WordPress Site Speed ​​Up Techniques (10 Effective Methods)

However, as your site grows, it can also grow with changes and take longer. Changing your theme, adding new features or installing new services on your site may require downtime. This will prevent visitors from accessing your site.

What Are the Side Effects of Website Maintenance for Your Visitors?

By default WordPress creates a landing page that informs your visitors about maintenance. However, this “We are not available as there will be scheduled maintenance for a short time. Try again in a few minutes.” It is a plain white page with text.

#You may be interested in: WordPress Site Setup (2 Step WordPress Installation)

This landing page creates an absolutely unpleasant user experience for your visitors. Your business can give potential customers a bad impression. Visitors don't care much about what's going on behind the scenes. That's why it's a good idea to change the default WordPress maintenance mode page. If you want to do it the right way, keep reading.

Why Do You Need to Activate WordPress Maintenance Mode?

In this section, we will show you how to create a more compelling WordPress maintenance mode page. For example, you will learn to show the estimated time your site is unreachable, add alternative links or even a chatbot that serves your visitors. Finally, you will learn how to redirect your visitors to another website during maintenance.

How to Turn Off WordPress Maintenance Mode?

While WordPress is updating itself or updating a plugin, it briefly enters maintenance mode while updating files. Sometimes things go wrong and you can get stuck in maintenance mode. Sometimes switching to another page during the update, or sometimes a problem with the updated item itself may cause your site to not be able to exit maintenance mode.

In such a case, in order to take your site out of maintenance mode, you can use the root directory of your site. . Maintenance Just delete the file. Your site will exit maintenance mode. You can continue your work from where you left off.

Conclusion

There are many ways to put WordPress into maintenance mode. The first method is to use the WP maintenance mode plugin. This WordPress plugin will help you create a beautiful landing page. This method is recommended for those who are not very familiar with coding. The second method requires adding a php code snippet to your functions.php file. The last method you can try is adding code to your .htaccess file.

I hope I was able to teach you the WordPress maintenance mode in this article. But what method did you use to put your WordPress site into maintenance mode? Share it with me in the comments section below!

International
You may also like these
Show Comments (1)