Cos’è l’errore 500 (Internal Server Error)

L’errore 500 indica che il server non ha potuto completare la richiesta. In WordPress, le cause più frequenti riguardano plugin/temi, .htaccess, limiti PHP o funzioni deprecate.

Esempi di log (anonimizzati)

Questi estratti mostrano pattern comuni. I percorsi e i domini sono stati anonimizzati.

[Sat Feb 08 12:03:17 2026] PHP Fatal error:  Uncaught Error: Call to undefined function get_magic_quotes_gpc() in /var/www/example/wp-content/plugins/old-plugin/init.php:42
Stack trace:
#0 /var/www/example/wp-settings.php(409): include()
#1 /var/www/example/wp-config.php(96): require_once('/var/www/exampl...')
#2 /var/www/example/wp-load.php(50): require_once('/var/www/exampl...')
#3 /var/www/example/wp-blog-header.php(13): require_once('/var/www/exampl...')
#4 /var/www/example/index.php(17): require('/var/www/exampl...')
thrown in /var/www/example/wp-content/plugins/old-plugin/init.php on line 42
[Sat Feb 08 12:05:02 2026] .htaccess: Invalid command 'php_flag', perhaps misspelled or defined by a module not included in the server configuration
[Sat Feb 08 12:06:45 2026] PHP Fatal error:  Allowed memory size of 134217728 bytes exhausted (tried to allocate 4096 bytes) in /var/www/example/wp-includes/class-wp-hook.php on line 310

Come intervenire

  • Abilita log e verifica l’errore preciso (file/linea).
  • Disattiva selettivamente plugin/tema sospetti.
  • Ripristina .htaccess standard WordPress.
  • Aumenta memory_limit e verifica funzioni deprecate.
  • Conferma la compatibilità della versione PHP.

Per panoramica generale vedi Risoluzione Problemi WordPress. Per incompatibilità PHP consulta Aggiornamento PHP WordPress.