Create a Maintenance Page in WordPress

Sometimes when you are doing updating or scheduled maintenance for your WordPress blog, i suggest you to make it temporary down while you are updating or maintenance. Temporary down in short time won’t cause any harm to your website, your visitors will understand and could comeback later. As well as crawl bot from search engines, when it see the HTTP Error 503 (Service unavailable), it will comeback again to index your website.

How to create a maintenance page:

Make a design for your maintenance page. SmashingMagazine compiled some good and inspirative maintenance page. Or see mine here.

Create maintenance.php page and put this code in header or top of the script:

The above method is manually make the maintenance page and use .htaccess to do it. That method apply for any website not just for WordPress system. For WordPress you can do it in 2 ways:

Use the .maintenance and maintenance.php file

Create a maintenance.php (see the instruction above) and put it under wp-content/ folder

Create .maintenance file and fill like this:

<?php $upgrading = ' . time() + (60 * 60) . '; ?>

Note: that script means always add 1 hour, so it would be endless.

Now you are done.

When you finish updating or maintenance just delete or rename .maintenance file so it would back to normal.

WP Maintenance Mode Plugin
The first 2 method need a little bit programming skill. If you don’t have that kind of skill then you can choose this last method. You can use WP Maintenance Mode plugin, it available free in WordPress plugins repository. WP maintenance mode plugin adds a maintenance-page to your blog that lets visitors know your blog is down for maintenance time. You can visit the plugin page for more details and download link: WP Maintenance Mode.

From all the method i like the manual method using the .htaccess, because it is more general and i can use it in different CMS not just WordPress. And it give me more power to do customization. But you may have different opinion, feel free to use the comment box below to share your thought. Thanks and have a nice day.