• Home
  • Archive
  • Tools
  • Contact Us

The Customize Windows

Technology Journal

  • Cloud Computing
  • Computer
  • Digital Photography
  • Windows 7
  • Archive
  • Cloud Computing
  • Virtualization
  • Computer and Internet
  • Digital Photography
  • Android
  • Sysadmin
  • Electronics
  • Big Data
  • Virtualization
  • Downloads
  • Web Development
  • Apple
  • Android
Advertisement
You are here: Home » How to create a custom maintenance page for WordPress

By Abhishek Ghosh April 16, 2011 2:20 pm Updated on October 17, 2014

How to create a custom maintenance page for WordPress

Advertisement

When you update your WordPress blog platform, or when you fix bugs on your WordPress theme , your blog becomes, or shall be inaccessible for some time. You obviously noted that WordPress shows “maintenancehtaccess mode activated” in the panel.

Worse if you perform a cleanup, it will take an hour or more.

Instead of losing visitors from search engine during this few seconds to minutes, you might want to redirect visitors to a page explaining that the blog website is undergoing maintenance and that would be accessible again soon.

Advertisement

---

It is true that there are Maintenance Mode plugin for WordPress that allows you to easily create a page where maintenance will be automatically directed to readers. This plugin works great, you can customize the maintenance message, announcing the return of the blog in X minutes, etc. except for major upgrade of WordPress when you have to disable all plugins to avoid major problems. We had to find another way to implement this maintenance page. After some research and unsuccessful attempts, we finally found a solution that works very well based on .htaccess with special maintenance page and a news page that announces maintenance.
 

The maintenance page

 

This page will be displayed on the browser that the visitor arriving at your blog for maintenance:
 

<?phpob_start();header('HTTP/1.1 503 Service Temporarily Unavailable');header('Status: 503 Service Temporarily Unavailable');header('Retry-After: 3600');header('X-Powered-By:');?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xml:lang="en" lang="en" xmlns="http://www.w3.org/1999/xhtml"><html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Blog is under maintenance</title><meta name="robots" content="none" /></head><body><!-- Your custom message --></body></html>

 
It uses the HTTP code 503 which means that the server is currently unavailable due to overloading or maintenance. Moreover, the code 503 is accompanied by another message indicating the robots not to index this page (content = “none”).
Just drop this file now “503.php” in the root of your web server.
 

.Htaccess special maintenance

 
This file is not to replace your present .htaccess, this is for special maintenance that will be activated at the time of maintenance. Name this file  as 503.htaccess, when you want to activate your maintenance, simply rename the existing .Htaccess to temporay.htaccess and 503.htaccess to .htaccess. More clearly: it activates one or the other of two files by renaming them.

Options +FollowSymLinksRewriteEngine OnRewriteBase /RewriteCond %{REMOTE_ADDR} !^ 123 \. 123 \. 123 \. 123RewriteCond %{REQUEST_URI} !^/503.php [NC]RewriteRule .* /503.php [L]

The 4th line should be modified according to your IP address for your blog is still accessible to you and only during maintenance.

And now, with these two small files you can update your blog quietly while preventing your readers that your blog will be back online after maintenance. This way you will avoid to submit a blog all broken and not working during this time.
Signature

Tagged With create wordpress maintenance page using custom html , customize maintenance wordpress , php create maintenance page , wordpress customize maintenance page , wordpress maintenance , wordpress maintenance page , wordpress maintenance page language:en

This Article Has Been Shared 251 Times!

Facebook Twitter Pinterest

Abhishek Ghosh

About Abhishek Ghosh

Abhishek Ghosh is a Businessman, Surgeon, Author and Blogger. You can keep touch with him on Twitter - @AbhishekCTRL.

Here’s what we’ve got for you which might like :

Articles Related to How to create a custom maintenance page for WordPress

  • 9 types of articles to write in your blog

    When one writes a blog on a regular basis, one of the main challenges is to produce relevant content, unique and interesting to the readers, all this on a regular basis. Here are some ideas about what to write on.

  • 22 best blogging tips for beginners

    Here are the most important tips for budding bloggers covering writing plan, making money to search engine optimization.

  • WordPress hosting options : What must to look for

    WordPress hosting options are wide and varied. It becomes difficult to choose the best budget hosting company’s server to host your WordPress blog

  • Personal Life and your Professional Blog : How to Handle

    Personal Life and your Professional Blog might try to conflict at some point of time in a bloggers life. How to handle the situation?

  • Schema.org for WordPress : Advanced Tips for Genesis 2.0

    Schema.org for WordPress is nicely integrated by Genesis 2.0 but in terms of semantic complexity, it requires some advanced hand made tweaking.

Additionally, performing a search on this website can help you. Also, we have YouTube Videos.

Take The Conversation Further ...

We'd love to know your thoughts on this article.
Meet the Author over on Twitter to join the conversation right now!

If you want to Advertise on our Article or want a Sponsored Article, you are invited to Contact us.

Contact Us

Comments

  1. AvatarMax says

    January 18, 2012 at 4:59 pm

    Good idea. In this case, we simply took the site down for a few hours so a 503 probably wasn?t necessary. Great suggestion for longer cases though.

Subscribe To Our Free Newsletter

Get new posts by email:

Please Confirm the Subscription When Approval Email Will Arrive in Your Email Inbox as Second Step.

Search this website…

 

Popular Articles

Our Homepage is best place to find popular articles!

Here Are Some Good to Read Articles :

  • Cloud Computing Service Models
  • What is Cloud Computing?
  • Cloud Computing and Social Networks in Mobile Space
  • ARM Processor Architecture
  • What Camera Mode to Choose
  • Indispensable MySQL queries for custom fields in WordPress
  • Windows 7 Speech Recognition Scripting Related Tutorials

Social Networks

  • Pinterest (24.3K Followers)
  • Twitter (5.8k Followers)
  • Facebook (5.7k Followers)
  • LinkedIn (3.7k Followers)
  • YouTube (1.3k Followers)
  • GitHub (Repository)
  • GitHub (Gists)
Looking to publish sponsored article on our website?

Contact us

Recent Posts

  • The Importance of Voice and Style in Essay Writing April 1, 2023
  • What Online Casinos Have No Deposit Bonus in Australia March 30, 2023
  • Four Foolproof Tips To Never Run Out Of Blog Ideas For Your Website March 28, 2023
  • The Interactive Entertainment Serving as a Tech Proving Ground March 28, 2023
  • Is it Good to Run Apache Web server and MySQL Database on Separate Cloud Servers? March 27, 2023

About This Article

Cite this article as: Abhishek Ghosh, "How to create a custom maintenance page for WordPress," in The Customize Windows, April 16, 2011, April 2, 2023, https://thecustomizewindows.com/2011/04/how-to-create-a-custom-maintenance-page-for-wordpress/.

Source:The Customize Windows, JiMA.in

PC users can consult Corrine Chorney for Security.

Want to know more about us? Read Notability and Mentions & Our Setup.

Copyright © 2023 - The Customize Windows | dESIGNed by The Customize Windows

Copyright  · Privacy Policy  · Advertising Policy  · Terms of Service  · Refund Policy

We use cookies on our website to give you the most relevant experience by remembering your preferences and repeat visits. By clicking “Accept”, you consent to the use of ALL the cookies.
Do not sell my personal information.
Cookie SettingsAccept
Manage consent

Privacy Overview

This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience.
Necessary
Always Enabled
Necessary cookies are absolutely essential for the website to function properly. These cookies ensure basic functionalities and security features of the website, anonymously.
CookieDurationDescription
cookielawinfo-checkbox-analytics11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Analytics".
cookielawinfo-checkbox-functional11 monthsThe cookie is set by GDPR cookie consent to record the user consent for the cookies in the category "Functional".
cookielawinfo-checkbox-necessary11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookies is used to store the user consent for the cookies in the category "Necessary".
cookielawinfo-checkbox-others11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Other.
cookielawinfo-checkbox-performance11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Performance".
viewed_cookie_policy11 monthsThe cookie is set by the GDPR Cookie Consent plugin and is used to store whether or not user has consented to the use of cookies. It does not store any personal data.
Functional
Functional cookies help to perform certain functionalities like sharing the content of the website on social media platforms, collect feedbacks, and other third-party features.
Performance
Performance cookies are used to understand and analyze the key performance indexes of the website which helps in delivering a better user experience for the visitors.
Analytics
Analytical cookies are used to understand how visitors interact with the website. These cookies help provide information on metrics the number of visitors, bounce rate, traffic source, etc.
Advertisement
Advertisement cookies are used to provide visitors with relevant ads and marketing campaigns. These cookies track visitors across websites and collect information to provide customized ads.
Others
Other uncategorized cookies are those that are being analyzed and have not been classified into a category as yet.
SAVE & ACCEPT