πŸ› οΈ Fixing (HTTP ERROR 500) PHP Website Blank / White Page / Internal Server Error

For cPanel + CloudLinux + LiteSpeed + Webuzo


πŸ“– Introduction

Seeing a white page or HTTP 500 Internal Server Error when visiting your PHP website means that something is brokenβ€”but PHP is hiding the error output by default. This is common in hosting setups that use cPanel, CloudLinux, LiteSpeed, or Webuzo, where errors are logged rather than displayed.

πŸ” Common Causes:

  • PHP memory limit exhausted
  • Incompatible or missing PHP modules/extensions
  • Syntax or runtime errors in scripts
  • Corrupt or blank index.php or .htaccess
  • Wrong PHP version or handler
  • File permission or ownership issues

πŸ” Step-by-Step Troubleshooting

πŸ“ 1. Locate PHP Error Logs

βœ… cPanel (No PHP-FPM):

/home/$cpuser/public_html/error_log

βœ… cPanel with PHP-FPM (CloudLinux default):

/home/$cpuser/logs/

βœ… LiteSpeed (if integrated with cPanel):

Also check:

/usr/local/lsws/logs/error.log

βœ… Webuzo:

Logs may be in:

/var/webuzo/users/$cpuser/webapps/$domain/error_log

πŸ“Ÿ 2. Monitor Logs in Real-Time

Run the following to catch the error while reloading the site:

tail -f -n0 /home/$cpuser/public_html/error_log

If using PHP-FPM:

tail -f /home/$cpuser/logs/php-fpm/error.log

If using LiteSpeed global log:

tail -f /usr/local/lsws/logs/error.log

πŸ§ͺ 3. Temporarily Show Errors On-Screen

For debugging only, add this at the top of index.php or the problematic file:

ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);

⚠️ Never leave these on in production.


βš™οΈ 4. Check PHP Configuration

cPanel & CloudLinux:

Use selectorctl to check or change user PHP settings:

selectorctl --get-current --user=$cpuser

List available versions:

selectorctl --list-available

Change version for a user:

selectorctl --set-user-current=8.1 --user=$cpuser

Check and enable missing PHP extensions:

Via CLI:

selectorctl --enable-extensions=mbstring,pdo,mysqli --user=$cpuser

Or via cPanel > Select PHP Version GUI.


🧱 5. File and Permission Checks

  • Ensure PHP files are 644 and directories are 755
  • File ownership should match the cPanel user: chown -R $cpuser:$cpuser /home/$cpuser/public_html

πŸ“‘ 6. Fix .htaccess and Routing Issues

  • Rename .htaccess temporarily: mv /home/$cpuser/public_html/.htaccess /home/$cpuser/public_html/.htaccess.bak
  • If the error disappears, regenerate .htaccess from CMS settings (e.g., WordPress Settings > Permalinks).

🚫 7. Fix Memory Limit / Timeout / Execution Issues

Edit .user.ini or use MultiPHP INI Editor (cPanel) to increase values:

memory_limit = 512M
max_execution_time = 120

To reload PHP-FPM:

/scripts/restartsrv_apache_php_fpm

For LiteSpeed:

/usr/local/lsws/bin/lswsctrl restart

🧰 8. Webuzo-Specific Tips

Webuzo panel has its own error_log location per app:

/var/webuzo/users/$cpuser/webapps/$app/error_log

Also check Webuzo PHP settings via:

Webuzo Admin Panel > Server Settings > PHP Settings

Or use the terminal:

php -v
php -m

βœ… Final Checklist

CheckDescription
βœ… LogsError appears in error_log
βœ… PHP VersionCompatible with your app
βœ… ModulesRequired extensions enabled
βœ… MemorySufficient memory limit
βœ… PermissionsCorrect ownership and chmod
βœ… .htaccessValid and uncorrupted
βœ… SyntaxNo PHP code errors

πŸ“ Conclusion

HTTP 500 or blank PHP pages are almost always due to server-side misconfigurations or suppressed fatal errors. Using this guide across cPanel, CloudLinux, LiteSpeed, and Webuzo, you should be able to identify the exact issue quickly.

Scroll to Top