Online Support

Sales: 0800 817 4727

4 Efficient ways to diagnose WordPress issues | Storm Internet

4 Efficient ways to diagnose WordPress issues | Storm Internet

“There comes a time in a man’s life, and I’ve had plenty of them” – Casey Stengel

And so too will you encounter numerous times when troubleshooting common WordPress issues will consume the hours of your day. But knowing how to diagnose these issues efficiently is half the battle won and can help you cut down on time spent digging for solutions.

Note: Solving WordPress issues is easy when you’re a Storm Managed WordPress or managed server customer. Get in touch with Storm support or a member of your dedicated Support Pod. They’ll investigate, diagnose, and resolve the issue while you take a well-earned break.

4 Ways to diagnose common WordPress issues

IBM has a nifty guide to troubleshooting, called, unsurprisingly, Introduction to Troubleshooting. The fact that this document exists (and that there are so many others like it on the internet) should say something about the act, nay, the art, of finding out what’s keeping a system (or in this case, your WordPress website), from working the way it should.

And while the IBM guide wasn’t written with WordPress users in mind, it touches on a few questions which should be answered in any troubleshooting scenario:

  • What are the symptoms of the problem?

Do you get any error messages? Are pages not loading, or only partially loading?

  • Where does the problem occur?

Does the problem only occur on specific pages? If so, which technologies (plugins, add-ons, etc.) are used on those pages?

  • When does the problem occur?

Are only some users experiencing the problem when they load certain pages or perform specific actions?

  • Under which conditions does the problem occur?

Does the problem only occur during times of high-volume traffic, or on, for example, the second step of a multi-step form?

  • Can the problem be reproduced?

If problems are reported by users, and you repeat their steps, do you experience the same issue?

Answering these questions is important since it can help narrow down the root cause of the error. Or, at least, provide you with enough information to fully describe the problem to others who might be able to help.

Always make a backup of your site before you begin

But if you’re intent on taking on that learning curve, it is strongly recommended to create a backup of your entire WordPress site and database before you proceed. If possible, use your backup to restore your site in a development or testing environment (for example, on your computer); when something breaks during the troubleshooting process (which is not uncommon), your live site won’t be affected and you can easily use your backup to restore your test site to its original state.

Method 1: Google it

Perhaps not the first step of a WordPress Jedi, but let’s face it, it’s faster. Copy and paste the error message you’re receiving into the search bar, and press enter. Chances are that someone, somewhere, has had the same problem, which other very clever people have helped solve. The sites where you’re likely to find a solution to your issue include:

While there are many other sites capable of providing solutions to your WordPress issues, I’ve found that these three tend to solve the majority of WordPress-related problems.

Method 2: Check the logs

But what if there isn’t an error message to Google? Or what if the error message is too unspecific?

Had I started WordPress armed with knowledge about logs and where to find them, the road would have been a little smoother. So to help speed your journey, here’s what you need to know:

What are logs?

A log is a record of events kept by your server. When someone visits your website, that event is written to a log file. When you experience an error on your website, that too is written to a log file. Most of the time.

The location where logs are stored will vary, depending on your server and hosting package:

If you’re on cPanel-enabled shared hosting, you’ll find the logs under Metrics > Errors

cPanel error log

If you’re on a Linux cloud virtual server you’ll usually find the logs located in /var/logs/apache2

Linux Apache logs

If you can’t find your site’s logs there (or there are too many to choose from), look in your site’s virtual host file for the name of your site’s error log:

Linux Apache vHost

You can find the log location in Apache’s environment variables:

Linux Apache envvars

Method 3: Enable WP_DEBUG

One step up from checking the log files is enabling WP_DEBUG. This WordPress debugging feature is typically used by developers but can be used to get more detailed information about errors on your WordPress website.

You can enable WP_DEBUG by adding the following line to the wp-config.php file in your site’s root directory:

// Enable WP_DEBUG mode

define( 'WP_DEBUG', true );

We can take it a step further and tell WordPress to commit all errors to a file by adding the following line next:

define( 'WP_DEBUG_LOG', '/tmp/wp-errors.log' );

If you’re hunting for errors on a live site, you might want to suppress errors being displayed on your site’s pages. Since we’ve already specified a log file where errors can be stored, we can set WP_DEBUG_DISPLAY to false, which won’t expose visitors to unattractive error messages.

define( 'WP_DEBUG_DISPLAY', false );

wp-config debug

Method 4: Use your browser’s Developer Tools

Modern browsers ship with Developer Tools, or DevTools, which is a set of diagnostic tools that can be used to view, edit, modify, and debug HTML, CSS, and JavaScript.

DevTools can be activated in most browsers by pressing F12. To close DevTools, press F12 again or click the ‘X’ in the top-right corner of the DevTools window.

screenshot of firefox devtools

However, the problem with DevTools is that it does require some technical know-how to make sense of what you’re seeing and to determine whether what you’re seeing is related to the WordPress issue you’re experiencing. 

For most non-developers, the Inspector and Console tabs are the most important:

Inspector: Useful to edit and debug CSS and HTML

Console: Useful to determine whether all site resources like cookies, JavaScript, and stylesheets are being loaded

To learn more about DevTools and how to use it, refer to your browser’s documentation:

Failing that, the only thing left to do is contact your host’s tech support team. When it comes to obscure WordPress-related issues, chances are that they’ve heard it before. Or, at least, they’ll know where to look.

0800 817 4727