How to: enable WordPress maintenance mode

0 Flares Facebook 0 Pin It Share 0 Google+ 0 0 Flares ×

In this tip we will learn How to enable WordPress maintenance mode. Sometimes it happens where we want to test something new on our blog but because of live site we skip that change. But as this post suggest we can enable wordpress maintenance mode to make those changes.

There are two methods available to achieve this functionality.

1. Advance user

This option available for those users who want to merely put their website in maintenance mode instead of frequently. you can follow below steps to activate maintenance mode.

  1. Login to your wordpress dashboard.
  2. Navigate to Appearance Menu Appearance->Editor.
  3. Open your current theme Function.php
  4. Put below code at the bottom of the file.

    function wpr_maintenance_mode() {
    if ( !current_user_can( ‘edit_themes’ ) || !is_user_logged_in() ) {
    wp_die(‘Maintenance, please come back soon.’);
    add_action(‘get_header’, ‘wpr_maintenance_mode’);

  5. Put below code at the bottom of the file.
  6. You can also change text message by replacing ‘Maintenance, please come back soon‘ with your custom text.
  7. Save the file.

2. Maintenance mode plugin

You can also enable wordpress maintenance mode using this useful plugin. as you can see from below screenshot it has activate option for a time interval. you can set your maintenance time from day to minutes which is quite good. you can also specify your custom message.


meantime you can also redirect user to your facebook and twitter page by using above html custom message section.

After activating the maintenance mode you will see screen like this.

Wordpress maintenance mode

I think that now you have learned how to enable WordPress maintenance mode when you will start working next time with your blog.

Happy Blogging!!

Posted in: Wordpress Tips
0 Flares Facebook 0 Pin It Share 0 Google+ 0 0 Flares ×