New 24/7 monitoring and daily cloud backups now included in every Shield Pro plan.

HTTP 500

How to fix a WordPress 500 internal server error

HTTP 500 is a generic server failure. WordPress, Apache, nginx, or PHP crashed before sending a useful page. This tutorial shows how to read logs, fix .htaccess, and isolate plugin conflicts on UK hosting.

Time: 20-45 minutes Level: Intermediate

What this problem looks like

A 500 error means the web server encountered an unexpected condition. On WordPress sites the cause is usually a bad .htaccess rule, PHP fatal error, memory limit, or incompatible plugin after an update.

Unlike a white screen, some hosts show a generic 500 page. You still need server logs to find the real message. Start with .htaccess and logs before reinstalling WordPress.

Back up .htaccess before editing. A malformed rewrite rule can 500 the entire site including wp-admin.

Step 1: Find the real error in server logs

Log into hosting and open Error Log or Raw Access. Search for entries at the time you saw the 500. Look for PHP Fatal error, mod_security block, or AH01071 lines on Apache.

  • cPanel: Metrics → Errors or File Manager → error_log in site root.
  • Plesk: Logs for the domain.
  • Managed WordPress hosts: Application or PHP logs in the dashboard.

Step 2: Test with a default .htaccess

Corrupt or plugin-added rewrite rules are a frequent cause. Rename .htaccess to .htaccess.old via FTP. If the site loads, the problem is in rewrite rules.

apache
# 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
After restoring .htaccess, visit Settings → Permalinks in wp-admin and click Save to regenerate rules cleanly.

Step 3: Enable debug mode in wp-config.php

If logs point at PHP, enable WordPress debug logging:

php
define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true );
define( 'WP_DEBUG_DISPLAY', false );

Step 4: Deactivate plugins and switch theme

Rename wp-content/plugins to plugins.disabled. If the 500 clears, move folders back one at a time. If not, rename the active theme folder in wp-content/themes/ and confirm a default theme exists.

Step 5: Raise PHP limits in hosting

500 errors often follow memory exhausted or maximum execution time messages. In hosting PHP settings, raise memory_limit and max_execution_time. You can also set WordPress memory in wp-config.php:

php
define( 'WP_MEMORY_LIMIT', '256M' );
define( 'WP_MAX_MEMORY_LIMIT', '512M' );

When to stop DIY and hire help

If the 500 persists after .htaccess reset and full plugin isolation, the issue may be server configuration or corrupted core files. BugShield fixes 500 errors at a confirmed price without hourly billing surprises.

FAQs

Why does only one page return 500?

A single page may hit a plugin shortcode or custom template that fatals. Check debug.log while loading that specific URL.

Can Cloudflare cause a 500 error?

Cloudflare shows 500 when your origin server fails. Fix the origin first. SSL mode mismatches can also cause loops that look like server errors.

Should I delete .htaccess?

Rename it instead of deleting. You can restore permalinks from wp-admin once the site loads.

How do I fix 500 after installing a plugin?

Rename that plugin folder in wp-content/plugins/ via FTP. Then update or replace the plugin before reactivating.

Rather someone else fixed it?

Request a fix at a confirmed price. Named UK developer, secure Vault, direct chat.

Request a Fix