Introduction
This guide explains how to set up a maintenance page on your WordPress site using the Restricted Site Access plugin. This will allow you to restrict public access to your site while you’re making major changes, such as moving your site to a new server.
Using a WordPress plugin for a maintenance page will not work if WordPress is unavailable during the maintenance (e.g. you’re changing the WordPress database). If you need a maintenance page which works while WordPress is unavailable, you should investigate the options available from your hosting service.
There are lots of WordPress plugins for displaying a maintenance page. Restricted Site Access works well, and also allows IP restriction which can be useful for remote testing during maintenance (e.g. crawling the site for broken links).
Requirements
A WordPress admin account.
For reference, these instructions were followed using:
- WordPress version 5.4.2.
- Restricted Site Access plugin version 7.2.0.
Skill Level
Basic knowledge of WordPress.
Instructions
Time needed: 5 minutes.
- Log into WordPress Admin.
- Install the Restricted Site Access plugin.
If you haven’t already, install the Restricted Site Access plugin. For instructions on installing plugins, see How to install a plugin in WordPress.
- Go to the Reading Settings page.
In the main menu go to Settings > Reading.
- Enable the site restriction.
In the Site Visibility section select Restrict site access to visitors who are logged in or allowed by IP address.
In the Handle restricted visitors section, select the relevant option. The simplest option is Show them a simple message.
If Show them a simple message is selected, enter the message in the Restricted message field.
If relevant, enter an IP or IP range in the Unrestricted IP addresses fields and click Add. This is only required if you want to provide access to people (or remote services) which aren’t logged into WordPress.
Click Save Changes. - Disable the site restriction after maintenance is completed.
When maintenance is completed, disable the site restriction.
In the Site Visibility section select Allow search engines to index this site.
Click Save Changes.
More Info
WordPress Restricted Site Access plugin page: https://en-gb.wordpress.org/plugins/restricted-site-access/