WordPress is a comprehensive Content Management System. It usually meets the user’s expectation and makes your website engaging and attractive. But nothing goes on without errors. So, does WordPress.
WordPress core code is very well coded and there are a very fewer chances that they return an error. Still, there are many cases, where a WordPress website shows loads of errors such as no theme on the website, or database connection error.
Well, the main reason behind these errors in most of the cases is third party plugins and themes. These plugins and themes extend the functionality of the website but there are negative effects as well. They create their own bugs, incompatibility, and issues.
In this post, I will give you some troubleshooting tips to tackle WordPress errors and glitches. So, if you ever encounter any WordPress error or glitch and you have no idea what to do, you can simply follow these troubleshooting steps and then despite the nature of your problem, it will be solved at that instance.
So, let’s get started,
Before doing any of the steps, make sure that you have created a full backup of your website. This is crucial as it will save the precious data of your website.
Deactivate All The Plugins
Now, most of the time the real problem in the errors of a WordPress website are caused because of plugins. An outdated plugin can really spun your head. Most of the time the problem initialize like this, you install a new plugin and then your website breaks.
The only solution to this is to simply deactivate the buggy plugin. Many a times, you need to work with that plugin or else you cannot move forward. In that situation, it’s wise to contact the developer of the plugin to solve the compatibility issue.
There are cases when bugs and errors come and you have no idea why. Deactivating the plugins or renaming the plugins directory via FTP can be a great first step to check whether there is a problem because of a plugin or not. Deactivate all the plugins collectively and then activate them one by one to find the problematic plugin. This is the best way to find the buggy plugin.
Change Your Theme Temporarily
Just like plugins, the theme might also have some compatibility issue. In order to check that, first, you need to check the support files for the incompatibility. There can be a situation where a plugin is embedded with the theme.
Many a times I have seen that the upgraded versions of themes can also break your WordPress website. After checking the plugins for the issue, next step is to troubleshoot the theme. You can switch to any of the default WordPress themes (Twenty Seventeen) and see if the problem still exists.
If the error goes away after switching the theme, it’s the theme that was causing the issue. You can contact theme developer to get the issue resolved.
Refresh The WordPress Permalinks
The WordPress website’s permalinks are highly SEO oriented but still, they can throw an error. That error is usually of unexpected 404. If your permalinks are not configured or updated properly, this error will definitely show up.
In this case, you need to make sure that you refresh your permalinks correctly. In order to refresh the permalinks, simply visit Settings → Permalinks page. If the problem still persists you can go ahead and click on save changes without making any changes. This will refresh the permalink structure of your WordPress website.
Rename The .htaccess File
The root of all the internal server errors is a corrupt .htaccess file. First, you need to access your website via FTP client. Then access the .htaccess file in the website’s root directory.
You will need to force FTP to show the hidden files since htaccess file will be hidden most of the time. Now, download the file to create a backup either on your system or hard disk or cloud. Then, simply rename it to say .htacess-bak.
Now go to Settings → Permalinks to refresh your permalinks and to automatically regenerate a new .htaccess file for your WordPress website. If this was the source of your problem, this should solve it.
Reinstall The Core Files
You must also check the version of the WordPress as well. Maybe you’re getting an error because the WordPress core files are outdated. You can reinstall the core files of WordPress.
You can do the same with plugins and themes if the error continues to show. You can also try to upload the core files manually via FTP. This will not affect your content on the website.
Increase PHP Memory Limit
If your website is not loading and also not showing any error then this might be a problem with your website’s PHP memory. You can increase it by adding these lines to your wp-config.php file. This file resides in the root directory of your website and you can access it via FTP.
If still nothing happens, then you must try 128M or 256M.
Bonus Tip: You can turn on the WordPress debug mode to view the errors caused by theme, plugins, etc (if any). You can simply enable debugging via wp-config.php. Set WP_Debug constant to true, which by default is always set to false.
define( 'WP_DEBUG', true );
These are some of the common troubleshooting techniques that can really come in handy while troubleshooting an unknown error on your WordPress website.
Here’s a quick flashback of some common troubleshooting steps:
- An outdated plugin can really spin your head. Most of the time the problem initialize like this, you install a new plugin and then your website breaks.
- Just like plugins, the theme might also have some compatibility issue. In order to check that, first, you need to check the support files for the incompatibility.
- If your permalinks are not configured or updated properly, you will definitely encounter 404 error.
- All the internal server error are caused by a corrupt .htaccess file.
- Maybe you’re getting an error because the WordPress core files are outdated. You can reinstall the WordPress core files to see if it resolves the problem at hand.
- If your website is not loading and also not showing any error then there might be a problem with your website’s PHP memory.
I hope this will help you in troubleshooting the common errors and glitches of a WordPress website. If you still face any problems then you can mention it in comments and we can solve it together.
About the Author: Marie Thomas is the author of this post. She is an experienced WordPress developer for WordSuccor Ltd. — a leading custom WordPress development services provider in the USA. Marie can be found here working on WordPress theme customization and plugin development with her team of industry’s most experienced WordPress professionals.