.htaccess “Down For Maintenance” Page Redirect

When you want to work some changes on your live websites, you want to put “Maintenance window” very often. This is to prevent user seeing a broken page while updating a massive update in site. So your website users should get a minimum message that says you are working on something. In this tutorial, you are learning to show maintenance page using .htaccess by using the below script

So all the requests to your website go to maintenance page as your setup. But one problem all the requests are going to the special page.  So your team want to watch the website while updating. There is a solution for that, you can bypass one or many IPs from this setup using the below script

The above code sends all users to maintenance.html EXCEPT those with the specified IP

Editorial Staff

Editorial Staff at tutsplanet is a dedicated team to write various tutorial articles.