How to fix 500 Internal Server Error in WordPress?

How to fix the 500 Internal Server Error in WordPress?

Have you ever visited your WordPress site all of a sudden and you were welcomed with an 500 internal server error in WordPress?

Maybe it is happening to you right now:

fix-internal-server-error-wordpress-0-1

This is an intimidating error because just like anyone establishing an error, your site completely disappears,

But you don't have to worry too much about it. This error is fixable and change the data on your WordPress site is safe.

In this post you will learn:

What is an internal server error, and some reasons for it?
How can you fix internal server error in WordPress?

What does internal server error mean?

Internal Server Error (sometimes called 500 internal server error), which gives you your server when there is a problem in it. It basically tells you that something has gone wrong, but it does not know what went wrong in the end.

This is not a satisfying explanation, but again, it is not a specific error either.

What is the cause of "Internal Server Error"?<
Because this error is so broad, there is no single reason for it.

Its most common causes of WordPress are:

corrupting .htaccess
Issue of one of the plugins.
Completion of the PHP memory limit.
Wordpress corrupt core files
So let me tell you the main solutions to deal with all these problems. But if you have to quickly find out what exactly is going wrong, the error logs of your server can quickly tell you what is the cause of the problem.

If your host continues to use cPanel, you can see it by going to your cPanel's dashboard and then clicking on the error log.

Fix internal server error in WordPress
Unfortunately, as you can see from the image below, these error logs are not always user-friendly, in terms of reading.

error log in the internal server error
If you do not know anything special from the error people, then you:

So you can contact your host's support to tell you what exactly the problem is.
Directly solve some common issues about which main is telling you below.
The hosts confirmed cPanel offered below:

Bluehost
Hostgator
SiteGround
Inmotion Hosting

How to fix "Internal Server Error" in WordPress?

Below are some of the most common ways to fix WordPress issues. I recommend you start from the top and move downwards.

Potential Fix 1: Generate a new .htaccess file

The .htaccess file is a file for the configuration of your web server. WordPress uses this to set the structure of your permalinks.

Because it controls the configuration of your web server, even a small mistake in this file can put an internal server error in front of you.

But thankfully it is very easy to solve this problem. All you have to do is force WordPress to generate a new .htaccess file for you.

Know how:

Step 1: Rename your existing .htaccess file

To begin, you will have to rename your existing .htaccess file. You can do this in two ways:

Connect your site via FTP. You can use Filezilla to do this.
You can also use cPanel's built-in file manager tool.
I am going to show you the process with the file manager because it is simple for most users. But core principles will remain the same, it does not matter which method you are using.

You can access Final Manager from the cPanel dashboard:

file manager c panel
Once you open File Manager, you go to your root directory, find the .htaccess file.

Right click and choose Rename.

htaccess in file manager - cPanel
Rename it as something like, ".htaccess_old".

Now you have to generate a new .htaccess file to replace it.

Step 2: Generate new .htaccess file

To force your WordPress to generate a new .htaccess file, go to your WordPress dashboard.

Then go to Settings → Permalinks.

You do not need to change any setting.

Just click the save changes button and WordPress will automatically generate a new file for you.</>

permalink par click Kare
And just hopefully your site will start running again.

Potential Fix 2: Deactivate your plugins, find the faulty plugin.

If the .htaccess file was not your problem, then the next thing you can try is to deactivate plugins.

Usually, plugin issues and conflicts can cause 500 internal server error in WordPress. This often happens when you have installed a new plugin and immediately you encounter an error.

By deactivating plugins, you can search and delete the plugin that causes the problem.

If you can still access your WordPress dashboard, then how to deactivate your plugins:

If you can still access your dashboard, go to your plugin management area, then use the checkbox to deactivate all plugins.

Now reactivate the plugins one by one so that you get the plugin that creates the problem.

Remember you can't access your dashboard, then how to deactivate plugins:

When internal server error occurs, there are most chances that you will not be able to access the dashboard. In such a situation, you have to take a slightly different approach to deactivate plugins.

In this case, you will have to resort to the file manager or FTP. You can also use Filezilla.
Go to the / wp-content / folder.
Rename the plugins folder as plugins_old.
fix-internal-server-error-wordpress-7-1
This will deactivate all plugins.

Now try to access your WordPress dashboard, if you are able to access it, then you will be confirmed that the issue is with a plugin.

If you go to the plugin section of your dashboard, it will give you an error: “the plugin has been deactivated due to an error; plugin file does not exist. "

Don't worry, we found that the problem is with anyone plugin.

To reactivate plugins one by one:

Rename the Plugin folder again from plugins_old to plugins itself.

Now reactivate the plugins one by one from the WordPress dashboard.

After activating each plugin, browse 3-4 pages of your blog. Keep doing this until the internal server error occurs again. You will get the faulty plugin.

In most cases, this will be the solution to your problem.

Potential Fix 3: Increase your web hosting's PHP memory limit

If your problem is still not solved, there are still some things you can do:

As you know that WordPress is a memory hobbing CMS, so when you install more plugins, or for anything else WordPress needs more memory, you have to increase the PHP memory limit, otherwise, error Will come.

To do this you have to edit the wp-config.php file. You can also access it from FTP or file manager.

increase PHP memory to fix internal server error
/ * Height all, stop editing! Happy blogging. Before * / message you have to add this code:

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

This will work only if your host has not set a lower memory limit for you.

For this reason, if you do not see any change after editing this file, then you will have to contact your host to increase the limit.

Potential Fix 4: Upload core files of WordPress again.

Finally, if nothing happens, you will need to upload a clean copy of the core files of WordPress.

For this work, I recommend you to use an FTP program instead of File Manager.

Note: Make sure that before doing all this, take a complete backup of your site. In this regard, you should read our article: How to get Complete Backup of your WordPress Site?

Download the latest version of WordPress from WordPress.org:

fix-error-judged-a-database-connection-wordpress-11-1
Once the download is over, extract and delete the ZIP file:

All wp-content folder.
wp-config-sample.php file.

After this, upload all the remaining files to your WordPress site via FTP. Your FTP program will give you a prompt for duplicate files. When this happens, do not forget to choose the option of Overwrite duplicate files.

Fixing Internal Server Error Message
At this point, some solution must have worked for you so that your internal server error will be solved.

If not, main recommend you to contact your host's support team. And if they too cannot help you, then you can hire a WordPress developer to fix things.

You can also comment, maybe we can solve your error together!

Tell me if you have encountered this error and what did you do to solve it...

Do share this article on social media so that more and more WordPress users will be helped to solve the errors.