Ultra Web Hosting Docs

500 Internal Server Error

A 500 Internal Server Error is the server's way of saying something went wrong but it cannot tell you exactly what on the page itself. The real cause is almost always in your error log. This guide walks you through the usual suspects and how to fix each one.

Common Causes

Nearly every 500 error on a shared hosting account comes down to one of these:

Step 1: Check the Error Log

Always start here. The error log tells you the exact file and line that failed, which usually points straight at the cause.

  1. Log into cPanel.
  2. Go to Metrics > Errors to see the most recent errors.
  3. Reproduce the error by visiting the broken page, then refresh the log.
  4. Read the newest entries from the bottom up — look for words like PHP Fatal error, Allowed memory size, or Invalid command.
Tip The error log gives you the file path and line number. Even if the message looks cryptic, that path tells you whether the problem is in a plugin, a theme, or your own code.

Step 2: Test Your .htaccess File

A corrupt or incompatible .htaccess is the single most common cause of a 500 error. To rule it out, rename it so the server ignores it.

  1. Open File Manager in cPanel and browse to public_html.
  2. Enable Show Hidden Files (dotfiles) from the Settings menu if you cannot see .htaccess.
  3. Rename .htaccess to .htaccess.bak.
  4. Reload your site. If it works now, the problem was in that file.
  5. For WordPress, regenerate a clean copy by going to Settings > Permalinks and clicking Save Changes.

For a deeper look at the rules that belong in this file, see our .htaccess guide.

Step 3: Raise the PHP Memory Limit

If the log shows Allowed memory size exhausted, your script needs more memory. You can raise the limit from cPanel.

  1. In cPanel, open MultiPHP INI Editor.
  2. Select your domain from the dropdown.
  3. Set memory_limit to a higher value, such as 256M.
  4. Click Apply and reload your site.
Note Raising the memory limit treats the symptom, not the cause. If a plugin needs an unusually large amount of memory, it may have a bug or a runaway query. Watch your resource usage after making this change.

Step 4: Rule Out a Plugin or Theme

If you are running WordPress and the error started after an update or a new install, a plugin or theme is the likely culprit. You can deactivate all plugins at once without logging in.

  1. In File Manager, browse to public_html/wp-content.
  2. Rename the plugins folder to plugins-off.
  3. Reload your site. If it loads, a plugin was the cause.
  4. Rename the folder back to plugins, then rename each plugin subfolder one at a time to find the offender.
  5. If plugins are not the cause, switch to a default theme such as Twenty Twenty-Four to rule out the theme.

For a full recovery walk-through, see WordPress White Screen of Death.

Step 5: Check File Permissions

Web servers refuse to run files with unsafe permissions. The standard, safe values are:

Avoid 777 on anything — it is a security risk and some servers will return a 500 error for scripts set that way. You can fix permissions in File Manager by right-clicking a file, choosing Change Permissions, and setting the correct value.

Warning Do not set files or folders to 777 to "make it work." This opens your site to attackers and is rarely the real fix. Stick to 644 for files and 755 for directories.

Still Stuck?

If you have worked through every step and still see a 500 error, open a support ticket. Include the domain, the exact page that fails, and the most recent lines from your error log so we can pinpoint the cause quickly.