There are few situations more alarming than existence locked out of your own WordPress admin dashboard. If you've encountered a message reading "Sorry, yous are not allowed to access this page" when trying to log in, you know the feeling first manus.

Fortunately, there are several solutions at your disposal for troubleshooting this error. With a fiddling patience, you can clear upwards the mistake and get back to managing your WordPress site in no time.

In this mail service, nosotros'll dig into the "Sorry, you are not immune to access this folio" fault and what causes it to occur. And so we'll walk you through the many potential solutions to help y'all notice the one that addresses your specific state of affairs.

Let'south jump right in!

Agreement the "Lamentable, You Are Not Allowed to Admission This Page" Error

Although we're referring to it every bit an "error" for the purposes of this postal service, the "Distressing, you are non allowed to access this page" message in WordPress is meant to be a helpful security measure.

Ultimately, seeing this notification simply means there'due south a permissions setting that's blocking you from a certain area.

This becomes a problem when you're locked out of a role of your site that yous should have permission to enter which, every bit an Ambassador, is anywhere on the backend. When this situation arises, information technology is often following a contempo update to a theme, plugin, or WordPress core.

You may come across the "Sorry, you are not immune to access this folio" message for a variety of reasons. Information technology might be that WordPress doesn't recognize you as an Ambassador. In other situations, the data independent in your site's core code or in a theme or plugin may not match what's in your database.

Boosted causes include incorrect information in your wp-config.php file or a site that's running an outdated version of PHP. Whatever the source, this error may foreclose you from accessing the unabridged admin area or just a portion of information technology.

Since it's likely that you will non be able to access fundamental settings via the dashboard, you'll need to apply File Transfer Protocol (FTP) or phpMyAdmin to resolve this upshot. Make sure to back up your site and brush up on using these platforms before y'all dive into the troubleshooting process.

The nearly frustrating thing almost encountering the "Sorry, you lot are not allowed to access this page" notification is that it tin can be hard to pin down which of its causes are at play. Fortunately, there are many solutions y'all tin can test out to discover the root of the problem.

How to Fix the "Distressing, You Are Non Allowed to Access This Page" Error in WordPress (11 Potential Solutions)

Due to its many possible causes, the "Sorry, you lot are not allowed to access this folio" fault takes quite a bit of patience to resolve. This long listing of solutions may be intimidating but it too covers a variety of situations to aid you notice the correct one for your site.

i. Restore a Previous Version of Your Site

The simplest and often the fastest way to get back into your WordPress dashboard is to restore your site to an earlier version. A contempo change, such equally an update, might exist the cause of the error you lot're seeing. Undoing your latest modification should enable you to admission your site again.

Kinsta clients have it like shooting fish in a barrel in this regard. Y'all can restore a WordPress backup in your hosting account with a single click:

Restoring a backup in MyKinsta
Restoring a fill-in in MyKinsta

The drawback to this solution is that yous may lose your recent changes and will take to find a mode to attain your goals without causing the same fault once again.

For this reason, you may want to restore your backup to a staging site instead. Yous tin can and so test different modifications to determine what caused the problem. Afterwards uncovering the root of the result, you can disengage the troublesome alter to regain access to your site.

2. Disable All of Your Plugins

A specific alter that may be causing the "Sorry, you are not allowed to access this folio" message on your site is the recent addition or upgrade of a plugin. If you suspect that this is the case, your all-time course of action is to disable your plugins one by one.

In the effect that you disable a plugin and the message goes away, you've found the source of the problem. You can then troubleshoot the issue with that plugin (or practise without it, if it'due south not crucial to your site'south functionality).

Of course, if you're locked out of your dashboard entirely, this process gets a little tricky. You lot'll need to admission your site using SFTP via a customer such as FileZilla. Once yous've done so, navigate to wp-content and find the sub-directory labeled plugins:

Disable all plugins by renaming the folder
Disable all plugins by renaming the folder

Enter this folder, and and so rename your virtually recently-added plugin to something like "plugin-name_old". Get dorsum to your site and check to meet if the error is resolved. If not, change the plugin's proper name back and repeat the process with the side by side one.

iii. Activate a Default Theme

However another potential cause of this error is that you lot've recently updated or installed a theme. Your best bet for resolving this problem is to activate a default WordPress theme such equally Xx Twenty or 20 Nineteen.

To practice and then without access to your admin area, yous'll need to utilize FTP again. Connect to your server with FileZilla and then navigate to wp-content > themes:

Disable your current theme by renaming the folder
Disable your current theme past renaming the binder

The rest of the process is fairly similar to the one described above for disabling your plugins.

Rename the folder for your active theme, and then return to your site and log in. You should see a notification telling you that the active theme is broken, and a default theme has been reactivated.

Then you can troubleshoot the theme. Your site should at least be accessible, albeit with the wrong theme activated.

4. Make Certain You're an Ambassador

Some other possibility is that your user role has been inadvertently changed and you are no longer listed as an Administrator. This is a common problem with multisite installations. To determine if this is the case, y'all'll demand to access phpMyAdmin and look for the wp_users table:

The WP users table
The wp_users table in phpMyAdmin

Discover your username and note your ID. And so, navigate to the wp_usermeta table and discover the wp_capabilties row:

The wp_usermeta table in phpMyAdmin
The wp_usermeta table in phpMyAdmin

If you lot have Administrator privileges, the meta_value in this row will read:

a:1:{south:thirteen:"ambassador";s:i:"1";}

If your wp_usermeta table says something else, you can click on the Edit link and change it. Alternatively, you can likewise create an entirely new Administrator account from phpMyAdmin. To take this road, return to the wp_users table and click on the Insert tab at the height of the tabular array:

Change user information in wp_users table
Change user data in wp_users table

Then, fill up in the fields with your new user information. Once you're done, click on the Go button and your new user should announced in the table. Side by side, you'll need to brand a annotation of the ID for this account and head dorsum to the wp_usermeta table.

Click on Insert once more, and fill in the resulting fields with the following data:

  • Unmeta_id: Leave this field blank; it will be filled in automatically for you.
  • User_id: Utilise the ID from the WP Users table.
  • Meta_key: Set this value as "wp_capabilities".
  • Meta_value: Add together the line mentioned above.

You should now be able to use your new credentials to log in to your WordPress admin surface area. Delete your old account or change its user office dorsum to Administrator from the dashboard and delete the new one instead.

Subscribe At present

5. Check Your Error Log to Pinpoint the Crusade

A smart fashion to streamline troubleshooting any problem on your site is to check your server's fault log. This may indicate plugin or theme compatibility issues, database errors, or problems with your site'southward files that are causing the "Sorry, you are not allowed to admission this folio" message to announced.

How yous view your server's mistake log volition vary depending on who your hosting provider is. For Kinsta customers, this process is as simple every bit logging into your MyKinsta dashboard. There, select the site that's experiencing problems and navigate to Logs:

MyKinsta logs tab
MyKinsta logs tab

Cull error.log from the drop-downward card. If you come across one of the causes of the alert in your log, then y'all can go about fixing it. Otherwise, you'll need to try another solution on this list.

six. Ensure That Your Database Prefix Is Correct

Every MySQL database has a prefix. If this one listed in your website'due south files doesn't match the one listed in phpMyAdmin, so you may see the "Lamentable, you are not allowed to access this page" message.

This can occur when migrating your site, including if you've used a local staging site for development and are now moving to a live server. To check for discrepancies, y'all'll need to access your wp-config.php file.

You tin do this via SFTP every bit we've described in previous solutions. Once you're in your wp-config.php file, you should look for your database's prefix (the default is "wp_"):

Database prefix
Database prefix

And then, log in to phpMyAdmin and look at the prefixes for your database'due south tables. They should match the ones listed in your wp-config.php file, like in the image below:

Prefixes should match those in your wp-config.php file
Prefixes should match those in your wp-config.php file

If they don't lucifer the prefix in your wp-config.php file, then you'll need to edit it and then that they do.

7. Await for Changes in Your wp-config.php File

On a similar note, you should also wait for whatsoever changes to your WordPress configuration file. This is peculiarly true if yous were editing this file shortly before yous received the "Sorry, yous are not allowed to admission this page" message or if you doubtable that your WordPress site has been hacked.

Yous can access your wp-config.php file using SFTP and look for anything that seems amiss. Still, this procedure is much easier if you accept some kind of file integrity monitoring or change detection feature in place.

8. Upgrade to the Latest Version of PHP

If your WordPress site is running an outdated version of PHP, this could be the source of your troubles. With that said, even if upgrading PHP doesn't solve this issue for yous, it should improve your site's overall security and performance.

Before y'all start the upgrade process, create a backup of your site. Yous tin can exercise this manually or from your MyKinsta dashboard, even if you're locked out of your admin area. Once yous've saved your backup, you'll want to test to meet whether your account is compatible with the latest version of PHP. One way to exercise this is with a WordPress staging site.

Assuming that all goes well, you can run the update. Kinsta customers can easily do and then by logging into the MyKinsta dashboard and navigating to the relevant site. And so go to Tools > PHP Engine > Modify, and select the newest version from the drop-down menu:

How to upgrade PHP version in MyKinsta
How to upgrade PHP version in MyKinsta

If you lot're with another provider, you may be able to follow a similar process via your own control panel. It's recommended that y'all contact your web host for more information.

9. Evaluate Your File Permissions

It's also possible that your site's file permissions have been tampered with. In this case, WordPress may consider y'all unauthorized to view sure areas of your site, even if yous're still listed as an Ambassador.

To check your site's file permissions, yous'll need to use SFTP to access your server. Once you lot're logged in, enter the public_html directory and bulk-select wp-admin, wp-content, and wp -includes. Correct-click on these folders and choose File Permissions:

Checking file permissions
Checking file permissions

In the resulting window, make sure the following options are selected:

  • The Numeric Value is set to 755.
  • Recurse into subdirectories is checked.
  • Use to directories simply is selected.

Click on OK when you're done. And then, highlight all the other files in public_html, right-click on them, and select File Permissions over again:

Setting new file permissions
Setting new file permissions

This time, fix the options in the permissions window to the following:

  • The Numeric Value should exist 644.
  • Recurse into subdirectories should nonetheless be checked.
  • Apply to files only should be selected.

Then, return to your site to see if this solves the problem and the "Distressing, you are not allowed to access this folio" message is gone.

10. Create a New .htaccess File

If none of the higher up strategies have worked, you may need to reset your .htaccess file. To practise so, launch FTP and navigate to your public_html folder. You should see your .htaccess file there, but if y'all don't, follow instructions for showing hidden files in FileZilla.

Next, you'll need to rename your existing .htaccess file, similar to how nosotros renamed plugin and theme files in earlier solutions. Something recognizable such as .htaccess_original or .htaccess_backup is platonic.

Then, right-click on the file and select Download. Open up the file in a text editor and supervene upon its contents with the following:

          #Begin WordPress  RewriteEngine On  RewriteBase /  RewriteRule ^index\.php$ - [Fifty]  RewriteCond %{REQUEST_FILENAME} !-f  RewriteCOnd %{REQUEST_FILENAME} !-d  RewriteRule . /index.php [Fifty]  #Finish WordPress        

Rename this file .htaccess and upload it to your server. If this file was the source of the "Sorry, you are not allowed to admission this page" error, and so it should now be fixed.

11. Reset Your WordPress Site

In the worst-case scenario, there may exist an installation issue. To ready information technology, you'll have to reset your WordPress site. It's vital that you take a recent backup y'all can restore after this process is complete, equally resetting your site volition crusade you to lose all posts, pages, and user comments.

In that location are several methods for doing this, including via your MyKinsta dashboard, using a WordPress plugin, and by using WP-CLI (the WordPress control line). Information technology's best to save this route as a last resort, so you don't take chances losing your site's content.

Are you lot getting the awfully alarming *Deplorable, You Are Not Allowed to Access This Page* message? Try ane of these methods to get your admission back! 🙅‍♂️🔑 Click to Tweet

Summary

Being locked out of your admin dashboard in WordPress is nervus-wracking, to say the least. Chop-chop finding the right solution to the "Pitiful, you are not allowed to access this page" error is vital to both your site and your peace of mind.

In this mail service, nosotros covered a wide range of possible causes and fixes for this issue. Allow'due south recap them speedily:

  1. Restore a previous version of your site.
  2. Disable all of your plugins.
  3. Actuate a default theme.
  4. Make sure yous're an administrator.
  5. Check your error log to pinpoint the cause.
  6. Ensure that your database prefix is correct.
  7. Await for changes in your wp-config.php file.
  8. Upgrade to the latest version of php.
  9. Evaluate your file permissions.
  10. Create a new .htaccess file.
  11. Reset your WordPress site.

Happy fixing!


Save time, costs and maximize site functioning with:

  • Instant help from WordPress hosting experts, 24/7.
  • Cloudflare Enterprise integration.
  • Global audience reach with 32 data centers worldwide.
  • Optimization with our congenital-in Application Performance Monitoring.

All of that and much more than, in 1 plan with no long-term contracts, assisted migrations, and a 30-day-money-back-guarantee. Check out our plans or talk to sales to find the plan that's right for you.