tutorials

How to Fix the “Sorry, You Are Not Allowed to Access This Page” Error (8 Easy Fixes)

Share

The WordPress warning “Sorry, You Are Not Allowed to Access This Page” is a helpful measure of security. However, just like the other WordPress errors, including the WordPress HTTP Error, and WordPress Memory Error, it is also highly annoying and hinders the entire website flow.

This is also a major issue if you are locked away from a section of your site that you should be able to enter which is anywhere on the backend as an administrator. If this circumstance occurs, a recent upgrade to a theme, plugin, or WordPress core generally follows.

For a variety of reasons, you can get the warning “Sorry, You Are Not Allowed to Access This Page,” like you may not be recognized as an administrator by WordPress. In other cases, the information in the core code or theme or plug-in of your website might not match what’s in your database.

Another problem is the erroneous information in the wp-config.php file or a website with an obsolete PHP version. Regardless of the source, this error could prevent you from accessing the whole or just part of the admin section.

Since you may be unable to access important settings via the dashboard, the issue must be resolved by using File Transfer Protocol (FTP) or phpMyAdmin. Before you enter the problem-solving procedure, make sure that you backup your site and brush up on these platforms.

The frustrating part about meeting the “Sorry, You Are Not Allowed to Access This Page” message is that it can be difficult to determine which of its causes are involved. Luckily, you may test various solutions to uncover the cause of the problem.

Fixing the “Sorry, You Are Not Allowed to Access This Page” WordPress error

The “Sorry, You Are Not Allowed to Access This Page” problem takes quite some patience to address due to its many possible causes. This extensive list of options will surely help you fix the error and have a happy browsing time.

Fix 1: Restoring the site’s previous version.

The easiest and fastest way to reinstate WordPress is to restore an older version of your website. The reason for the error you notice may be a recent change, such as an update. You should be able to access your site again by undoing your latest edit.

The disadvantage here is that you can lose your recent adjustments and find a means to achieve your aims without making the same mistake again. You may want to restore your backup to a place where you are staging. You can then test various changes to find out what caused the problem. You can retrieve the troubling change to retrieve the access to your site when you have detected the root of the issue.

Fix 2: Disabling all the Plugins.

The recent addition or update of a plugin is a specific alteration that can cause the notice “Do not access this page.”

You should disable your plugins one by one if you feel that is the case.

If a plugin is deactivated and the notice disappears, the origin of the problem is located. This plugin can then solve the problem.

Of course, this approach is somewhat tough if you are locked out fully from your dashboard.

Step 1: You will need to access your website utilizing SFTP.

Step 2: After doing so, browse to wp-content and find the labeling plugins in the subdirectory.

Step 3: Enter this folder and then rename your latest additional plugin to “plugin-name-old.” Go back to your website and see if the mistake is fixed. If not, replace the name of the plugin with the next one.

Fix 3: Activating any default theme.

Another likely reason for this problem is the recent upgrade or installation of a theme. Your best bet to resolve this problem is to set a theme like Twenty Twenty or Twenty Nineteen for default WordPress.

Step 1: You will have to use FTP again to do so without access to your admin area. Navigate to wp-content > themes.

Step 2: For disabling your themes, the rest of the process is quite identical to that explained before in plugins.

Step 3: Rename your active theme folder and then login back to your site. You should see a notice that the active theme is broken and a default theme reinstated.

Then you can fix the error.

Fix 4: Ensure that you are an Administrator.

You may also modify your user role unintentionally and no longer be included as an administrator. This is a typical issue with multi-site systems.

Step 1: You need to access phpMyAdmin and see the wp_users table, to determine whether this is the case.

Step 2: Search your ID for your username. Navigate to the table wp_usermeta and find the row wp_capabilities. The meta value in this row will read if you have administrative privileges.

a:1:{s:13: “administrator”; s:1: “1”;}

If something else is being said in your wp_usermeta database, you can click and modify the edit link. Also, you can establish a whole new phpMyAdmin Administrator account.

Step a: To take this route, go back to the table for wp_users and click on the top of the table tab Insert.

Step b: Then, add your new user information to the fields. Once the user is finished, click the Go button and the table should show your new user.

Step c: Next, you will need to take a note and head back to the wp_usermeta database to make your account identification.

Step d: Click Insert again, provide the following information in the resulting fields:

  • Unmeta id: leave this box blank; it is automatically filled in for you.
  • User id: Use WP Users table identification.
  • Meta key: Set this value to “wp capabilities.”
  • Meta value: Add the above line.

Now you need to be able to log in to your WordPress admin area using your new credentials. Remove your old account or modify your user role from the dashboard back to Administrator and delete it instead.

Fix 5: Ensuring that the Database prefix is right.

There is a prefix in each MySQL database. If you see the error “Sorry, You Are Not Allowed to Access This Page,” it might be due to the difference in the database prefix at the wordpress site and the one shown in phpMyAdmin on your website.

This can be the case when your website is migrated, even if you have used a local development site and are now transferring to a live server. You will have to visit your wp-config.php file to check for differences.

Step 1: As stated in earlier solutions, you can do that via SFTP. You should look for your database prefix (default is “wp_”) while you are in your wp-config.php file.

Step 2: Then login and see the tables for your database prefixes in phpMyAdmin. It should match those in your wp-config.php file.

You’ll need to change it to do so if it does not match the prefix in your wp-config.php file.

Fix 6: Looking for the changes in the wp-config.php file.

Similarly, you should also look for modifications to your configuration file for WordPress. This is especially true if you edited the file soon before the ‘Sorry, You can’t access this page’ notice was sent, or if you suspect that you hacked your WordPress site.

You can use SFTP to access your wp-config.php file and look for anything you don’t feel like. However, if a file integrity monitoring or change detection mechanism is in place, this process is far easier.

Fix 7: Evaluating all the File permissions.

You can also have file permissions from your site manipulated. In this instance, even though you’re listed as an administrator, WordPress may think you are not allowed to visit some portions of your website.

Step 1: You will need to utilize SFTP to access your server to check your site file permissions.

Step 2: Once logged into, enter the wp-admin, wp-content, and wp-comprises public_html directory. Click right on these folders and select File Allowances:

Make sure the choices are selected in the resulting window:

  • The value is 755 Numeric Value.
  • Check for resources in subdirectories.
  • Select only the application for directories.

Step 3: If you’re finished, click OK. Then highlight, right-click and choose File Permissions again: all the other files in public_html. This time, set the following parameters in the permission window:

  • The number value is expected to be 644.
  • Recurse should still be verified for subdirectories.
  • Only choose applications for files.

Step 4: Then go back to your site to find out if this solves the problem and the message “Don’t get this page access” is gone.

Fix 8: Resetting the WordPress site.

There may be an installation problem in the worst-case scenario. You must reset your WordPress site to solve it. It is important that when this process has been completed you have an updated backup that will make you lose all postings, pages, and comments. You must reset your site or start a new one.

Conclusion

These were the top eight and most effective techniques to fix the “Sorry, You Are Not Allowed to Access This Page” error. If you go through each of them in the right sequence and have patience above all, then you will easily be able to resolve the error and fix it for a longer period.

Chris Wagner

I am Chris Wagner, Having 12+ years of experience in the Hosting industry.

Published by
Chris Wagner

Recent Posts

9 Best Student Hosting for 2025

Hello, Gen Z! Ready to fly high with your dreams? Let no one stop you…

6 months ago

5 Best HideMyAss Alternatives (#3 is Just Awesome)

Let's talk about HideMyAss Alternatives! But first, let us talk about HideMyAss. If you’re interested…

6 months ago

Kadence WP Review (2025)

These days the theme market is flooded and users are spoiled by choices. But if…

6 months ago

10 Best Tested Video Hosting Sites

Thinking of starting a video log or want to host your video on a video…

6 months ago

9 Best Ecommerce Hosting Providers in 2025

So, you‘re looking for the best ecommerce hosting company for your needs? No matter whether…

6 months ago

Turnkey Internet Review: My Honest Opinion + Pros & Cons

Why Trust Us "We have been a paying customer for Turnkey Internet since March 2019.…

6 months ago