Do you want your WordPress site to be in a read only mode?
By freezing your site’s content, you can make sure that no one changes anything on your website, even if they normally have edit access. This can help you avoid errors, conflicts, and confusion when you’re making changes to your website.
So, we will show you how you can put your WordPress site in a read only mode for site migrations and maintenance.
Why Put Your WordPress Site in a Read Only State for Site Migrations and Maintenance
You can tweak a lot of settings on your WordPress website without stopping visitors from accessing the site. However, when you’re making a big change to your website, it’s a good idea to put your site into a read only state.
So, if you’re moving WordPress to a new host or server, upgrading to a new version of WordPress, or installing a new theme, then it can affect the user experience and stop your site from working normally.
Setting up read only mode can help you avoid losing any data or content that’s added to your site while you’re making the change. You also prevent frustration from a poor user experience when features don’t work right.
Also, if someone is writing a new post in the WordPress dashboard while you’re migrating to a new server, then all of their hard work may be lost. Or perhaps a user can’t add products to their cart or checkout, so they leave your site.
So, let’s take a look at the best way to put your WordPress site in read-only mode to prevent those issues.
How to Put Your WordPress Site in a Read Only State for Site Migrations and Maintenance
There are a few dedicated content freeze or read-only mode plugins available, but they are all currently outdated and not actively maintained by their developers.
That’s why we recommend using the Lock User Account plugin instead.
This is perfect for membership sites, online stores, or any other type of site that allows user registration.
This plugin lets you temporarily lock any user out of their WordPress account. Anyone who is locked out of their account won’t be able to edit the site’s content or add any new content, although visitors will still be able to see the website.
If a user tries to log into a locked account, then they’ll see a message simply stating ‘Your account has been locked.’ You can customize this message to give your users more information.
Now, using this plugin doesn’t actually freeze your site or prevent database changes. That’s why we also recommend temporarily disabling your comments and any contact forms on your site as well. We’ll show you how to do that below.
Before starting the content freeze, you can change the message that users will see if they try to log into a locked account. For example, you might want to explain that you’re changing your domain name or doing essential maintenance.
To change the default ‘Your account has been locked’ error message, simply head over to Settings » General.
Towards the bottom of the screen, you’ll see a new ‘Lock User Account’ section.
You can now simply type a new message into the ‘Locked User Message’ field. Once you’re happy with the message, just click on the ‘Save Changes’ button.
After that, you’re ready to put your site into read-only mode.
To go ahead and start locking users out of their account, head over to Users » All Users.
On this screen, you’ll see all the people who have an account on the site.
The ‘Locked’ column shows whether each user currently has access to their account (unlocked) or not (locked).
To go ahead and temporarily lock a user out of their account, just click to check the box next to their profile picture.
If you want to lock multiple people out of their accounts, then click to select multiple boxes.
After selecting one or more usernames, click on the ‘Bulk actions’ dropdown and then select ‘Lock.’
When you’re ready to go ahead and lock these people out of their accounts, click on the ‘Apply’ button.
Now, the site is essentially in read only mode for your users, and if anyone with a locked account who tries to log in will get an error message.
Once you’ve finished your work, you can unlock the user accounts. Simply go back to Users » All Users and repeat the process above. Only this time, be sure to select ‘Unlock’ from the ‘Bulk Actions’ dropdown.
After that, you can click the ‘Apply’ button to reactivate these accounts.
How to Temporarily Disable Comments and Form Entries
Before you start your site migration or other big changes, you’ll also want to temporarily disable comments and form entries on your site. If someone submits a comment or form in the middle of your changes, that data would be lost.
To temporarily disable comments quickly and easily on your whole site, we recommend using WPCode.
Simply install and activate the free WPCode snippets plugin and then navigate to Code Snippets » Add Snippet.
From here, you can click on the Comments category in the left menu and then click on ‘Use snippet’ under ‘Completely Disable Comments’.
You may also want to see our ultimate WordPress SEO guide for beginners to bring more visitors to your website. If you have any issue on this, you can use our comment session or join our delegate on Facebook to solve any issues related to WordPress and subscribe to our YouTube Channel for WordPress video tutorials.