Trusted WordPress tutorials, when you need them most.
Beginner’s Guide to WordPress
25 Million+
Websites using our plugins
Years of WordPress experience
WordPress tutorials
by experts

What to Do When You Are Locked Out of WordPress Admin (wp-admin)

Editorial Note: We earn a commission from partner links on WPBeginner. Commissions do not affect our editors' opinions or evaluations. Learn more about Editorial Process.

One of the most common issues that our readers have is being locked out of their WordPress admin areas.

This can be caused by a lot of different reasons, which makes it tricky for beginners to troubleshoot.

Fortunately, we have 16+ years of experience troubleshooting and fixing WordPress errors, so we are here to help.

In this article, we will show you what to do when you are locked out of WordPress admin (wp-admin) so that you can regain access to your site.

What To Do When You Are Locked Out of WordPress Admin (wp-admin)

Why Are You Locked Out of WordPress Admin?

We often hear from users who are locked out of WordPress admin area. This is frustrating and can bring your productivity to a standstill. You can’t write posts, respond to comments, or do any work on your WordPress website.

If you are having trouble logging in to someone else’s site, then you should contact the site owner or admin to let them know. They can explain why you don’t have access or work with you to solve the problem.

If you are the site owner, then you can follow our troubleshooting steps below.

There are a few reasons why you could be locked out of WordPress admin, so let’s take a look at each of them one by one. Hopefully, through this process of elimination, you will be able to figure out the solution to your problem.

You can also refer to our WordPress troubleshooting guide to find out what is causing the issue and how to fix it. You might also find a solution in our list of the most common WordPress errors and how to fix them.

Expert Tip: Would you prefer to leave the troubleshooting to the professionals? Our WordPress Premium Support Services can troubleshoot and fix your WordPress errors in no time. We offer on-demand, 24/7 emergency support and affordable, one-time solutions for small businesses.

With that being said, let’s have a look at some steps you can take when you are locked out of WordPress admin. You can use the links below to quickly navigate to the error message you see:

Error Establishing Database Connection

Error Establishing Database Connection

Are you seeing the ‘Error establishing database connection’ warning on every page of your site? This message is shown for various reasons, such as a corrupt database or issues with your web hosting server.

If you are seeing this error when trying to log in, then please refer to our guide on how to fix the error establishing a database connection in WordPress.

500 Internal Server Error

Internal Server Error

Another WordPress error that a beginner may come across is “Internal Server Error”, or sometimes “500 Internal Server Error”. This error is displayed when there is something wrong, but the server is unable to identify where the problem is.

If you see this message when trying to log in to WordPress, then follow the steps in our guide on how to fix the 500 internal server error in WordPress.

404 ‘Not Found’ Error

Sometimes, users make a mistake when changing the WordPress address and site address in their WordPress settings. The next time they try to log in to their admin area, they see the error ‘Error 404 – Not Found’.

WordPress Address and Site Address

If this is happening to you, then you can check our guide on how to change your WordPress site URLs. You won’t be able to use Method 1 because you can’t log in, but the other methods should get you out of trouble.

Note: If you can log in to your site but see the 404 error when viewing one of your posts, then you have a different problem. You can learn how to fix the issue in our guide on how to fix WordPress posts returning 404 error.

403 Forbidden Error

Forbidden Error

Some users report seeing the “HTTP Error 403 – Forbidden” error when trying to log in to wp-admin. This error can be caused by incorrect file permissions, poorly coded security plugins, or your server configuration.

If you are seeing this error, then our guide on how to fix the 403 Forbidden Error in WordPress will help you track down and fix the problem.

401 Unauthorized Error

Unauthorized Error

Another message you might see when you are locked out of WordPress admin is the 401 error. This error is sometimes accompanied by a message saying, ‘Access is denied due to invalid credentials’ or ‘Authorization required’.

You can see this message if you have password-protected your WordPress admin folder. It can also be caused by a WordPress security plugin or security measures taken by your hosting company.

Please refer to our guide on how to fix the 401 Error in WordPress to learn six solutions that will help you regain access to your website.

Limited Logins

Limited Logins

By default, WordPress allows users to enter passwords as many times as they want. Hackers may try to exploit this by using scripts that enter different combinations until your website cracks.

To prevent this, we recommend that you limit the number of failed login attempts per user. However, this might mean that you find yourself locked out of your own website when you enter the wrong password too many times.

If you are in that situation, then you should follow the steps in our guide on how to unblock Limit Login Attempts in WordPress.

White Screen of Death

White Screen of Death

Are you seeing a white screen on your WordPress admin? This issue is often referred to as the WordPress white screen of death.

This happens when you exhaust the memory limit. It could be caused by a poorly coded plugin or theme or by unreliable web hosting.

If you are seeing this error, then please refer to our guide on how to fix the WordPress white screen of death.

Incorrect Password Issue

Incorrect Password Issue

There is nothing more frustrating than being told you have used the wrong password when you are sure you haven’t, and you even checked that your caps lock isn’t on.

This can happen if you were a victim of a hack, or you might just be making an honest mistake.

Worse still, when you try to change your password, you never receive the email because it goes to an address you no longer have access to.

Luckily, there is another way, and you can reset your WordPress password from phpMyAdmin. This method can be a bit overwhelming for new users, but it is your best hope for regaining access to your admin area.

Problems With Plugins

You may be locked out of WordPress admin due to a faulty plugin or theme. This may be the case if you can’t log in to WordPress admin after installing a new plugin or if the error message mentions ‘wp-content/plugins/’.

Deactivate All Plugins

To regain access to your site, you will have to temporarily disable your plugins. You can do that using FTP or phpMyAdmin by following our step-by-step guide on how to deactivate all plugins when not able to access wp-admin.

Lost Admin Privileges

Sometimes, you may be able to log in to your WordPress admin, but you don’t see any of the admin functionality. For example, you don’t have access to your themes or plugins.

This can happen if your user permissions were modified. It could be that hackers have infected your site and then deleted your admin privileges.

In this case, you should add an admin user to the WordPress database via MySQL (phpMyAdmin).

Add an Admin User via MySQL

Hacked WordPress Site

If you suspect that your site has been hacked, then there are other steps you may need to take.

A hacked website may look different, display different content, or automatically play music or other media. Worse still, it may be infecting your visitors with viruses, so you need to act quickly.

You can start with our beginner’s guide on how to fix your hacked WordPress site. We will show you how to identify the hack, restore your site from a backup, and remove any malware.

After that, you should protect your site from future attacks. We show you how to do that in our ultimate WordPress security guide.

Login Page Refreshing and Redirecting

Login Page Refreshing and Redirecting

Another type of login error is when your WordPress login page keeps refreshing and redirecting back to the login screen.

This can happen because of incorrect values for the site URL and home URL fields in the WordPress options table. It can also be caused by poorly configured permalink settings or redirects set in the .htaccess file.

To fix this problem, check our guide on how to fix WordPress login page refreshing and redirecting issue.

‘This Has Been Disabled’ Error

When you try to log in to your WordPress admin area, do you see the error ‘This has been disabled’? This message is displayed when you have gone to the wrong admin address.

A common WordPress security practice is to change the default admin login URL ( to something custom. This can help prevent hackers and bots from hammering your login URL trying to gain access.

If you forget that the URL has been changed and go to the old one, then you will see this error message. If you’ve forgotten the correct address, then you should check out our beginner’s guide on how to find your WordPress Login URL.

‘Briefly Unavailable for Scheduled Maintenance’ Error

'Briefly Unavailable for Scheduled Maintenance' Error

Are you seeing the ‘Briefly unavailable for scheduled maintenance’ error in WordPress? This error usually appears while updating WordPress core, plugins, or themes.

But if your WordPress site fails to finish the update, then you are left stuck in maintenance mode.

To fix the problem, you should check our guide on how to fix the Briefly Unavailable for Scheduled Maintenance error in WordPress. The guide will also explain why the error happens and how to avoid it in the future.

PHP Syntax Errors

PHP Syntax Errors

PHP errors can happen after you paste a code snippet from a WordPress tutorial or website. The wrong code can stop your website from working properly and stop you from logging in.

Often, beginners use the built-in WordPress editor from their dashboard. That feature is handy but can lead to disaster if you don’t know what you are doing.

That’s why we wrote our beginner’s guide to pasting snippets from the web into WordPress.

Note: In many cases, it’s safer to use a code snippets plugin like WPCode instead of directly entering custom code. For more details, you can see our guide on how to add custom code safely in WordPress.

If you are locked out of WordPress admin because of a code snippet, then you will have to fix the problem manually using an FTP program like FileZilla to access your files. If you are not familiar with FTP, then check our beginner’s guide on FTP.

After you have connected to your WordPress site using the FTP software, you should follow our guide on how to fix syntax errors in WordPress to correct or remove the code that you added.

Your Site Is Experiencing a Technical Issue

Site is experiencing technical difficulties

Sometimes, when trying to access your WordPress admin area, you may see a white screen or a message saying, ‘The site is experiencing technical difficulties. Please check your site admin email inbox for instructions.’

You will need to log in to your administrator email account and open your inbox.

You should see an automated email from WordPress that will tell you which theme or plugin is causing problems on your site. It also provides a login link so that you can access your WordPress admin.

Email from WordPress about technical problem in your site

Simply click on the link, and you will be able to access your WordPress admin in recovery mode. Then, you will need to deactivate the plugin or theme causing the problems on your site.

However, you may not receive this email with the login link. In that case, please see our guide on how to use WordPress recovery mode.

We hope this tutorial helped you fix the ‘locked out of WordPress admin’ problem. You may also want to learn how to choose the best WordPress hosting or check our list of must have plugins to grow your website.

If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.

Disclosure: Our content is reader-supported. This means if you click on some of our links, then we may earn a commission. See how WPBeginner is funded, why it matters, and how you can support us. Here's our editorial process.

Editorial Staff

Editorial Staff at WPBeginner is a team of WordPress experts led by Syed Balkhi with over 16 years of experience in WordPress, Web Hosting, eCommerce, SEO, and Marketing. Started in 2009, WPBeginner is now the largest free WordPress resource site in the industry and is often referred to as the Wikipedia for WordPress.

The Ultimate WordPress Toolkit

Get FREE access to our toolkit - a collection of WordPress related products and resources that every professional should have!

Reader Interactions

231 CommentsLeave a Reply

  1. Syed Balkhi says

    Hey WPBeginner readers,
    Did you know you can win exciting prizes by commenting on WPBeginner?
    Every month, our top blog commenters will win HUGE rewards, including premium WordPress plugin licenses and cash prizes.
    You can get more details about the contest from here.
    Start sharing your thoughts below to stand a chance to win!

  2. Dayo Olobayo says

    I’ve been locked out of my WordPress admin before and it can be a real panic moment. It’s great to know that there are so many common reasons why it might happen, and that there are solutions for each one. I’ll definitely be bookmarking this for future reference. Thanks!

  3. Jiří Vaněk says

    As for the 403 error, I have also dealt with the problem many times that the blocking was on the hosting provider’s side. Why? Some providers protect themselves against bruteforce attacks and thus have deployed GEO IP protection for the administration, where they use the htaccess file to limit access to the administration only from certain countries. If a person is in a foreign country or uses a VPN, he will not get into the administration. Therefore, it is sometimes a good idea to contact your webhosting provider afterwards.

  4. Michael says

    Now there’s an even NEWER error message that redirects you to this page (/mod-security-error/rule-13051.html):

    “WordPress Login Temporarily Disabled

    We apologize for the inconvenience! You are seeing this message because your site has recently been targeted by attackers attempting to gain access to your WordPress Dashboard. In order to protect your site your WordPress Login page has been temporarily disabled.

    Unfortunately, you will be unable to login to the Dashboard until the block expires.”

    • WPBeginner Support says

      That appears to be an error from your mod security for protecting from brute force attacks. If you reach out to your hosting provider they should be able to assist with that error :)


  5. Tree says

    There has been a critical error on your website.

    Get this message when I try to login to admin and this it what shows when I go to the webpage – it’s totally down.


  6. Mehar says

    “This feature is forbidden temporarily for security reason. Try login again.” this is the issue shown while iam entering the wp-admin url. Why is that issue happening?

    • WPBeginner Support says

      For that error, you would want to check our recommendations under the 403 section as it sounds like that may be a security plugin’s rewording of a 403 error.


  7. Janet Lewison says

    I can’t log in to my admin area as I get the’ invisible captcha is not enabled message’. What can I do please?

  8. Mehwish Abdul Rehman says

    my admin dashboard is opened but when I click any of the functionality like (click on pages to view all the pages) it shows the error page not found…I am unable to configure the problem

  9. Lui says

    Hello, when going to my homepage it says “You have been blocked by site administrator” but all the other pages works totally fine. Can you help?

  10. Atarhe Okejotor says

    I tried accessing my WP dashboard for my blog I get a “This has been disabled” error. Please what can I do to resolve this?

  11. Charl says

    Hi, I changed the link of my wordpress website to ‘https’ to activate our ssl certificate. Now, everytime i attempt to log it, google comes up with a ‘this site cannot be reached’ page. Is there a way to fix this?

  12. Char says

    Everytime I try to login to my wordpress URL, it get redirected to a domain I previously used. This means I cannot login because I set up a new site for the previous domain and it should no longer be associated. I suspect that the change maybe something that I did within wordpress (changing the permalinks?) But I cant login because it keeps redirecting- help!!!

    • WPBeginner Support says

      In that situation, we would recommend first reaching out to your hosting provider and they can normally assist.


  13. Anna says

    I have a wordpress site where the ReCaptcha code got changed, but I was logged out before the code could be updated site-side. Now I’m locked out with a broken ReCaptcha. Any ideas?

  14. Steve Garson says

    I´ve been locked out from my wordpress admin, I cannot access the login page. I just get an error page that says a plugin has a Fatal error.

  15. Ingemar says


    I´ve been locked out from my wordpress admin as I cannot even access the login page – i´m only being redirected to my “Under construction”-page.
    Have tried mysite/wp-login.php and mysite/login and mysite/admin and from different browsers and different IP´s/internetconnections but nothing works. What should i do?

    Thanks for help!

  16. Gazi Sharin Mostafiz says

    I have a woo-commerce website. But when I want to login or logout a popup showing on top. I want to remove this popup sign in box. Please help me if anyone knows the solution.

  17. Sakshi Singh says

    I was working on user registration and login forms using User Submission form plugin. I have enabled the captcha option but unfortunately didn’t set any method. Now, when i am trying to login into my website it’s giving an error “ERROR:Captcha code error, please try again” but their is no option for any type of captcha in my login form, so now i am unable to login anyhow.
    Plz help..

  18. Mary Cheung says

    Please please help me!
    so i tried to update wordpress and pressed [update all]
    Loaded for about 30 mins, now i have HTTP ERROR 500 on the admin panel.

    • WPBeginner Support says

      If you resolve the underlying issue, you should not have to wait to log back into your site.


  19. omer raza says

    I have tried almost everything to log in my WordPress dashboard but it’s not allowing me to log in. I have changed the password in the wp-users table, cleared browser cache and cookies as well but still, it is showing the same error(invalid username or password).

    • WPBeginner Support says

      You would want to reach out to your hosting provider and they should be able to see if there are any errors that could be blocking the password change.


  20. Md Mukarram Hossain says

    Nothing you described matches as the scenario as I faced with my site. I or others can enter my wp dashboard only with the role of administrator. Other users (editor, contributor…) cannot access dashboard. Is there any solution to this problem. Waiting for your reply.

  21. Reese says

    I changed the Url for both WordPress and bluehost now my account has been locked. Is there a way to unlock it

    • WPBeginner Support says

      You would want to reach out to BlueHost and they should be able to help you :)


  22. Dahlia Harari says

    After editing text and publishing I am having a very weird issue.
    The website is online but when I went to my website all that I see is just the menu on the screen.
    What can I do to fix this problem?
    Any help would be most appreciated

    • WPBeginner Support says

      If you are just starting out and didn’t set a static home page then you should start seeing content when you publish posts on your site.


  23. Abdulrazaq Yahaya says

    Good afternoon.
    I want to ask that if you want a developer to help you to design your website either partially or impartially, what position would you post him to, administrator or what?

    • WPBeginner Support says

      Most developers would normally need admin access to be able to see everything and fix issues with the site and the back end of the site.


  24. Philip Sambell says

    I update my WP site plug-ins today and then the site crashed and displays this error:

    Parse error: syntax error, unexpected ‘[‘ in /wp-content/plugins/swiftype-search/vendor/react/promise/src/functions.php on line 17

    I cannot access my site at all, can anyone help please?


  25. Alberto says


    I have WordPress (latest version), Installed Locally with MAMP on my mac, and everything seems fine UNTIL, I activate a plugin. Once I activate this plugin, the entire thing crashes and I can’t do anything but to erase wordpress and reinstall it again. I literally can’t access anything on my dashboard, or any of the options such as plugins, etc. The whole thing is just frozen.

    I don’t get any error or Syntax message, I simply can’t do anything at all.

    Can someone please help me fix this issue?

    Thanks and have a wonderful day!!!

  26. Abhishek Singh says

    I have been locked out of wp-login.php on my pc only, after i overrided it by login via google plus but i can access wp-login.php through other devices…. please reply ASAP so that i can access it on my pc too

  27. UGOCHUKWU says

    I was locked out of my wp admin panel after installing a premium theme, I guess it was as a result of many free themes and plugins I previously installed, I have been trying to get my ftp details from wordpress so I can troubleshoot from filezella,but it has not been ssuccessful.

    • WPBeginner Support says

      For your FTP information, rather than reaching out to WordPress, you would need to reach out to your hosting provider and they would be able to give you that information.


  28. Kevin says

    I was attempting to update some pages on my website, and was eventually locked out of my website. Now, all I get when I go to the website, from any browser, is the following error message-
    Parse error: syntax error, unexpected T_FUNCTION in /home/content/77/7030077/html/wp-content/plugins/redirection/redirection.php on line 100

    I have no idea how to access my website and correct this error. Please help…

  29. Anita says

    Jetpack has blocked my IP address to the login page. However, the IP address that is shown is not mine, but originates in San Jose, Calif. I’m in Glens Falls, NY. I was instructed to send a link to my email address so I could try getting in.

    Fortunately, only one of my sites is being attacked. But it is an important one, so I’m just a little freaked by this. I sure would appreciate any advice that would help me resolve this!

    • WPBeginner Support says

      With Jetpack blocking your UP address, you would want to reach out to Jetpack’s support and explain the situation and they should be able to assist.


  30. Bibhash Roy says

    From today, I am getting this error message in wordpress after I started making changes to integrate and work with Woocommerce.

    This is the message “You have reached the maximum number of requests that is permitted to make per hour. The current rate limit window resets on……”

    Many things are not working in the WP Dashboard after I got this message. Google search did not provide much clue.

    Why I am getting this message? Is WP or Woocommerce responsible for this? What is the fix?

    • WPBeginner Support says

      You may want to reach out to your hosting provider to ensure that is not a limit set by them causing that error.


Leave a Reply to CHLOE Cancel reply

Thanks for choosing to leave a comment. Please keep in mind that all comments are moderated according to our comment policy, and your email address will NOT be published. Please Do NOT use keywords in the name field. Let's have a personal and meaningful conversation.