If a theme conflict or a bug prevents you from accessing the WordPress dashboard, you can switch to a default WordPress theme by renaming the active theme's folder. This action restores access to the dashboard for a Site Administrator.
Before you begin
You will need:
Site Administrator access
Access to your website's files via an FTP client or a File Manager (such as the one provided in your hosting control panel)
Switch to a default theme via file management
Connect to your site's files using an FTP client or your hosting control panel's File Manager.
Navigate to the directory where your themes are stored:
wp-content/themes/.Locate the folder for your currently active theme.
Rename the active theme's folder to include
.oldat the end (for example, renametwentytwentyfourtotwentytwentyfour.old).Log in to your WordPress dashboard.
Note: Renaming the folder forces WordPress to recognize the current theme as missing. WordPress will then automatically fall back to the next available default theme.
Confirm the result
You can successfully log in to the WordPress dashboard.
The site displays a default WordPress theme (such as Twenty Twenty-Four).
The site remains online and accessible to visitors.
If you still cannot access the dashboard
If you still cannot access the dashboard after renaming the theme folder, the issue may be caused by a plugin conflict or a configuration error in your wp-config.php file.
Check for plugin conflicts: Navigate to
wp-content/and rename thepluginsfolder toplugins_old. This deactivates all plugins. If the dashboard becomes accessible, one of your plugins is causing the error.Verify site URLs: Ensure the
WP_HOMEandWP_SITEURLconstants in yourwp-config.phpfile are correct.
Limitations
Once you have regained access to the dashboard, you will need to create a new theme or reinstall your preferred theme to restore your site's original design. This procedure only provides a way to bypass a broken theme to regain administrative access.
