How to Use WordPress Log Files to Improve Your Website?

- Advertisement -

WordPress has become one of the most popular platforms for website creation and blogging (even as a profession!). Not only it being an open-source platform benefits the users, but also there are numerous features provided which crosses out the need to develop a site from its base codes. Free templates, advanced plugins, different modes of editors, etc. are some of the tools which help in WordPress theme customization.

Not only the process of creating and uploading a website through WordPress has become easy and accessible to all but also has the work of maintaining the websites and fixing its errors as it runs.


- Advertisement -

WordPress Log Files refers to those documents which are usually hidden somewhere in the application, which keep track of all the tasks performed by your website over its whole life span or even for a specific amount of period (which can be set by you).

There are several reasons for which developers refer to these log files.

- Advertisement -

These are:

1. To find errors in your website

- Advertisement -

2. Help fix the errors, i.e., troubleshooting

3. Inspecting the security and safety of your portal

4. Keeping a record of the user activity

5. Maintaining a track of the customers coming on your website and their experience

6. Monitor plugin activity and performance

7. Surf themes, etc.


Amidst these log files, you can also find the error logs, which are the records of all the problems your website has faced and the fixes (troubleshooting) which need to be done as soon as possible to prevent further troubles.

Debugging is the process of finding errors to eradicate them, and troubleshooting is mainly restricted to the end product, which is fixing the problem.


After learning the basics, let’s jump on to the tutorial part where you’ll learn how to access these log files to find errors in your website and fix them. If you’re entirely unaware of the coding and WordPress, it is advisable to hire a WordPress developer to aid you with the debugging and troubleshooting processes.


By default, the WordPress logging is turned off. The main reason being that logging too much can cost your server resources and therefore, rather than running the site, WordPress is logging how to run the website.

Hence, the first step is to enable logging. You can do it either by FileZilla via FTP and code-editor or WP File Manager or cPanel. Nevertheless, the necessary process can be achieved easily in three sub-steps:

  • Finding the wp-config.php file

Please navigate to the WordPress root folder, which is public_html and open the wp-config.php file within it.

  • Editing the wp-config.php file

Open the wp-config.php file with any editor of your choice and scroll down till you read the line /* That’s all, stop editing! Happy blogging. */

Just above this line, copy-paste the following code:

define( ‘WP_DEBUG’, true);

define( ‘WP_DEBUG_LOG’, true);

The first piece of codes helps to start the debugging process, while the second piece is responsible for creating the log file.

If any of them is already present and marked ‘false’, make the necessary changes to make them look like the codes given above.


After turning the logging process on, the log files will be generated for you to read and understand the errors. Keep patience for the log files will not appear out of nowhere within seconds, the process will take some time.

If the debug.log file is not generated, it’s mainly because your website is error-free. But this happens quite rarely. Often, plugins keep crashing, and various tasks are unable to get completed.

Once the debug.log file is generated, you will find many PHP notices and issues given within it.

Again, if you are new to WordPress or are having problems with enabling the logging and debugging process, hire a WordPress developer to perform the developing and website-managing tasks for you.


  • If you’re not a developer yourself, the best option for you to fix such issues is to download the complete debug.log file and mail it to your system administrator or WordPress developer.
  • Alternatively, you can also send the individual reports of the debug.log file to the plugin developers of WordPress to get your issues fixed. Use forums available on the support pages of plugin’s repo page for the same.

Once your problems get fixed, remember to disable the logging lest you want to get more issues. Change the ‘true’ part in both the codes in STEP 1 to ‘false’ and save the changes.

Although WordPress log files can be extensive sometimes, they prove to be beneficial when it comes to finding errors and fixing them. They help you identify breakdowns within different plugins and fix them, thereby aiding you with your WordPress theme customization, indirectly. Hence, the next time you face any issue, enable the logging and mail the debug.log to the developers.

- Advertisement -
Jhon Dew
Internet trailblazer. Travel ninja. Social media evangelist. Incurable explorer. Subtly charming organizer. Tv scholar. Alcohol geek. Certified creator.

Related Stories

How To Manage Academic Stress In College Life

Most students face a major amount of stress that has a significant effect on health, happiness, and grades. While in stress and...

Dog Nail Problems

Dog nail problems can be avoided by keeping them trimmed. Long nails pose a threat for several reasons. First, the clicking...

The best way to Recover Lost MS SQL Database Password?

MS SQL Server database can be an RDBMS (Rational Database Management System), that’s produced by Microsoft. Its primary function to retrieve, manage,...

How to win at online betting?

Many people are losing their jobs and companies in the pandemic situation Coronavirus. That's why people choose to earn online cash. Online...

What kinds of videos can be watched online

It’s always great to meet up with your friends or family and hide out on the couch to watch a movie, film,...

5 tips to win at online casinos

Online casino games are the best way of online gambling, where you can play games and gamble on them.   Online gambling...

Everything to know about online movie streaming

People are always in search of new ways to have entertainment. Life without entertainment is quite boring. Some people love to play...

You might also likeRELATED
Recommended to you

How To Manage Academic Stress In College Life

Most students face a major amount of...

Dog Nail Problems

Dog nail problems can be avoided...

The best way to Recover Lost MS SQL Database Password?

MS SQL Server database can be an...