I am building up a website for C Programming Tutorial www.programminginc.net . Now I am using a plugin to show my site under construction. What is the code used to create a website under construction setup?

  • If either of these answers worked for you, please take a moment to check it as accepted so the question can be closed and helpful to others. Dec 15 '13 at 5:13

The quick and dirty way to do it is to create a file named .maintenance at the root of the site-- same directory as license.txt-- and add a bit of PHP:



Of course, you can create whatever markup and messages you'd like before the die();, but there is very little WordPress available since it fires very early in the wp-settings.php file.

If you want to see how to add and remove the file automatically, look at how the core does it.


Here are two options:

  1. Create a static HTML "Coming Soon" page and redirect outside requests to your domain to that page. This will let you continue to work on your site (hopefully you're developing locally and pushing changes to your live site) without your visitors loading up the WordPress side.

  2. Create a basic WordPress theme with your "Coming Soon" page as index.php and set the theme as default. You can use a plugin like Theme Test Drive to test out the one you're developing while your visitors see the "Coming Soon" theme.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.