WebGee DocsDocs
Development
Free migration + 30-day money-backSee how

Find your error log

Where PHP and Apache errors are written, and how to read them when a page returns a blank screen or a 500.

Find the errors behind a blank page or a 500 error. Applies to shared, reseller and Premium hosting.

The log is the difference between guessing and knowing. A 500 error page says nothing; the log names the file and line.

Where to look

LogLocationContains
Your site's PHP errorserror_log in the same directory as the scriptFatal errors, warnings, notices
Apache errors for the account~/logs/Server-level errors, permission failures
cPanel ErrorscPanel → ErrorsThe most recent entries, no SSH needed

The one you usually want is error_log in your document root, or in whichever subdirectory the failing script lives.

Read it

In File Manager, enable Show Hidden Files, then open error_log. The newest entries are at the bottom.

Over SSH:

tail -n 50 ~/public_html/error_log

# watch it live while reproducing the problem
tail -f ~/public_html/error_log

tail -f is the most useful: run it, trigger the error in a browser, and watch the entry appear. That removes any doubt about which entry corresponds to your problem.

What the entries mean

PHP Fatal error:  Uncaught Error: Call to undefined function foo()
in /home/user/public_html/wp-content/plugins/example/file.php:42

The file and line are the useful part. Here it is a plugin called example, line 42.

  • Fatal error — execution stopped. This is your blank page or 500.
  • Warning / Notice — logged but execution continued. Usually noise, unless they correlate with the problem.

If there is no error_log

  • PHP error logging is off for that directory. Enable it temporarily — see Enable error logging in a PHP script.
  • The error is not from PHP. A 500 caused by .htaccess or by file permissions appears in ~/logs/, not in error_log — see File and directory permissions.
  • You are looking in the wrong directory. Each directory gets its own error_log. Search for it: find ~ -name error_log.

Delete it when you are done

error_log grows without limit, and a site erroring on every request can produce a file large enough to fill your disk quota. Delete it once fixed — it is recreated when needed.

On this page

Hosted elsewhere?

Cloud Hosting

cPanel on NVMe storage, with LiteSpeed, free SSL and daily backups included.

See plansFree migration