Discover in this tutorial how to put your WordPress website into maintenance mode by using a simple code snippet.
Do you have to make a quick change on the web but don’t feel like installing and uninstalling a “Coming soon” plugin or similar?
Sometimes you just need to make small changes that won’t take long. However, you also don’t want the website to be visible while you make them.
Here you will learn how to display the WordPress native maintainer page with a custom message while working on the web.
And all with a simple snippet of code:
Snippet to put WordPress into maintenance mode
Add the following fragment at the end of functions.php:
To see this and another 1097 code snippets of this website, login or subscribe here.
Just like that, see?
You can also modify the text to show the message you prefer.
And once you’re done with your changes, you can remove the code and you’re done.
Conclusion
As you can see, with a few lines of code you can get the site into maintenance mode with a custom message without the need to use third party plugins.
This trick is as simple as it is practical for WordPress designers and developers.
Personally, it comes in handy. I hope you find it useful, too.
Any questions? I read you in the comments.
And if you want to give me any suggestion for future tutorials, leave it in the contact form. Advantages of being a subscriber. 😉