Home / WordPress Guides / Troubleshooting / 9 Proven Ways to Fix WordPress Login Problems (Fix It Fast)

9 Proven Ways to Fix WordPress Login Problems (Fix It Fast)

TABLE OF CONTENTS

Free WordPress Site Review

Is your WordPress setup ready for what 2026 demands?

TL;DR

Try these three fixes first, in this order. They cover the most common causes of WordPress login problems.
 

  • Reset your password. Use the “Lost your password?” link on the login page. If the reset email never arrives, change the password directly in phpMyAdmin.
  • Clear your browser cache and cookies. This stops the login page from reloading or redirecting in a loop. A private window is a quick way to test.
  • Deactivate all plugins. Rename the plugins folder via FTP or File Manager. If you can log in afterward, a plugin was the cause.

Being locked out of wp-admin is stressful, but WordPress login problems almost always come down to a handful of causes: a wrong password, a stale browser cookie, a plugin conflict, or a damaged core file. Each one has a known fix, and most take only a few minutes.

This guide walks through nine solutions in the order worth trying them, from the quickest (resetting your password, clearing your cache) to the more technical (.htaccess, wp-config.php, database credentials). Most steps work even when the dashboard is unreachable, because they only need your hosting File Manager, FTP, or phpMyAdmin.

Before editing any file, save a copy of it so you can roll back. And if you would rather hand the job to a developer, Kiwistic can restore access and find the root cause.

Why Can’t I Log In To WordPress? Common Causes

WordPress login problems can happen for several reasons, including incorrect credentials, browser cookie issues, plugin conflicts, or server errors. The quickest way to identify the cause is to look at what happens when you try to access your WordPress admin dashboard.

Here are seven common causes and the symptoms that can help you recognize them:
  • Incorrect username or password. If WordPress displays an “Incorrect password” or “Unknown username” message, your login credentials may be wrong. Check for typing errors, confirm that Caps Lock is off, and make sure you’re using the correct username or email address.
  • Browser cookie or cache issues. If your login page keeps refreshing, redirects you back to the login form, or displays a cookie-related error, your browser may not be storing authentication cookies correctly. Browser settings, cached data, and server-side caching can all contribute to login problems.
  • Plugin or theme conflicts. A faulty update or incompatible plugin or theme can trigger a critical error, a blank screen, or an inaccessible admin area. If the problem started immediately after an update, the affected component is a useful place to investigate.
  • Corrupted or misconfigured WordPress files. Problems with .htaccess, wp-login.php, or other core files can prevent the login page from loading correctly. Depending on the affected file and server configuration, you might encounter redirect loops, server errors, or a blank page.
  • Incorrect WordPress site URLs. If your WordPress Address (URL) and Site Address (URL) are configured incorrectly, you may experience unexpected redirects or authentication issues. This can happen after a domain change, website migration, or HTTPS configuration change.
  • PHP memory exhaustion. When WordPress or one of its plugins exceeds the available PHP memory limit, the request may fail with a fatal error. Symptoms can include a critical error message, an HTTP 500 error, or a blank screen. Check the error logs before assuming memory is the cause.
  • Database connection errors. If your site displays “Error establishing a database connection,” WordPress cannot communicate with its database. Possible causes include incorrect database credentials, an unavailable database server, or database-related problems.

Not sure which issue you’re facing? Start with the error message or symptom you can see. The troubleshooting steps below begin with simple login and browser checks before moving to changes involving plugins, WordPress files, and server settings.

For additional checks involving passwords, browser cookies, and security software, see the official WordPress login troubleshooting guide.

9 Step-by-Step Solutions to Fix Your WordPress Login

The right fix depends on what happens when you try to log in. An incorrect-password message, a login page that keeps refreshing, and a critical error are different problems. Treating them as the same issue can lead to unnecessary changes to your website.
Start with the least disruptive checks. Only move on to plugins, server files, or the database when the earlier steps do not resolve the problem or the error points to a specific cause.

1. Check Your Credentials & Reset Your Password

Start here if WordPress says your username, email address, or password is incorrect. If your credentials are accepted but you are redirected back to the login page, the issue may involve cookies or redirects instead. We cover those possibilities in the next steps.

Before resetting anything, confirm that you are using the login page for the correct website. A staging site and a live site can look identical while using separate user accounts.
Also check whether your browser has autofilled an outdated password. If you use a password manager, select the saved credentials for the correct domain rather than relying on the first suggested login.

Method A: Reset Your Password from the Login Page

Use this method when you still have access to the email address associated with your WordPress account.

1. Open your WordPress login page, typically yourdomain.com/wp-login.php.

2. Select Lost your password?

Lost your password?

3. Enter your WordPress username or the email address associated with your account.

WP Get New Password

4. Select Get New Password.

5. Check your inbox for the password-reset email and follow its link.

6. Choose a new, unique password and sign in again.

If the reset email does not arrive: Check your spam folder and confirm that you entered the email address assigned to the WordPress user. A missing message does not automatically mean the account is gone. Email delivery may be failing, or the account may use a different address.

If your website uses two-factor authentication (2FA), resetting your password will not necessarily remove the additional authentication requirement.

Method B: Reset Your Password Through phpMyAdmin

Use this method only if the email reset is unavailable and you have authorized access to the website’s hosting account and database.

Editing the database directly is more sensitive than using the login form. Create a database backup first, and confirm that you have selected the correct database and user account.

1. Sign in to your hosting control panel and open phpMyAdmin.

This is the login page for cPanel.

2. Select the database used by your WordPress installation. If you are unsure which one is correct, check the DB_NAME value in wp-config.php.

Database management - phpmyadmin

3. Find the WordPress users table. It is commonly named wp_users, but the prefix may be different.

phpmyadmin - wp_table

4. Open the table and locate your account using the user_login or user_email column.

wp_users table in phpmyadmin

5. Select Edit for the correct user.

wp_users - edit

6. Find the user_pass field.

7. Enter a new, strong, unique password in its value field and select MD5 from the Function dropdown.

wp_users table

8. Save the change by selecting Go.

9. Return to the WordPress login page and sign in with your new password.

user_pass - Save changes

Why MD5 appears in these instructions: This is a compatibility-based recovery procedure documented by WordPress, not a recommendation to use MD5 for ongoing password storage. On a standard modern WordPress installation, a successful login causes the temporary MD5 password hash to be replaced with a stronger hash.

If you have WP-CLI access, you can also reset a WordPress user’s password without editing database rows manually. This may be preferable for an experienced administrator.

How to tell whether this fixed the issue

Try signing in once with the new credentials.

1. You reach the WordPress dashboard: The password reset worked.

2. WordPress still reports incorrect credentials: Recheck the username, site, database, and user record before changing anything else.

3. The login page refreshes or redirects without signing you in: Continue to Step 2 and investigate browser cookies.

4. You see a critical error or blank page: A password reset is unlikely to resolve the underlying problem. Investigate WordPress errors, plugins, or themes instead.

Avoid repeatedly changing the password when the error message has not changed. Identify what is failing before making another modification.

2. Clear Your Browser’s Cache and Cookies

Use this fix if WordPress accepts your login details but sends you back to the login screen, or if you see a message saying cookies are blocked.
WordPress uses authentication cookies to keep you signed in. If those cookies are blocked, expired, or no longer valid, you may be unable to access the dashboard even with the correct password.
The goal here is to check whether the problem is specific to your browser before changing anything on your website.
First, test the login in a private window

1. Open an Incognito window in Chrome or a Private Browsing window in Firefox.

2. Visit your WordPress login URL, usually yourdomain.com/wp-login.php.

3. Enter your credentials manually and try to sign in.

4. If the login still fails, repeat the test in another browser.

If you can sign in through a private window but not your regular browser, that points to a browser-specific issue. Stored cookies, extensions, or browser settings may be responsible.
A successful private-window login does not prove that cached files are the cause.

Clear Cookies and Site Data in Google Chrome

You usually don’t need to delete your entire browsing history. Start by removing data stored for the affected website.

1. Open Chrome and go to Settings → Privacy and security → Third-party cookies.

Chrome Privacy and security settings with the Third-party cookies option highlighted.

2. Open See all site data and permissions. The location or wording may differ by Chrome version.

Chrome Third-party cookies settings showing the See all site data and permissions option.

3. Search for your website’s domain.

4. Delete the stored site data for that domain.

Chrome site data list showing kiwistic.com and the delete icon for removing its stored cookies and data.

5. Open the WordPress login page again and sign in.

If the problem continues, try clearing Chrome’s cached images and files through Settings → Privacy and security → Delete browsing data.

How to clear cache in Chrome browser

Note: Removing cookies for a domain signs you out of sessions associated with that domain.

Clear Cookies and Site Data in Mozilla Firefox

1. Open Firefox and go to Settings → Privacy & Security.

2. Find Cookies and Site Data.

3. Click Manage Data.

4. Search for your website’s domain.

5. Select the matching website data and click Remove Selected.

6. Save the changes and try logging in again.

You can also clear Firefox’s cached web content if removing site cookies does not help.

Check Whether Cookies Are Being Blocked

If WordPress displays “Cookies are blocked or not supported by your browser”, check that your browser allows cookies for the website.

Temporarily disable browser extensions that modify cookies, block scripts, or change privacy settings, then test the login again. Re-enable them after testing.
Do not disable browser security protections permanently just to access WordPress.

What if the login still redirects?

If the same problem occurs across multiple browsers or devices, stop clearing browser data. The next likely causes are elsewhere in the setup:
  • A plugin interfering with authentication or redirects.
  • Incorrect WordPress site URLs or an HTTP/HTTPS mismatch.
  • Server-side caching or security rules affecting the login request.

Continue to Step 3 to check for plugin conflicts.

3. Rule Out Plugin Conflicts (The Safe Way)

Try this if your WordPress login stopped working after a plugin update, a new installation, or a configuration change. Plugin conflicts can cause login redirects, PHP errors, or a critical error that prevents the dashboard from loading.
The challenge is identifying the faulty plugin without unnecessarily disrupting the rest of your website.
At Kiwistic, we’ve worked on WordPress login issues using FTP, phpMyAdmin, and WP-CLI. One of the most useful troubleshooting principles is to isolate the problem before making permanent changes. Temporarily disabling plugins is a diagnostic test, not a reason to start deleting files.

Before You Disable Anything

If you can still access the WordPress dashboard, deactivate the most recently installed or updated plugin first. Test your login before disabling anything else.
If WordPress shows a critical error, check your administrator email for a Recovery Mode link. When available, this can help you access the dashboard and identify a faulty plugin without changing its files manually.
If you cannot access the dashboard or Recovery Mode, you can test plugin conflicts through FTP or your hosting File Manager.

Important: Before proceeding, make sure you have a recent backup of your website files and database. Disabling plugins can temporarily affect contact forms, payment processing, caching, security features, and other active functionality. On a busy WooCommerce store or another business-critical website, perform this test during a suitable maintenance window or on a staging copy when possible.

How to Disable WordPress Plugins Using FTP or File Manager

1. Connect to your website using an FTP/SFTP client or open the File Manager in your hosting control panel.

2. Locate the WordPress installation directory. It usually contains wp-admin, wp-content, and wp-includes.

3. Open the wp-content folder.

4. Find the folder named plugins.

5. Rename it to plugins-disabled.

6. Open your WordPress login page and try signing in again.

theme & plugin rename

(This action is completely safe and reversible. By renaming the folder, WordPress can no longer find your plugins and will automatically disable all of them.)

Renaming the folder makes the normally installed plugins unavailable to WordPress. This is a temporary way to test whether one or more of them are interfering with the login process.

If you can log in now: A standard plugin is likely involved. Continue with the isolation steps below.

If you still cannot log in: Rename plugins-disabled back to plugins. Don’t leave the folder renamed while investigating unrelated causes.

Keep in mind that this test does not necessarily disable must-use plugins (mu-plugins), server-level security rules, or functionality loaded outside the standard plugins directory.

How to Identify the Problematic Plugin

If disabling the plugins restores access:

1. Rename plugins-disabled back to plugins.

2. Open Plugins → Installed Plugins in your WordPress dashboard.

3. Check which plugins are inactive. You may need to reactivate them manually.

4. Reactivate one plugin at a time, testing the login and affected website features after each activation.

5. If the issue returns after activating a particular plugin, deactivate it again and investigate further.

Pay special attention to plugins that control authentication, security, redirects, caching, or two-factor authentication, especially if one was recently changed.

Don’t delete the suspected plugin immediately. First, check its update history, compatibility, error logs, and available support or rollback options. Removing a plugin can also affect its settings or stored data.

For business-critical websites, restoring normal functionality matters as much as restoring dashboard access. Check forms, checkout, scheduled tasks, and other features that depend on plugins before considering the issue resolved.

What If the Plugin Folder Test Doesn’t Work?

If the login problem continues with the standard plugins disabled, move on to the next diagnostic step rather than making random changes.
A theme conflict, incorrect WordPress URLs, server configuration, or a separate authentication issue may be responsible.

Continue to Step 4: Switch to a Default WordPress Theme to test whether your active theme is contributing to the problem.

4. Switch to a Default WordPress Theme

Try this if your login problem started after a theme update, a change to your theme’s PHP files, or an unexpected critical error.
Your WordPress theme controls more than how the website looks. It can also run PHP code, register custom functions, and interact with plugins. An error in that code may prevent the login page or dashboard from loading correctly.
Switching temporarily to a default WordPress theme helps determine whether your active theme is involved.

Before Switching Themes

Check whether a default WordPress theme, such as Twenty Twenty-Five, is already installed and compatible with your WordPress version.

If you can access the dashboard, go to Appearance → Themes and check your installed themes. If you cannot access it, inspect the folders inside wp-content/themes using SFTP or your hosting File Manager.

Important: Switching themes on a live website can change its layout, navigation, widgets, and other theme-dependent features. Use a staging environment when possible, especially for a WooCommerce store or a business-critical website. Keep a recent backup before making changes.

Method A: Switch Themes from the WordPress Dashboard

If you can still access the dashboard:

1. Go to Appearance → Themes.

2. Find an installed default WordPress theme.

3. Select Activate.

4. Test the affected login or dashboard page.

5. Check whether the original error still appears.

If the problem disappears with the default theme, your previous theme or its interaction with another component may be responsible.
This test does not prove that the theme alone is defective. The problem may involve custom code, a child theme, or compatibility with a plugin.

Method B: Rename Your Active Theme Folder Using SFTP

If you cannot access the dashboard, you can temporarily make your active theme unavailable through your hosting files.

1. Connect to your hosting account using SFTP or open its File Manager.

2. Navigate to wp-content/themes/.

3. Identify the folder belonging to your currently active theme.

4. Confirm that a compatible default WordPress theme is also installed.

5. Rename your active theme folder. For example, change my-theme to my-theme-disabled.

6. Reload your WordPress login page and try accessing the dashboard.

WordPress login problems - Theme deactivation

(This action tells WordPress it can no longer find your active theme. It will then automatically fall back to the most recent default theme it can find.)

WordPress may switch to an installed default theme when the active theme becomes unavailable.

If no usable fallback theme is installed, this test may leave the website displaying an error. Do not assume WordPress can automatically recover without another theme.

What Do the Results Tell You?

The login works with the default theme.

Your previous theme is likely involved in the problem. Before reactivating it, review recent theme updates, custom PHP changes, child-theme modifications, and available error logs.
If the problem started after a specific update, check whether the theme developer has published a fix or compatibility guidance.

The login still fails

Restore the original folder name and continue investigating. The cause may involve WordPress URLs, server configuration, core files, or another component.

The website shows a new error

First, verify that a working default theme is installed. Restore the original folder name if the fallback fails, then check the site’s PHP error logs before making additional changes.

Restore Your Original Theme After Testing

If you renamed the active theme folder:

1. Return to wp-content/themes/.

2. Rename the folder back to its original name.

3. If you can access WordPress, open Appearance → Themes.

4. Reactivate your original theme only when it is safe to do so.

5. Check the website’s layout, navigation, and important functionality.

Restoring the folder name does not necessarily reactivate the theme automatically.
Avoid deleting the theme or reinstalling it before identifying the cause. Custom changes inside the theme folder could be lost during replacement.

If the problem persists after testing both plugins and themes, continue to Step 5: Fix a Corrupted .htaccess File to investigate possible server-level redirect or rewrite issues.

5. Fix a Corrupted .htaccess File

Check your .htaccess file if your WordPress login returns a 403 Forbidden or 500 Internal Server Error, or if the problem began after changes to redirects or server rules.

The .htaccess file controls certain web server behaviors on WordPress websites running Apache or compatible server configurations. It can contain URL rewrite rules, redirects, access restrictions, and security settings.
An incorrect rule can prevent WordPress from loading properly, including pages involved in the login process.

Not every WordPress website uses .htaccess. Standalone Nginx servers manage these rules through their server configuration instead. If you’re unsure which web server your hosting account uses, check with your hosting provider before editing anything.

Step 1: Back Up Your Existing .htaccess File

Before changing the file, save a copy of its original contents.

1. Connect to your hosting account using SFTP or File Manager.

2. Open the directory containing your WordPress installation, usually the same folder as wp-config.php.

WordPress login problems - htaccess settings

3. Enable Show Hidden Files if you cannot see .htaccess.

WordPress login problems - htaccess show

4. Download a copy of the file to your computer.

5. Check whether it contains custom redirects, security restrictions, or other rules you may need to restore later.

This matters because the file may contain more than WordPress’s standard permalink rules. Replacing it without reviewing those changes could break existing redirects or remove important protections.

Step 2: Temporarily Rename the File

Once you have a backup:

1. Find the .htaccess file in your WordPress installation directory.

2. Rename it to .htaccess_old.

htaccess

3. Open your WordPress login page again.

4. Check whether the original error still appears.

Renaming the file temporarily removes its rules from the server’s normal .htaccess processing.

If your login works again: A rule in the original file may have caused the problem. Don’t delete the backup yet.

If the same error remains: Rename .htaccess_old back to .htaccess and continue troubleshooting. The file may not be responsible.

If the website behaves unexpectedly after renaming the file, restore the original filename immediately.

Step 3: Restore Your WordPress Permalink Rules

If the login starts working after you rename .htaccess:

1. Sign in to your WordPress dashboard.

2. Go to Settings → Permalinks.

Permalinks WordPress

3. Keep your existing permalink structure unchanged.

4. Click Save Changes if you need WordPress to attempt to update the rewrite configuration.

4. Check whether a new .htaccess file has been created or updated.

WordPress can write its standard rewrite rules when the server configuration and file permissions allow it. If the file is not writable, you may need to update the rules manually or ask your hosting provider for assistance.

Do not copy the entire old file back without reviewing it. That could restore the same rule that caused the error.

Instead, compare the original and regenerated files, then restore only the custom rules that are still necessary and verified to work.

Step 4: Test More Than the Login Page

After restoring the configuration, check:
  • Whether wp-login.php and wp-admin load correctly.
  • Whether regular pages and blog posts open without 404 errors.
  • Whether HTTPS and security restrictions continue to work.
  • Whether contact forms and other important website features still function.

A successful login is only part of the test. A change to .htaccess can affect URLs and functionality elsewhere on the website.

What If Your Website Uses Nginx?

A standalone Nginx server does not use Apache-style .htaccess files. Renaming or creating one will not fix its rewrite or redirect configuration.
Instead, check the Nginx configuration and error logs with your hosting provider or server administrator.
Do not apply Apache rewrite rules directly to an Nginx configuration.

Still unable to log in? If the issue persists after checking the server rules, continue to Step 6: Verify Your WordPress Site URLs. Incorrect site addresses can also cause login redirects and prevent access to the dashboard.

7. Repair a Corrupted wp-login.php File

Consider this step if your WordPress login page displays a PHP error, fails to load, or stopped working after an interrupted WordPress update.

The wp-login.php file is part of WordPress core. It handles the standard login screen and several authentication-related actions.
If this file is missing, damaged, or modified incorrectly, the login page may stop working.
However, a failed login does not automatically mean wp-login.php is corrupted. A redirect loop, incorrect password, or plugin conflict usually needs a different fix.

Step 1: Check Whether the Core File Is the Problem

Before replacing anything, look for evidence that points to wp-login.php.
For example:
  • The login page produces a PHP fatal error referencing wp-login.php.
  • The file is missing from your WordPress installation.
  • A WordPress update or file transfer was interrupted.
  • A file integrity check reports that wp-login.php differs from the expected WordPress core file.
WordPress installation files in hosting File Manager showing the wp-login.php core file

A changed file is not always proof of corruption. It could also indicate an unauthorized modification. If you suspect malware, investigate the wider installation instead of treating the replacement as a complete security fix.

At Kiwistic, we’ve used FTP and other administrative tools to investigate WordPress login problems. The important part of this process is checking the likely cause before replacing website files.

Step 2: Back Up Your Existing WordPress Files

Before making changes:

1. Connect to your website using SFTP or your hosting File Manager.

2. Open the directory containing your WordPress installation.

3. Locate wp-login.php, typically alongside wp-admin, wp-content, and wp-includes.

4. Download a copy of the existing wp-login.php file.

5. Confirm that you have a recent backup of your website files and database.

Do not edit or replace wp-config.php, your themes, or your plugins as part of this specific test.

Step 3: Download a Clean Copy of WordPress

You need a trustworthy copy of the WordPress core files.

1. Identify the WordPress version currently installed on your website.

2. Visit the official WordPress download or release archive.

3. Download the appropriate WordPress package.

4. Extract the ZIP file on your computer.

5. Find wp-login.php inside the extracted WordPress folder.

Make sure the file comes from the correct WordPress release. Do not download an arbitrary copy from another website or assume that a file from a different WordPress version is interchangeable.

If you cannot reliably determine your installed version, do not guess. Ask your hosting provider or a WordPress developer to verify it first.

Step 4: Replace the Damaged wp-login.php File

Once you have confirmed the file needs replacing:

1. Return to your website’s WordPress installation directory.

2. Rename the existing wp-login.php file to wp-login.php.bak to preserve a temporary copy.

WordPress wp-login.php file selected in hosting File Manager with the Rename option highlighted.

3. Upload the clean wp-login.php file from the verified WordPress package.

4. Confirm that the uploaded file has appropriate permissions for your hosting environment.

5. Open your WordPress login page and test it.

Avoid changing unrelated core files during this step.

If the login page works again: The original file may have contributed to the problem.

If the error continues: Review the PHP error logs and other WordPress components rather than repeatedly replacing the same file.

If the replacement introduces a new problem, restore the original file from your backup while you investigate.

Step 5: Check for Further WordPress Core Issues

Restoring the login page does not necessarily mean the underlying issue is resolved.
After a successful login:

1. Confirm that /wp-admin/ loads correctly.

2. Check whether WordPress reports an incomplete or pending core update.

3. Verify the integrity of the remaining WordPress core files.

4. Review PHP error logs for related problems.

5. Check for unexpected administrator accounts or suspicious file changes if you suspect unauthorized access.

If several WordPress core files are missing or modified, replacing wp-login.php alone may not be enough. A controlled WordPress core reinstallation or security investigation may be required.

Security note: If the original file contains suspicious or malicious code, do not restore it to the live website. Preserve a copy for investigation and examine the rest of the installation.

What If Replacing wp-login.php Doesn’t Fix the Login?

If the file is clean and the same issue remains, the cause may involve PHP configuration, another WordPress component, or a server-level error.
Check the actual error message and server logs before making further changes.

Continue to Step 8: Increase Your PHP Memory Limit only if you have evidence of a memory-related error. Increasing the memory limit will not resolve every WordPress login problem.

8. Increase Your PHP Memory Limit

Try this step if your WordPress login page displays an “Allowed memory size exhausted” error, or if your PHP error logs show that WordPress ran out of available memory during login.

WordPress needs PHP memory to load its core files, plugins, and theme functions. If a process exceeds the available memory limit, PHP may stop executing it, resulting in a critical error or a page that fails to load.
However, not every WordPress login error is a memory problem. If you receive an incorrect-password message or a redirect loop without a memory-related error, increasing the limit is unlikely to help.

Step 1: Confirm That PHP Memory Is the Problem

Before changing the configuration, look for an error similar to this:
PHP Fatal error: Allowed memory size of 134217728 bytes exhausted
This example indicates that a PHP process reached a memory limit of approximately 128 MB.
You may find this information in:
  • Your hosting control panel’s PHP error logs.
  • WordPress debug logs, if logging was already enabled.
  • A technical error report provided by your hosting company.
Check the timestamp and file path to confirm that the error occurred during the failed login attempt.

Important: A memory error tells you that PHP exhausted its available memory. It does not tell you which plugin, theme function, or process is responsible.

Step 2: Check Your Current Memory Settings

WordPress and your hosting environment can have different memory settings.
Two WordPress configuration constants are especially relevant:
  • WP_MEMORY_LIMIT: The memory limit WordPress requests for normal execution.
  • WP_MAX_MEMORY_LIMIT: The higher memory limit WordPress can request for certain administrative operations.
Your hosting server also has a PHP setting called memory_limit, which controls how much memory a PHP process can use.
WordPress may be able to increase the effective PHP memory limit at runtime, but some hosting environments restrict this.

If you can access the dashboard, check Tools → Site Health → Info → Server for the PHP memory limit reported by WordPress.

WordPress Site Health Info screen showing the Server section where PHP memory settings can be checked.
If the dashboard is unavailable, review your hosting PHP settings or contact your hosting provider.

Step 3: Adjust the WordPress Memory Limit

If the error confirms a memory shortage and your hosting environment permits a higher limit, you can test a configuration change.

1. Connect to your website using SFTP or your hosting File Manager.

2. Locate wp-config.php in your WordPress installation.

3. Download a backup copy before editing.

4. Open the file in a code editor.

5. Search for an existing WP_MEMORY_LIMIT definition.

6. If one exists, review and update it rather than adding a duplicate.

7. Save the file and test the login again.

For example, to request a 512 MB memory limit for normal WordPress execution:

define( ‘WP_MEMORY_LIMIT’, ‘512M’ );

Place the definition before the line:
/* That's all, stop editing! Happy publishing. */
WordPress login problems - Memory limit

512 MB is an example, not a required setting for every website. The appropriate value depends on your actual memory usage, hosting resources, and application requirements.

If you have already configured WP_MEMORY_LIMIT and the problem continues, check the effective PHP limit before increasing the value again.

Step 4: Check the WordPress Admin Memory Limit

WordPress also supports a separate memory setting for administrative operations.
For example:

define( ‘WP_MAX_MEMORY_LIMIT’, ‘512M’ );

This controls the higher amount WordPress may request for certain backend operations. It is not necessarily the memory limit used by every login request.

Do not increase WP_MAX_MEMORY_LIMIT simply because the login form fails. First verify whether the failing process is affected by that setting.

Also, setting either constant does not guarantee that PHP can use the requested amount. Your hosting environment must permit the increase.

Step 5: Check Your Hosting PHP Memory Limit

If the error continues after updating wp-config.php, review your hosting configuration.
Depending on your hosting provider, PHP settings may be available through a control panel, a PHP configuration file, or a support request.
Look for the PHP directive:

memory_limit = 256M

This is an example of a PHP configuration setting, not PHP code to paste into wp-config.php.

Do not create or edit a php.ini file without confirming how your hosting environment manages PHP settings. On some servers, changes made in the wrong location have no effect.
If your hosting plan restricts memory usage, ask your provider which limits apply to your website and whether they can be adjusted.

Step 6: Retest and Identify the Underlying Cause

After making a verified memory adjustment:

1. Reload your WordPress login page.

2. Try signing in.

3. Check whether the previous memory error appears again.

4. Review the PHP logs for new errors.

5. If access is restored, inspect recently updated plugins, theme functions, and resource-intensive operations.

If increasing the limit resolves the error, don’t stop investigating automatically.

A plugin that unexpectedly consumes excessive memory may continue creating performance problems even after the limit is raised.
When troubleshooting WordPress login problems, we focus on identifying the failing component rather than repeatedly increasing server resources without evidence.
If the memory error persists despite an appropriate limit, investigate the stack trace and the specific PHP process involved. The problem may require code-level troubleshooting or hosting assistance.

Still unable to access WordPress? Continue to Step 9: Check for a Database Connection Error, but only if the website displays a database-related error or the logs indicate a database connection failure.

9. Check for a Database Connection Error

Use this step if WordPress displays “Error establishing a database connection” when you open the website or try to access the login page.

WordPress stores user accounts, passwords, settings, posts, and other essential information in a database. If WordPress cannot connect to that database, it cannot retrieve the information needed to run the website or authenticate users.
Unlike an incorrect-password error, a database connection failure usually affects more than the login page. You may also find that the homepage and other pages are unavailable.
The two main possibilities to investigate are incorrect database connection settings and a database server that is unavailable or refusing connections.

Step 1: Check Your Database Credentials in wp-config.php

WordPress normally stores its database connection settings in wp-config.php.
To inspect them:

1. Connect to your hosting account using SFTP or File Manager.

2. Open your WordPress installation directory.

3. Locate wp-config.php and download a backup copy.

4. Open the file in a code editor.

5. Find the database configuration section.

You should see settings similar to these:

define( ‘DB_NAME’, ‘example_database’ );
define( ‘DB_USER’, ‘example_user’ );
define( ‘DB_PASSWORD’, ‘your_database_password’ );
define( ‘DB_HOST’, ‘localhost’ );

Here’s what each value means:
  • DB_NAME: The name of the database WordPress connects to.
  • DB_USER: The database account used by WordPress.
  • DB_PASSWORD: The password for that database account.
  • DB_HOST: The address of the database server.
wp-config.php file Database Credentials
These are illustrative values, not credentials to copy into your website.

Don’t assume DB_HOST must be localhost. Some hosting providers use a separate hostname, IP address, port, or socket.

If the connection error appeared immediately after a migration or hosting change, compare these values with the configuration provided by your current host.

Step 2: Verify the Database in Your Hosting Panel

Next, confirm that the database and its assigned user actually exist.

In cPanel, this information is commonly available under MySQL Databases or Manage My Databases. Other hosting panels may use different names.

Install Manually WordPress: Select MySQL Database
Check the following:

1. The database listed in your hosting panel matches DB_NAME.

2. The database user matches DB_USER.

3. The database user is assigned to the correct database.

4. The user has the permissions required by WordPress.

5. The database hostname matches the value supplied by your hosting provider.

Be careful with database passwords. Most hosting panels do not display an existing database password in plain text.

If you suspect a password mismatch, verify the available recovery process before resetting it. Changing a database user’s password without updating WordPress and any other applications that use that account can cause additional outages.
At Kiwistic, we’ve used phpMyAdmin and WP-CLI while troubleshooting WordPress issues. In database-related incidents, it’s important to establish which connection details are actually wrong before making changes.

Step 3: Check Whether the Database Server Is Available

If the configuration appears correct, the problem may be with the database service rather than WordPress.
Open phpMyAdmin through your hosting panel, if available, and check whether you can access the expected database.
Keep in mind that phpMyAdmin access alone does not prove WordPress can connect using the credentials in wp-config.php. The tools may authenticate differently.
If your hosting account provides database or server error logs, look for messages involving:
  • Connection refused or connection timed out.
  • Access denied for the configured database user.
  • Too many database connections.
  • Database server unavailable.
These messages point to different problems and should not all be treated as password errors.
If the database server is unavailable, contact your hosting provider. Ask them to check the database service, connection limits, account restrictions, and relevant server logs.

Step 4: Check Database Health Only After Connectivity Is Restored

A connection failure and a damaged database table are not the same problem.
If WordPress can connect but you suspect table-level issues, an administrator with appropriate access can investigate the database using phpMyAdmin or WP-CLI.
For example, WP-CLI provides a database check command:

wp db check

Run this only in the correct WordPress installation and after confirming that database access is working.

Do not run database repair, reset, or restore commands without understanding their effects and having a verified backup. In particular, a database reset is not a troubleshooting shortcut, it can remove website data.

Step 5: Confirm the Website Is Working Again

Once the connection issue is resolved:

1. Reload the homepage and confirm it opens normally.

2. Visit the WordPress login page.

3. Sign in with a valid administrator account.

4. Check that the dashboard loads without database errors.

5. Test a few important pages and database-dependent features.

6. Review the logs to confirm the original connection error is no longer occurring.

If the error returns intermittently, record when it happens and ask your hosting provider to investigate database availability and connection limits.

If the database is working but you still cannot log in, return to the error-specific checks earlier in this guide. A successful database connection does not automatically resolve incorrect credentials, cookie problems, or authentication-related plugin conflicts.

How to Prevent Future WordPress Login Issues

Fixing a WordPress login problem is one thing. Reducing the chance of it happening again requires a few ongoing checks.
Not every login issue is preventable. Hosting outages, failed updates, and unexpected software conflicts can still happen. But the following practices can make your WordPress website more secure and easier to recover.

1. Keep WordPress, Plugins, and Themes Updated

Outdated software can introduce security vulnerabilities and compatibility problems. However, updating everything at once without checking the results can also create unexpected issues.
For a safer update process:
  • Back up your website before significant changes.
  • Review plugin and theme compatibility.
  • Test major changes on a staging website when possible.
  • Check the login page, dashboard, forms, and important website features after updating.
If something breaks, knowing which component was updated makes troubleshooting much easier.

2. Protect Your Administrator Accounts

A strong password is important, but it should not be your only login protection.
Use a unique password for every administrator account and enable two-factor authentication (2FA) where supported.
Also:
  • Remove accounts that no longer need access.
  • Give users only the permissions required for their work.
  • Keep the email addresses associated with administrator accounts current.
  • Secure the email accounts used for WordPress password recovery.
Avoid sharing a single administrator login between multiple people. Individual accounts make access easier to manage and revoke when necessary.

3. Maintain Reliable Backups and Test Restores

A backup is useful only if you can restore it.
Keep regular backups of both your WordPress files and database. Store copies separately from the live hosting environment so that a server failure does not affect every available copy.
Periodically verify that backups complete successfully and test the restore process in a safe environment.
For business websites, make sure you know who can access the backups and what steps are required to restore the site if the dashboard becomes unavailable.

4. Monitor Website Errors Before They Become Bigger Problems

Some WordPress problems produce warning signs before the website becomes completely inaccessible.
Watch for:
  • Failed plugin or WordPress core updates.
  • Repeated PHP fatal errors.
  • Unexpected redirects.
  • Unusual login activity.
  • Website downtime or recurring server errors.
Keeping useful error logs and monitoring website availability can help identify when a problem started.
If you notice repeated login failures, investigate the cause rather than assuming every attempt is an attack. Incorrect credentials, outdated saved passwords, and authentication settings can produce similar symptoms.

5. Keep an Alternative Recovery Method Available

If you lose WordPress dashboard access, you may need another way to investigate the problem.
Make sure an authorized website administrator knows how to access the hosting control panel, SFTP, backups, and relevant technical support contacts.
You don’t need to use these tools regularly. The goal is to avoid discovering during an outage that nobody has the access required to recover the website.
Keep credentials in a secure password manager, not in shared documents or email threads.

6. Follow a Consistent Maintenance Routine

For websites that generate leads, process orders, or support daily business operations, WordPress maintenance should be a routine rather than something you do only after an error.
A practical routine includes testing updates, checking backups, monitoring security and uptime, and reviewing technical errors.

If you’d rather have these tasks handled regularly, Kiwistic’s WordPress maintenance services cover ongoing updates, backups, monitoring, and technical support.

The goal isn’t to eliminate every possible WordPress error. It’s to reduce avoidable problems and make recovery more manageable when something goes wrong.

Conclusion

WordPress login problems are easier to troubleshoot when you start with the error you’re actually seeing. An incorrect password, a redirect loop, and a PHP fatal error require different approaches. Making changes without identifying the symptom can create more problems than it solves.

If you’ve restored access, check that your dashboard, website pages, and essential features work correctly before considering the issue resolved. Keep a reliable backup, document any changes you made, and investigate recurring errors rather than applying the same temporary fix again.

FAQ

Why does my WordPress login page keep refreshing or redirecting?

A login page that refreshes or redirects without signing you in can indicate a problem with authentication cookies, WordPress URL settings, plugins, or server redirects.

Start by testing the login in a private browser window. If the problem also occurs in another browser, investigate the site’s URL configuration and authentication-related plugins. Avoid changing .htaccess rules unless the symptoms or server logs give you a reason to suspect them.

How can I find my WordPress username if I've forgotten it?

The WordPress password-reset form accepts either a username or the email address associated with your account.

If you don’t remember either, an authorized administrator with database access can inspect the WordPress users table through phpMyAdmin. The table is commonly named wp_users, but its prefix may be different. Look for your account in the user_login and user_email columns.

Don’t create another administrator account until you’ve confirmed whether your original account still exists.

What does a blank white screen on my WordPress login page mean?

A blank white screen can be caused by a PHP fatal error, but the screen alone doesn’t identify the cause.

Check the PHP error logs for the time of the failed request. Common areas to investigate include recently updated plugins, theme code, incompatible PHP changes, and memory exhaustion.

Use the error details to choose the next step instead of immediately increasing the PHP memory limit or replacing WordPress core files.

What if I lose access to my WordPress two-factor authentication (2FA) app?

Start by checking whether you saved backup recovery codes or have another recovery method supported by your authentication plugin or identity provider.

If another authorized administrator can access WordPress, they may be able to help reset your 2FA setup.

If neither option is available, the recovery process depends on how 2FA was configured. Some plugins provide administrator or command-line recovery methods, while other authentication systems may be managed outside WordPress.

Avoid disabling your site’s security protections without verifying the appropriate recovery procedure. Once access is restored, configure 2FA again and securely store new recovery codes.

Why can I log in to WordPress but not access wp-admin?

If your credentials work but you cannot open the dashboard, first check what happens after signing in.

A redirect back to the login screen may point to an authentication cookie or URL configuration problem. A 403 error may indicate a server security rule or access restriction. A message saying you don’t have permission to access a page may involve your WordPress user role or capabilities.

If you see a critical error instead, check the PHP logs and recent plugin or theme changes.

The correct fix depends on the error. Don’t reset your password repeatedly if WordPress is already accepting your credentials.

Ognjen Velickovic

WordPress Developer & Product Manager at Kiwistic. I build and maintain WordPress sites for small businesses and troubleshoot everything from login lockouts to security issues. These guides come from real experience, so you don't have to figure it out alone.

You May Also Like…