Sorry, You Are Not Allowed to Access This Page

Have you got this error when you’ve tried to login to your WordPress admin panel with an account you know should have admin access?

There’s a few things you can try to get this error fixed, so you can get back on track.

Plugins

If you’ve recently installed a plugin which may have caused this message to appear, you can try the following steps:

  1. Login to your website hosting control panel, FTP or SSH.
  2. Navigate to the /wp-content/plugins directory.
  3. Delete or rename the offending plugin.
  4. Attempt to access the WordPress admin page.
  5. If that fails, try again using an incognito or private browser window.

Usermeta Permissions

If you’ve migrated your site, changed your WordPress configuration, or added a user manually, you may have your permissions set incorrectly:

  1. Connect to your WordPress database via phpMyAdmin or your database client.
  2. Check whether your WordPress tables are prefixed with wp_ or another custom prefix, e.g. mysite_.
  3. Navigate to the users table (either wp_users or your custom prefix e.g. mysite_users) and verify your user exists. Note down your numeric ID.
  4. Navigate to the usermeta table (either wp_usermeta, or your custom prefix e.g. mysite_usermeta)
  5. In the usermeta table, search for rows where the user_id column matches your numeric ID from the users table.
  6. For your numeric user ID, check the capabilities and user_level are set correctly.
    1. For Administrator users, the capabilities meta_value column should be a:1:{s:13:"administrator";b:1;}.
    2. For Administrator users, the user_level meta_value column should be 10.
    3. Update the usermeta fields if they don’t match the values above.
  7. Verify the prefix for the capabilities and user_level start with the default wp_ prefix, or your custom prefix if one exists e.g. mysite_.
  8. Attempt to access the WordPress admin page.
  9. If that fails, try again using an incognito or private browser window.