In a while, you should look for errors on your website. While managing a WordPress website, checking the error logs is one of the best practices to keep it running smoothly.
It’s possible that a visitor’s browser sends a request to access a page of your site, but it shows an error. There is a chance that you can’t come to know for a long time.
In this tutorial, you’re going to learn about checking both error logs without requiring any coding skills. The biggest fear comes into the light when people deal with technical things.
Well, I am going to walk you through a simple process you can use any time.
Check for cPanel Error_log
Before we start, you should know the reasons for such errors.
- Old URLs
- Missing Error Pages
- Blocked pages
- Renamed files
- Deleted files
- Permalinks change
Your site may have errors due to many other reasons. Let me walk you through finding those errors.
Note: It’s essential to enable error_log to see the list.
Most of the people follow the steps before even realizing that to see error_log, and you need to enable using the .htaccess file or any other method.
For now, follow the steps to check the list.
Login to your cPanel account and search for the Metrics‘ section. Depending on your web hosting company, the design template may vary.
But you shouldn’t worry about anything. Try to find an Errors option and click to open. It’s possible that your web hosting company may provide an Account Management System to access cPanel.
Here are some best small business web hostings you may like.
When you open the page, you can see 300 previous errors which consist of the Date, IP, Type, Location, etc.
You can detect the user’s location from its IP address. Using the type, you can try to find the error page and fix it. To see the cPanel error logs, this is it.
Next, you need to understand PHP errors.
Search for PHP Error_log
As I have mentioned before, if you have enabled PHP error_log, only then you can see the list. Let me mention a few PHP errors.
- Syntax Error
- Parse Error
- PHP Fatal Error
To find the list, you need to look for the error_log file in the main directory. Follow the steps.
As you’re already logged in to your cPanel account, open the file manager from Files‘ section. This is one of the most common things you can come across while using cPanel.
You may find the file manager icon independent or under any particular section depending on which web hosting company you have.
Click to open.
On this page, you have to make sure you see the public_html directory. By default, many web hostings display the home directory.
Navigate to public_html from the left-hand sidebar.
By default, the name of the error log file is error_log, but it can be php_errorlog or something similar. Scroll down and look for it.
Once you find it, you can download it by double-clicking or decide to see the data by accessing the code editor. Depending on your choice, go ahead.
The best thing is that PHP errors are easy to troubleshoot because of their precise location. If a plugin is conflicting, you can quickly figure it out because the error message will consist of the folder location.
You require WordPress error solving expertise. I hope it’s not a big deal.
Can You Now Locate the Error Logs
Now and then, people ask as is it’s hard to maintain an error-free WordPress site. Well, I always say, you need to learn the basics of WordPress.
Most of the WordPress errors can be solved within a few minutes. Checking the error_log can help you find out the errors you can can’t find out on your own.
Your visitors may see some errors pages, which can affect the user experience. You need to take care of such errors.
In most of the cases, you may ask for someone’s help. But as I have mentioned, PHP errors are easy to diagnose and fix.
Try checking the error_log file and learn more. I hope you can accomplish such a task in no time.