So, you have built a WordPress business website that is not running so smoothly now.
Do you often find yourself Googling phrases like “WordPress issue tracking” or “how to fix WordPress issues?”
If yes, then we might just have the panacea you seek!
We at Mavlers have delivered 5,000+ WordPress projects to 3,000+ clients globally and have the requisite expertise and experience to build WordPress-based websites that perform! Interestingly, we are also a WP VIP Silver Agency Partner.
In today’s blog, we will explore the top 10 WordPress errors and their solutions.
By the end of this blog, you will be able to identify and fix WordPress errors that are quite common yet fixable.
1. The White Screen of Death (WSOD)
The White Screen of Death (WSOD) is one of the most frustrating errors you can encounter in WordPress. When it occurs, your website displays nothing but a blank white screen, with no error message or indication of what went wrong. This error can affect your entire site or just specific pages.
Cause:
A faulty plugin or theme often causes WSOD. Exhausted memory limits or a corrupted file can also trigger it. The lack of an error message makes this issue particularly challenging to diagnose.
How to troubleshoot:
- Disable all plugins: The first step in troubleshooting WSOD is to disable all your plugins. You can do this by accessing your site via FTP or your hosting control panel’s file manager. Rename the plugins folder in wp-content to something like plugins_old. This will deactivate all plugins. Check your site to see if the error is resolved. If it is, you can narrow down the problematic plugins by reactivating them one by one.
- Switch to a default theme: If disabling plugins doesn’t fix the issue, the problem may lie with your theme. Access your site files and rename the active theme folder in wp-content/themes to something like theme_old. WordPress will automatically switch to a default theme, such as Twenty Twenty-Three. If your site starts working, you know the theme was the issue.
- Increase PHP memory limit: If the WSOD persists, it might be due to an exhausted PHP memory limit. You can increase the memory limit by adding the following line to your wp-config.php file:
define(‘WP_MEMORY_LIMIT’, ‘256M’);
This increases the memory limit to 256MB, which should be sufficient for most websites.
2. Error establishing a database connection
When you see the “Error Establishing a Database Connection” message, it means that your WordPress site is unable to communicate with its database. This is a critical error, as WordPress relies on the database to store all your content, settings, and user data.
Cause:
This error can be caused by incorrect database credentials in your wp-config.php file, a corrupted database, or server-related issues such as the MySQL server being down.
How to troubleshoot:
- Check database credentials: The first thing to check is whether your database credentials are correct. Open your wp-config.php file and verify the following lines:
define(‘DB_NAME’, ‘your_database_name’);
define(‘DB_USER’, ‘your_database_user’);
define(‘DB_PASSWORD’, ‘your_database_password’);
define(‘DB_HOST’, ‘localhost’); // This is usually ‘localhost’, but it can vary.
Make sure that the database name, user, password, and host are correct. You can confirm these details with your hosting provider.
- Repair the database: If your credentials are correct, the issue might be a corrupted database. WordPress has a built-in repair feature that you can enable by adding the following line to your wp-config.php file:
define(‘WP_ALLOW_REPAIR’, true);
After adding this line, go to yoursite.com/wp-admin/maint/repair.php to access the repair page. Follow the on-screen instructions to repair your database.
- Contact your hosting provider: If the above steps don’t resolve the issue, it’s possible that the problem lies with your hosting provider. The MySQL server might be down, or there could be a server configuration issue. Contact your hosting support for assistance.
3. 404 error on posts
A 404 error occurs when a specific page on your website cannot be found. This error is common when trying to access individual posts while the rest of your site functions normally.
Cause:
The most common cause of this issue is incorrect permalink settings. It can also be due to a missing or corrupted .htaccess file.
How to troubleshoot:
- Re-save permalink settings: To fix this, go to Settings > Permalinks in your WordPress dashboard and click “Save Changes” without making any modifications. This simple action often resets the permalinks and resolves the issue.
- Update .htaccess file: If re-saving the permalinks doesn’t work, you might need to update your .htaccess file. Access your site via FTP and add the following code to the .htaccess file in the root directory:
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ – [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
4. Internal Server Error (500 Error)
The Internal Server Error (500 Error) is a generic error that indicates something has gone wrong on the server, but the server is unable to specify the exact problem.
Cause:
This error can be caused by a corrupted .htaccess file, an exhausted PHP memory limit, or a faulty plugin.
How to troubleshoot:
- Check .htaccess File: The first step is to check if the .htaccess file is corrupted. Access your site files via FTP and rename the .htaccess file to .htaccess_old. Reload your site to see if the error is resolved. If it is, go to Settings > Permalinks in your WordPress dashboard and click “Save Changes” to generate a new .htaccess file.
- Increase PHP memory limit: If the .htaccess file isn’t the issue, try increasing the PHP memory limit by adding the following line to your wp-config.php file:
define(‘WP_MEMORY_LIMIT’, ‘256M’);
- Deactivate plugins: If increasing the memory limit doesn’t work, deactivate all plugins by renaming the plugins folder via FTP. Then, reactivate them one by one to identify the problematic plugin.
5. Stuck in maintenance mode
WordPress automatically enters maintenance mode when performing updates. However, if an update fails or is interrupted, your site can become stuck in maintenance mode, displaying the message, “Briefly unavailable for scheduled maintenance. Please check back in a minute.”
Cause:
The .maintenance file, which is created during updates, is not deleted automatically after the update completes.
How to troubleshoot:
- Delete .maintenance File: Access your site via FTP and delete the .maintenance file in the root directory. This will immediately restore your site.
- Clear browser cache: If your site still appears to be in maintenance mode, try clearing your browser cache or accessing your site from a different browser.
6. Memory exhausted error
The Memory Exhausted Error occurs when a WordPress script exceeds the server’s allocated memory limit. When this happens, you’ll see an error message similar to “Fatal error: Allowed memory size of x bytes exhausted.”
Cause:
This error is usually caused by a plugin or theme that requires more memory than is currently allocated.
How to troubleshoot:
- Increase memory limit: The most straightforward solution is to increase the PHP memory limit. Add the following line to your wp-config.php file:
define(‘WP_MEMORY_LIMIT’, ‘256M’);
- Check for heavy plugins: Some plugins are more resource-intensive than others. If increasing the memory limit doesn’t resolve the issue, try disabling plugins that might be consuming a lot of memory.
7. Sidebar below content error
This error occurs when your website’s sidebar unexpectedly shifts below the main content area instead of appearing alongside it.
Cause:
The Sidebar Below Content Error is typically caused by HTML or CSS issues, such as unclosed tags or improper width settings in your theme’s stylesheet.
How to troubleshoot:
- Check for unclosed HTML tags: Inspect the affected page’s HTML code for any unclosed tags. Unclosed tags can disrupt the layout and cause the sidebar to drop below the content.
- Adjust CSS widths: If the HTML code is clean, the issue might be with your theme’s CSS. Ensure that the widths of your content and sidebar are correctly defined and that their combined width does not exceed 100% of the container.
8. Connection timed out
A “Connection Timed Out” error occurs when your site takes too long to load, causing the server to stop waiting and time out.
Cause:
This issue is often caused by an overloaded server, poorly optimized plugins, or insufficient server resources.
How to troubleshoot:
- Increase memory limit: A quick fix is to increase the PHP memory limit by adding the following line to your wp-config.php file:
define(‘WP_MEMORY_LIMIT’, ‘256M’);
- Optimize plugins: Deactivate plugins that might be causing high server loads, especially resource-intensive ones like backup or security plugins.
- Upgrade hosting plan: If your site regularly experiences timeouts, it might be time to upgrade your hosting plan to one that offers more resources.
9. Locked out of WordPress admin
Being locked out of the WordPress admin area can be a nerve-wracking experience, especially if you can’t access your dashboard to manage your site.
Cause:
This issue can be caused by incorrect login credentials, a forgotten password, or even a security plugin blocking access due to too many failed login attempts.
How to troubleshoot:
- Reset password via phpMyAdmin: If you’ve forgotten your password, you can reset it via phpMyAdmin. Access your database and locate the wp_users table. Find your username, edit the entry, and replace the password with a new one using MD5 encryption.
- Disable security plugins: If a security plugin is blocking your access, you can disable it by renaming the plugin’s folder via FTP.
10. Image upload issues
Image upload issues in WordPress can manifest in several ways, such as images failing to upload, appearing as broken links, or displaying incorrectly on the front end.
Cause:
Incorrect file permissions, insufficient memory, or a conflict with a plugin or theme often cause these issues.
How to troubleshoot:
- Check file permissions: Ensure that the wp-content/uploads folder has the correct file permissions. It should be set to 755 or 775. You can change these permissions via FTP or your hosting control panel.
- Increase PHP memory limit: If the issue persists, try increasing the PHP memory limit by adding the following line to your wp-config.php file:
define(‘WP_MEMORY_LIMIT’, ‘256M’);
- Disable plugins: If image upload issues start after installing a new plugin, try disabling it to see if the problem resolves.
The road ahead
You might now want to read Why Does WordPress Get Hacked? What Steps/Measures Does Mavlers Take To Prevent It?
Naina Sandhir - Content Writer
A content writer at Mavlers, Naina pens quirky, inimitable, and damn relatable content after an in-depth and critical dissection of the topic in question. When not hiking across the Himalayas, she can be found buried in a book with spectacles dangling off her nose!
Mavlers' Link Building Success: What KPIs You Should Expect?
Top 10 CRM Reports You Should Be Using Right Now!