Back to blog
WordPress 500 Error: Guide to Diagnose and Fix
WordPress

WordPress 500 Error: Guide to Diagnose and Fix

Bastien AllainMarch 11, 202614 min read
wordpress500-errortroubleshootingserverdebug

The 500 Internal Server Error is one of the most frustrating problems for WordPress site owners. Unlike client-side errors (404, 403), this error gives no clear indication of its cause. The server simply reports that it cannot process the request, without specifying why.

In 2026, nearly 35% of WordPress support tickets involve 500 errors in various forms. This guide walks you through a methodical diagnosis and provides 10 concrete solutions to restore your site quickly.

How to diagnose and fix a WordPress 500 error (8 etapes)
  1. 1

    Check server error logsAccess your hosting error logs to identify the exact failure point.

  2. 2

    Reset the .htaccess fileRename .htaccess and create a fresh default WordPress version.

  3. 3

    Increase PHP memory limitSet memory_limit to 256M in wp-config.php or php.ini.

  4. 4

    Deactivate all pluginsRename the plugins folder via FTP to rule out plugin conflicts.

  5. 5

    Switch to a default themeActivate Twenty Twenty-Five to check for theme-related errors.

  6. 6

    Re-upload WordPress core filesReplace wp-admin and wp-includes with fresh copies from wordpress.org.

  7. 7

    Check file permissionsSet folders to 755 and files to 644 on your server.

  8. 8

    Contact your hosting providerEscalate to support if server-side issues persist after all checks.

What Is a 500 Internal Server Error?

The 500 error is a generic HTTP response code indicating that the server encountered an unexpected condition that prevented it from processing the request. In simple terms, something broke on the server side, but the server does not know exactly what.

On WordPress, this error can appear in several ways:

  • A white screen with the message "500 Internal Server Error"
  • A blank page with no message (White Screen of Death)
  • A custom error page from your hosting provider
  • The error only on specific pages or in the admin area (/wp-admin)
  • Variations such as "HTTP 500", "HTTP Error 500", "Temporary Error (500)" or "Internal Server Error"

Important note: the 500 error is not WordPress-specific. It can affect any website. But the complexity of the WordPress ecosystem (core, plugins, themes, .htaccess file, MySQL database) multiplies the potential causes and makes diagnosis more challenging.

Quick Diagnostic Method: Where to Start?

Before testing each cause individually, follow this triage method that helps identify the source of the problem in minutes:

  1. Does the error affect the entire site or only certain pages?

    • Entire site: probably .htaccess, wp-config.php, or a server issue
    • Only /wp-admin: plugin conflict or PHP memory limit
    • A single page: faulty content or shortcode
  2. Did the error appear after a specific action?

    • After a plugin/theme update: deactivate that component first
    • After a code change: revert to the previous version
    • Without any particular action: check server logs and host status
  3. Do you have access to the WordPress dashboard?

    • Yes: deactivate plugins from the interface
    • No: use FTP or the hosting file manager
  4. Is your host reporting any incidents?

    • Check your hosting provider's status page before making any changes

This methodical approach prevents you from wasting time on leads unrelated to your problem.

The 10 Causes and Solutions for WordPress 500 Errors

1. Corrupted or Misconfigured .htaccess File

The .htaccess file is the number one culprit for 500 errors on WordPress. This Apache configuration file manages permalinks, redirects, and URL rewrite rules. A single malformed line is enough to trigger a 500 error.

Diagnosis:

Connect to your server via FTP (FileZilla, Cyberduck) or your hosting file manager. Locate the .htaccess file at the root of your WordPress installation.

Solution:

  1. Rename the .htaccess file to .htaccess_backup
  2. Create a new .htaccess file with the default content:
# 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
  1. Test your site. If the error disappears, the problem was indeed the .htaccess
  2. Regenerate permalinks from Settings > Permalinks in WordPress

2. PHP Memory Limit Exceeded

WordPress and its plugins consume PHP memory with each page load. When the allowed limit is reached, the server returns a 500 error. This is particularly common on shared hosting with low limits (64 MB or 128 MB).

Diagnosis:

Enable WP_DEBUG (see dedicated section) and look for messages like Fatal error: Allowed memory size of X bytes exhausted.

Solution:

Increase the PHP memory limit by adding this line to your wp-config.php file (before the line /* That's all, stop editing! */):

define('WP_MEMORY_LIMIT', '256M');

If your host allows it, you can also modify the php.ini file:

memory_limit = 256M

Or add this directive to .htaccess:

php_value memory_limit 256M

3. WordPress Plugin Conflicts

Plugin conflicts account for approximately 40% of 500 errors on WordPress. A poorly coded plugin, one incompatible with your PHP version, or one conflicting with another plugin can crash the server.

Diagnosis:

If you have access to the dashboard, deactivate all plugins at once. If the error disappears, reactivate them one by one to identify the culprit.

Solution via FTP (if the dashboard is inaccessible):

  1. Connect to your server via FTP
  2. Navigate to /wp-content/
  3. Rename the plugins folder to plugins_disabled
  4. Test your site: if the error disappears, a plugin is the cause
  5. Rename the folder back to plugins
  6. Rename each individual plugin folder to isolate the culprit
# Example structure
wp-content/
  plugins/
    suspect-plugin/     # Rename to suspect-plugin_disabled
    another-plugin/

After identification: update the plugin, replace it with an alternative, or contact its developer.

4. Theme Issues or Incompatibility

A WordPress theme can trigger a 500 error if its functions.php file contains a syntax error, if it is incompatible with your PHP version, or if it conflicts with a plugin.

Diagnosis:

Test by activating a default WordPress theme (Twenty Twenty-Four or Twenty Twenty-Five).

Solution via FTP:

  1. Navigate to /wp-content/themes/
  2. Rename your active theme folder (e.g., my-theme to my-theme_disabled)
  3. WordPress will automatically switch to an installed default theme
  4. If no default theme is installed, download one from wordpress.org and place it in /wp-content/themes/

If the problem comes from the theme, check:

  • Compatibility with your PHP version
  • Recent changes to functions.php
  • Available updates
  • Using a child theme for your customizations

5. Corrupted WordPress Core Files

WordPress core files can become corrupted during an interrupted update, an incomplete FTP transfer, or a malicious attack. Even a single altered file can trigger a 500 error.

Diagnosis:

Compare your installation files with a clean WordPress version. The WP-CLI tool makes this verification easy:

wp core verify-checksums

Solution:

  1. Download a fresh copy of WordPress from wordpress.org (the official documentation details the reinstallation process)
  2. Extract the archive
  3. Upload the wp-admin and wp-includes folders via FTP, overwriting existing files
  4. Do not touch the wp-content folder (your themes, plugins, and media) or the wp-config.php file

6. PHP Version Incompatibility

WordPress evolves regularly and requires increasingly recent PHP versions. Conversely, some older plugins or themes do not work with the latest PHP versions.

Diagnosis:

Check the PHP version used by your host. WordPress 6.x recommends PHP 8.1 or higher. From your dashboard: Tools > Site Health > Info > Server.

Solution:

  • If your PHP is too old: update it via your hosting control panel (cPanel, Plesk)
  • If a plugin or theme is not compatible with a recent version: contact the developer or find an alternative
  • Always test on a staging environment before changing the PHP version in production

7. File and Folder Permission Issues

Incorrect permissions on WordPress files and folders prevent the server from reading or executing them properly, which triggers a 500 error.

Recommended permissions for WordPress:

ElementPermissionOctal Value
FoldersRead + Execute755
FilesRead644
wp-config.phpRestrictive Read640 or 600

Solution:

Fix permissions via FTP or SSH:

# Fix folder permissions
find /path/to/wordpress/ -type d -exec chmod 755 {} \;
 
# Fix file permissions
find /path/to/wordpress/ -type f -exec chmod 644 {} \;
 
# Secure wp-config.php
chmod 640 /path/to/wordpress/wp-config.php

Warning: never set permissions to 777 (read, write, execute for everyone). This creates a major security vulnerability, as we explain in our WordPress security guide.

8. Errors in wp-config.php

The wp-config.php file contains your site's critical settings (database credentials, security keys, table prefix). A syntax error, incorrect parameter, or wrong database credentials will systematically trigger a 500 error.

Diagnosis:

Open wp-config.php via FTP and verify:

  • No characters before <?php or after ?>
  • Database credentials (DB_NAME, DB_USER, DB_PASSWORD, DB_HOST)
  • Straight quotes (not typographic quotes)
  • No blank lines at the end of the file

Solution:

// Check these lines first
define('DB_NAME', 'database_name');
define('DB_USER', 'database_user');
define('DB_PASSWORD', 'database_password');
define('DB_HOST', 'localhost');  // Sometimes 127.0.0.1 or a specific host

If in doubt, contact your hosting provider to confirm the database connection parameters.

9. Server-Side Causes

Some 500 errors do not come from WordPress but from the server itself:

  • Server overload: too many simultaneous visitors on shared hosting
  • MySQL database unreachable: the MySQL server is stopped or saturated
  • Server timeout: scripts take too long to execute
  • Apache/Nginx configuration issues: missing or misconfigured modules
  • Disk space full: the server has no more space to write temporary files

Solution:

Contact your hosting provider if the previous solutions did not work. Provide them with:

  • The exact time of the error
  • The actions that trigger it (specific page, dashboard, all pages)
  • Recent changes made
  • Error logs if you have access

10. Using WP_DEBUG for In-Depth Diagnosis

WP_DEBUG is the diagnostic tool built into WordPress. It displays detailed PHP errors that are normally hidden, allowing you to precisely identify the cause of the 500 error.

Activation:

Add or modify these lines in wp-config.php:

// Enable debug mode
define('WP_DEBUG', true);
 
// Log errors to a file
define('WP_DEBUG_LOG', true);
 
// Do not display errors on screen (recommended in production)
define('WP_DEBUG_DISPLAY', false);
 
// Display all PHP errors
@ini_set('display_errors', 0);

Errors will be logged to /wp-content/debug.log. Check this file to identify:

  • The exact file and line of the error
  • The error type (Fatal error, Parse error, Warning)
  • The responsible plugin or theme

Important: disable WP_DEBUG once diagnosis is complete to avoid exposing sensitive information.

Summary Table: Causes and Solutions

CauseTypical SymptomQuick FixDifficulty
Corrupted .htaccessError 500 on entire siteRename via FTPEasy
PHP memory limitError on heavy pagesIncrease in wp-config.phpEasy
Plugin conflictError after updateDeactivate all pluginsEasy
Incompatible themeFront-end errorSwitch to default themeEasy
Corrupted core filesRandom errorReinstall core via FTPMedium
Incompatible PHP versionError after PHP changeChange PHP versionMedium
File permissions403 or 500 errorFix via SSHMedium
wp-config.php errorError on entire siteCheck syntax and credentialsEasy
Server problemIntermittent errorContact hostVariable
Unidentified PHP errorNo clear messageEnable WP_DEBUGMedium

SEO Impact of the 500 Error: What Your Rankings Risk

A prolonged 500 error has direct consequences on your search engine rankings. Googlebot interprets 500 errors as a signal of a failing site. Here is what happens concretely:

  • Less than 24 hours: Google retries the crawl. Minimal impact if the error is resolved quickly
  • Between 24 and 72 hours: affected pages may be temporarily deindexed from search results
  • Beyond one week: Google reduces the crawl frequency of your site and your crawl budget is wasted on error pages

Monitor via Google Search Console:

  1. Open the Coverage (or Pages) report in Google Search Console
  2. Filter by error type "Server error (5xx)"
  3. Identify the impacted URLs and the date of first detection
  4. After fixing, use the URL Inspection tool to request reindexation

Expert tip: set up a monitoring tool like UptimeRobot or Pingdom to be alerted in real time whenever your site returns a 500 error. Every minute counts to limit the impact on your SEO.

Prevention Tips: Avoiding the 500 Error

Prevention is better than cure. Here are best practices to minimize the risk of 500 errors:

  • Regular updates: keep WordPress, your plugins, and your theme up to date following the best practices in our WordPress maintenance guide. Updates fix bugs and security vulnerabilities
  • Frequent backups: perform complete backups (files + database) before any major changes. Plugins like UpdraftPlus or BlogVault automate this process
  • Staging environment: test updates and changes on a test environment before applying them in production
  • Quality hosting: choose a reliable WordPress host with sufficient resources (memory, CPU, storage)
  • Proactive monitoring: use tools like UptimeRobot to be alerted immediately in case of downtime
  • Regular cleanup: remove unused plugins and themes, optimize your database

FAQ: Your Questions About WordPress 500 Errors

How do I quickly fix a 500 error on WordPress?

Start by renaming the .htaccess file via FTP, then deactivate all plugins by renaming the plugins folder. These two actions resolve the majority of cases. If the problem persists, enable WP_DEBUG to get a precise error message.

Does the 500 error affect my site's SEO?

Yes, if the error persists for more than a few hours. Googlebot interprets 500 errors as a signal of a failing site. After several unsuccessful attempts, Google may temporarily deindex the affected pages. Check the Coverage report in Google Search Console to identify impacted URLs and request reindexation after fixing.

What is the difference between a 500, 502, 503, and 504 error?

The 500 error indicates an undefined internal server problem. The 502 error (Bad Gateway) means an intermediary server received an invalid response. The 503 error (Service Unavailable) indicates the server is temporarily unavailable, often due to overload. The 504 error (Gateway Timeout) signals a timeout between servers. The 500 error is generally the most complex to diagnose because it provides no indication of the cause.

Can a 500 error be caused by hacking or malware?

Yes. A hacked WordPress site can display a 500 error if core files have been modified, if malicious code has been injected into functions.php or .htaccess, or if a backdoor consumes too many server resources. Verify the integrity of your files with wp core verify-checksums and check our guide on common WordPress bugs for deeper diagnosis.

What should I do if I cannot access the WordPress admin area?

If /wp-admin is inaccessible, use an FTP client (FileZilla, Cyberduck) or your hosting provider's file manager (cPanel, Plesk). Via FTP, you can rename .htaccess, deactivate plugins by renaming the /wp-content/plugins/ folder, switch themes, and enable WP_DEBUG in wp-config.php. SSH access and the WP-CLI tool offer additional options for advanced users.

How do I check WordPress error logs?

Enable WP_DEBUG_LOG in wp-config.php then check the /wp-content/debug.log file. You can also access server logs via cPanel (Metrics > Errors) or ask your hosting provider for access to Apache or Nginx error.log files.


The WordPress 500 error is rarely fatal. In the vast majority of cases, it can be resolved by identifying and correcting the underlying cause. Follow the systematic diagnostic method in this guide: .htaccess, plugins, theme, PHP, permissions, then server.

If you need professional assistance with maintaining and troubleshooting your WordPress site, discover our WordPress maintenance service for tailored support.

Related articles:

Related posts