How to Fix the 500 Internal Server Error on Your WordPress Website

Posted on March 29, 2016 by in Tips & Tricks | 24 comments

How to Fix the 500 Internal Server Error on Your WordPress Website

The 500 internal server error runs on every page of your site when there’s a problem with the server or file system that’s powering your site. The cause most likely occurs in the root directory, where your WordPress files are, but it can also be caused by a problem on your host’s server.

This is one of the most frustrating errors that can occur in WordPress. It never has a straightforward solution, requiring a lot of troubleshooting that can eat up your time and patience. But we’re going to try to help alleviate some of that stress by suggesting several solutions to this problem and walking you through each.

Let’s get started.

How to Fix the 500 Internal Server Error on Your WordPress Website

Subscribe To Our Youtube Channel

Backing Up Your Site

These solutions require making a lot of changes in your site’s root directory. It’s highly recommended you backup your site prior to trying any of these solutions in case something goes wrong. Here are some resources we have that can help you with this important first step:

Using an FTP Client

If you already have experience using an FTP client, skip this section. I’m going to go over how to set up an FTP client for those who have never used one as most of these solutions require it.

An FTP client allows you to access and edit your site’s files. You can use the File Manager your host uses, of course, but an FTP client of your choosing is often easier to use.

http error 500

There are many FTP clients, but we’re going to use FileZilla for the purpose of this demonstration. Go to FileZilla’s homepage, and click Download FileZilla Client.

Click the green Download FileZilla Client button if the site is recommending your exact operating system. If it’s not, click the Show Additional Download Options link beneath the green button and download the version that’s appropriate for your operating system.

Open the client once you’ve downloaded the installer and have installed it on your system. Click File > Site Manager. Click New Site, and enter your site’s name.

error 500

Configure these settings:

  • Host – Your domain name
  • Port – Leave blank
  • Protocol – FTP – File Transfer Protocol
  • Encryption – Only Use Plain FTP
  • Logon Type – Normal

Use the username and password you use to access your host’s file manager. If your host uses cPanel, use the login information you use to access cPanel. If you’re not sure, ask your host.

Go to the Transfer Settings tab, and select the checkbox for Limit Number of Simultaneous Connections. Set the Maximum Number of Connections to 8. This keeps your site’s server from blocking your IP address. Click Connect to connect to your site’s server.

You’re ready to go!

Common Solutions for the 500 Internal Server Error

The two most common causes of this error are a corrupted .htaccess file and exceeding your server’s PHP memory limit. The .htaccess file in your WordPress directory can become corrupted after you install a plugin or make another change to your WordPress site. The fix is simple. All you need to do is create a new .htaccess file.

PHP memory limit issues often occur as the result of a poorly-coded plugin running on your site or a site that’s grown considerably over time and is using too many plugins. You’ll begin to exceed the PHP memory limits set by your hosting provider once either of these things happen. The result is a 500 internal server error.

We’re going to learn how to create a new .htaccess to get rid of the corrupted one as well as how to test whether or not you’re exceeding your PHP memory limits.

Creating a New .htaccess File

Open your WordPress root directory in FileZilla or your preferred FTP client. This is typically called public_html. If you see folders named wp-admin and wp-content, you’re in the right place. If you don’t see your .htaccess file or any dotfiles, make hidden files viewable by clicking Server and selecting Force Showing Hidden Files.

500 Internal Server Error Fix

Once you find your .htaccess file, right-click it, and rename it “.htaccess.bak”. This essentially deletes your site’s .htaccess file, so we need to create a new one. Go into your WordPress admin area. Hover over Settings, and select Permalinks. Scroll down to the bottom of the page, and click Save Changes.

Open your website in your browser. If the 500 internal server error is gone, it was caused by a corrupted .htaccess file and your issue is now fixed. If you’re still seeing the error, you have some more tests to run.

It’s also worth mentioning that an improperly named .htaccess file will cause this error to run on your site. Make sure this file is not named anything other than “.htaccess”.

Increasing Your PHP Memory Limit in WordPress

PHP memory limits are set by your host and WordPress. WordPress will attempt to increase your limit if you begin exceeding it, but it can only go as high as the limit your host has placed on your server. This limit is often lower for shared hosting plans. You need to increase your PHP memory limit in WordPress and refresh your site to test whether or not this is causing your 500 internal server error.

500 Internal Server Error Fix

Open your root directory, and locate your wp-config.php file. Right-click on the file, and select Download to download it to your computer. Open the file in your preferred text editor, and add this bit of code under the opening PHP tag:

define('WP_MEMORY_LIMIT', '64M');

Save the file, and re-upload it to your root directory, overwriting the original file. Refresh the client, and refresh your site. If you still see the error, you are not having PHP memory limit issues. Remove the above code from the wp-config.php file on your computer, save it, and re-upload it to your root directory.

Don’t get too excited if you don’t see the error. You still have some work to do.

Increasing your site’s PHP memory limit in the wp-config.php file is the equivalent of pouring bleach down your kitchen sink when it smells like rotten eggs. You’re fixing the problem well enough to get rid of the offensive odor, but you’re not fixing the bigger issue at hand, which is likely a clog somewhere in the pipes that lead to your sink.

The same is true with increasing your site’s PHP memory limit. You may have increased it yourself in the file, but something is still exhausting your limit. You can follow the steps in the next few sections to try and find out what that might be, but if worst comes to worst, you’ll likely need to convince your host to increase the limit on your server.

Less Common Solutions for the 500 Internal Server Error

Fixing a corrupted .htaccess file and increasing a site’s PHP memory limit are the top two solutions for fixing this error, but there are other solutions if those haven’t helped you.

They are as follows:

  • Deactivating plugins to check for faulty plugins.
  • Locating issues by debugging your site.
  • Checking if your files and folders have the correct file permissions.
  • Uploading fresh wp-content and wp-includes folders to your site.
  • Asking your host if the issue is on the server that powers your site.

Deactivating Plugins

500 Internal Server Error Fix

If you’re able to access the WordPress admin area, deactivate your plugins one by one. Refresh your site after each deactivation. If the error disappears, it was likely caused by the plugin you deactivated prior to refreshing.

Delete the plugin and find a replacement if its function is important for your site. If you don’t feel you can replace the plugin, contact the developer directly. You can do this within the plugin’s support forum on, but I recommend doing a bit of research to see if the developer offers support elsewhere.

If you cannot access the WordPress admin area, open your FTP client. Open the root directory, and open the wp-content folder. This folder contains your Plugins, Themes and other folders.

500 Internal Server Error Fix

Rename the Plugins folder to anything you wish, such as “plugins.test”. This deactivates all of the plugins on your site. Refresh your site. If the error is gone, it was caused by a faulty plugin. Activate each plugin one by one, refreshing your site after each activation, to find out which plugin is causing the error.

Make sure you rename the folder back to “Plugins” afterward.

Debugging Your WordPress Website

500 Internal Server Error Fix

If you’re having trouble figuring out what’s causing this error to run on your site, you may want to use WordPress’ built-in debugging feature. Pasting a bit of code into your site’s wp-config.php file enables debugging on your site. Any errors found are recorded in a file in your directory.

Josh Pollock wrote a post on how to use this feature in WordPress a while back. If you’re a developer, go ahead and start debugging your site. If you’re an average site owner, you may want to sit this one out as you may not know the difference between a minor error that can be safely ignored and a major error that should be taken care of promptly.

Normally, debugging a live site is frowned upon as it may reveal essential code to site visitors, among other things. However, it may be the only thing that explains what might be causing the 500 internal server error to run on your site.

Checking File Permissions

500 Internal Server Error Fix

This likely isn’t the issue, but it’s still worth checking. In your WordPress directory, permissions for folders and files should be 755 or 644. Setting permissions to anything else may cause problems, including 500 internal server errors.

Open your root directory in an FTP client. Many clients, including FileZilla, have a Permissions tab you can use to quickly check the permissions for each file and folder in your root directory. Make sure these are not set to anything other than 755 or 644.

Uploading Fresh Versions of wp-admin and wp-includes to Your Site

This step should be a last resort, but if you’ve used the above solutions and still cannot find one that works, it’s worth a try. Backup your site, and download a fresh version of WordPress from the main site.

500 Internal Server Error Fix

Extract the files from the ZIP file, and open the extracted folder. Open your site’s root directory in an FTP client, and upload the wp-admin and wp-includes from your fresh version of WordPress to your site’s directory, overwriting the older versions.

Refresh the client, and refresh your site. If the error is gone, it was likely caused by a corrupted core file. If you still see the error, you may have no other option than to contact your host.

Contacting Your Host

If you’ve gone through all of these steps and still cannot find a solution, your host may have it. It is, however, important that you go through these steps to ensure the issue is not occurring in your root directory.

The quality of the support you receive differs between hosts, but many hosts may shrug the issue off and blame your site’s files rather than their servers. This isn’t out of the question as third-party plugins and themes do cause plenty of issues that are out of your host’s hands.

So, it’s important that you go through all of these steps so you can explain to them that you’ve checked every nook and cranny of your file system and can’t find a single issue that would lead to the 500 internal server error that’s running on your site.

Politely ask them to check their server logs to see if the issue is there.

Final Thoughts

The 500 internal server error is a frustrating issue as it doesn’t always have a clear cause or a clear solution. It requires a lot of troubleshooting, as you’ve learned, but I hope these steps have at least made the task a little less irritating.

All in all, make sure you back up your site on a regular basis and update your plugins, themes, and WordPress core files as soon as they’re available. A great way to prevent this issue is to ask your theme’s developer whether or not their theme or an update to their theme is compatible with the plugins you’re running on your site as this may corrupt your .htaccess file.

Lastly, make sure you upgrade your hosting package accordingly. This error is most likely to occur on a small-budget shared hosting server, so it’s important for you to begin researching other options so you can move your site to a server capable of handling your growing site.

Have you ever had this issue? Share your experience in the comments!

Article thumbnail image by Fireofheart /

Premade Layouts

Check Out These Related Posts

Splice Video Editor: An Overview and Review

Splice Video Editor: An Overview and Review

Posted on May 7, 2019 by in Tips & Tricks

Video is a valuable form of content for social media. Unfortunately, creating quality videos is usually a long process that involves moving mobile footage to a desktop app for editing. However, mobile editing is on the rise. Apps such as Splice Video Editor make it possible to efficiently create...

View Full Post


  1. Very good tutorials. Have to bookmark this! Thank you

  2. Using the default WordPress htaccess works like charm every time. Thanks for the tutorial;)

  3. It is impossible to go to the WordPress admin area to ‘save changes’ for permalinks if you are experiencing a 500 error.

    I think a reasonable addendum would be to create an empty (or minimal) .htaccess file via the ftp tool.

    “Once you find your .htaccess file, right-click it, and rename it “.htaccess.bak”. This essentially deletes your site’s .htaccess file, so we need to create a new one. Go into your WordPress admin area. Hover over Settings, and select Permalinks. Scroll down to the bottom of the page, and click Save Changes.”

  4. Excellent! One of those thinks we need to have near at the problema time.
    Thanks to share it.

  5. Thank you. What are your thoughts on intermittent 500 errors? There are two sites with different themes and both experience it. I was going to request that the host move us to a different server or change hosts altogether since there’s a speed issue too.

    I’ve done the plugin thing, but haven’t created a new htaccess.

    • If the 500 errors are intermittent my guess is that the websites are exceeding the allowable memory limit set by your web host. This is particularly true of shared web hosting where resources are shared among website accounts.

      If you have access to your website log files, look for something along the lines of “Premature end of script headers”. That’s likely a sign that a task was killed by your web host because it was using too many resources. The front-end result is usually a 500 error.

  6. Great post! I’d add a note in the beginning to look at the web server and PHP error logs first. They’ll probably point you in the direction of which fix needs to be applied.

  7. thanks, good article.
    from my experience. Highest on the possible causes internal error 500 is conflict plugin, excessive resource usage on a shared hosting

  8. What if my website is hosted at cloud like flywheel with SFTP. In my case, i know the issue is caused by syntax error in my functions.php file. However to access the funstions.php file in cloud hosting is challenging for someone new to cloud hosting like me.

  9. But most commonly this error occurs if you are using a lot of plugins.
    Anyways great tutorial! Thanks for sharing!

  10. Dealing with .htaccess was always scary for me and I’m looking forward to remove the error of ip canonicalization error. Can you please publish the solution for this error too?

  11. An excellent, comprehensive guide. Many thanks for that!

  12. Internal server error is most common error while designing or developing any new content or page on a website while working on enterprise web content management services. Not only WordPress, this happens to every web development solutions like Drupal, Sitefinity, Umbraco etc. The major reason behind this is passing an element not supported by the server or due to missing file on server. While in development phase, ensure that all the necessary server files are uploaded and does not contain any broken or unwanted code. To identify the type of error, check the error logs for your server. It can provide valuable context related to any code failures or other potential causes of a site failure. Double check the .htaccess configuration, any syntex error will result in server error. PHP script makes external network connections, this connections may time out which is another cause of server error thus it is advisable to remove external connections.

  13. Does defining memory limit will cause effect other services, What is the max. memory we can use >

  14. Thank you so much for this. I get the 500 error with every single page load and it’s infuriating!! I know it’s due to my iThemes plugin because if I deactivate it, the problem goes away (on both sites). I even have to disable the plugin just to create a post on my blog. Does anyone know if it will work after I crate a new .htaccess file???

  15. I get the 520 and 504 error message fairly often with one of my sites, especially if I am making lots of changes. I am assuming this is similar to the 500 error??

    I have done the .htaccess trick above, and noticed that now I have:
    * .htaccess
    * .htaccess (wordpress).txt
    * .htaccess-new
    * .htaccess.bak

    Should I delete any of these? Is this what is causing my error messages?

    I also have some file permissions as 600. how do I know if I should change them to 755 or 644?

  16. You are a life saver, exactly what I needed to fix my site. Thanks so much for this.

  17. Thanks a lot.I fix my 500 Inter Server Error with this tutorial.

  18. tank’s for this amazing post. but i have one problem, in google webmaster i have a error 500 for theme directory. How i can solve it?

  19. Hello to all pls am having similar issues I can’t access wp-admin after logging into my WordPress blog

  20. Solved the problems with a few of my sites after moving server. Thanks!

  21. Hi, thanks for sharing this tutorial. I already solved 4 webpage with 500 error on my website. however, can you make another tutorial on redirection error? deeply appreciated. Thank you.


  23. In case this helps anyone… I had a similar problem in that one day the post content and sidebar wasn’t showing in any of my single post pages (it would only show the post title and featured image). The admin toolbar at the top also wasn’t showing on those pages. Upon closer inspection, I saw there was a 500 internal server error saying that the specific post page couldn’t be retrieved.

    After backing up my site, updating my plugins, theme, and WP version, then deactivating each plugin individually and re-checking, it turned out that the culprit was the “Ultimate Social Media Plus” plugin. Everything showed up normally after I deactivated it. Glad it was a simple solution and nothing too crazy!

Join To Download Today

Pin It on Pinterest