Is your WordPress site acting up? Is it taking time for things to load properly, or is some content not showing up at all? It can be frustrating when your site slows down or something’s not working, especially if the cause for these problems is not evident. But worry not! There’s plenty you can do to find out what’s up with your site.
When you have access to the right tools and knowledge, you’ll be diagnosing and fixing issues in a breeze. Even if your website seems to be working just fine, it’s a good idea to take a look around every once in a while to ensure everything’s OK and performing in an optimal way. If you want your site to be stable and if you’re looking for top performance, it’s a good idea to learn debugging!
“Debugging is the process of finding the root cause, workarounds, and possible fixes for bugs.”
Wikipedia
In this guide, we’ll take a look at how to do debugging in WordPress – and what tools Seravo’s hosting has to offer to make it easier and faster.
WordPress Debugging: The Essentials
Before we dive deep into advanced tools, here are the basics every WordPress site owner, admin or developer should know!

1. Enable Debugging Mode in WordPress
Debugging mode means that any errors are logged and shown directly in your browser when your site is loaded, so you don’t have to look at log files separately. This way, you’ll get an idea of the source of the problem, such as a plugin, theme or custom code.
To turn on debugging mode, you need to edit your site’s wp-config.php file. The file is located in the root directory of your website (htdocs). In Seravo’s hosting environment, the path is /data/wordpress/htdocs/. See directory structure in knowledge base.
Add or edit the following lines before the line that says /* That’s all, stop editing! Happy blogging. */:
define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true );
define( 'WP_DEBUG_DISPLAY', true );

- WP_DEBUG: Activates the debugging feature.
- WP_DEBUG_LOG: Writes all errors into the designated file.
- WP_DEBUG_DISPLAY: Hides errors from the public frontend. Enable this only if you’re working in a staging environment, or on an unpublished website. Should be always set to ‘false’ on a live site: don’t activate it in production, or your website visitors will see the error notifications, too.
If you’re working in a staging environment (shadow) at Seravo, debugging mode is activated by default.
2. Find the Cause
This is the crucial part! However, it’s not always easy to narrow down the culprit and find out what’s actually causing the issue.
If your site breaks immediately after, say, updating or installing a plugin, in all likelihood the new plugin is the culprit.
If the issue happens every once in a while or starts occurring even though nothing has changed, it’s a good idea to narrow down the culprits. Here’s how to do it:
- Temporarily deactivate all plugins. If the issue disappears, one of your plugins is the main culprit. Reactivate plugins one by one and see how your site loads after each activation. Once you activate the plugin that’s causing the errors, you should see the problem reappear on your site.
- Temporarily change your site’s theme. Switch into a default theme (one of the “Twenty” themes) and see how your page loads with it. If your problem disappears, the issue is caused by your site’s theme.

Debugging Tools at Seravo
Seravo’s hosting for WordPress offers powerful tools for developers to make troubleshooting faster and easier. Tools are available both in Seravo Plugin as well as over the command line (SSH).
WordPress Logs
When your WordPress site is hosted at Seravo, the most important log files are all gathered in the /data/log/ directory. Here are the most essential ones in terms of debugging:
| Log File | Purpose |
| php-error.log | Catches all PHP errors, notices, and warnings. The most important log file for debugging. |
| nginx-access.log | Logs all HTTP requests made to your site. |
| nginx-error.log | Logs errors related to the web server (NGINX). |
| sql.log | This log isn’t standard, but its function is often covered by the Query Monitor plugin (see below) which gives you real-time query analysis directly in your WordPress admin. For database issues, combining Query Monitor with the general logs is most effective. |
Helper Command: wp-watch-logs
At Seravo, you can use the following helper command for observing your site’s logs. Just log in to your site via SSH and run:
$ wp-watch-logs
This command conveniently follows the most relevant log files in real time. Try reloading your website in your browser and see how the output changes. The command makes it easy to see exactly what is happening as your site is visited.

WordPress Plugins for Debugging
If you’re looking to further expand the troubleshooting capabilities on your site, there are some great plugins to try out and see if they work for your debugging workflow.
Query Monitor: The Debugging Dashboard for Developers
Query Monitor is one of the most popular debugging plugins for WordPress. It adds new tools to your WordPress dashboard, displaying detailed information, such as…
- Database queries: Highlight slow queries or errors in the database.
- PHP errors: Display errors, warnings and notices in the PHP code.
- HTTP API calls: Show external HTTP requests made by your site, including response codes.
- Scripts and styles: List assets and flags broken dependencies.
Tips for Using Query Monitor
If you’re using Query Monitor, we recommend activating it only for the duration of your debugging session, as keeping it active may slightly slow down your site.
Cross-check the information shown by Query Monitor with other site logs to see what might be causing issues on your site.
Log HTTP Requests: Plugin for Tracking External Connections
The Log HTTP Requests plugin specifically monitors and logs every outgoing request your WordPress site makes using the standard WordPress HTTP API.
Many WordPress plugins communicate with external services and form integrations with them. These include services such as payment gateways, content delivery networks (CDN), SMTP, social media feeds or map APIs. If the external service is slow or fails to respond, your site may freeze, or its functionalities may break.
The Log HTTP Requests plugin displays the URL, response code as well as how long did the request take, helping you identify slow or failing requests pertaining to those services. You can read more about HTTP requests and HTTP error codes in our earlier blog post.
Seravo Plugin: Inspect and Improve WordPress Performance
Seravo Plugin is a powerful dashboard within your WordPress admin view. It seamlessly integrates essential maintenance and debugging features directly into your site, simplifying admin tasks that would otherwise require SSH access or interacting with the command line.
When your site is hosted at Seravo, you’ll find the Seravo Plugin settings in your WordPress dashboard (wp-admin), under the Tools menu.
Here are the most important features in Seravo Plugin when you need to debug or troubleshoot your WordPress site:
- Logs: The plugin provides a graphical interface to view the latest entries from the critical log files (like php-error.log, nginx-access.log, and update.log). This is the easiest way to quickly check your site for errors.
- Site Status: This view gives you insights into your site’s automatic updates, security checks, and backups, as well as other site optimization settings..
- Cache Management: Allows you to easily purge various levels of server-side cache with a single click, which is handy in displaying any changes made during debugging. (In a shadow environment caching is disabled, though.)
Discover more Seravo Plugin features in our knowledge base.

Advanced Debugging and WordPress Code Profiling: Xdebug
Need a deep look into how PHP code executes on your site during a page load? For more complex debugging scenarios and performance optimization, we recommend using a dedicated code profiling tool like Xdebug. It’s an open-source extension for PHP, and can be used for both debugging and profiling alike.
WordPress and its features rely on hooks, actions and functions. If you’re curious in finding out which parts of your WordPress installation (theme, plugin, core) are using the most resources, then Xdebug is for you. Using Xdebug makes it easier to determine what exactly is slowing down your site.
What Xdebug Does
What does Xdebug do? It creates a record of how the PHP is being executed: it displays the names of the functions, the order in which they were executed, as well as the amount of time and memory that was used for each function. With the help of this data, you can pinpoint performance bottlenecks on your WordPress site.
While the raw data of Xdebug can be complex, you can use an additional tool like Webgrind or Graphviz to visualize the result, making it easier to see the bottlenecks.
With the help of this data, you can implement performance fixes to your site and make it load significantly faster. If you’re interested in learning more about Xdebug and using it while your site is hosted at Seravo, take a look at the instructions in our knowledge base.
Final Tips for Troubleshooting WordPress
Remember to use a staging environment! Never debug or develop a site that’s already live. Seravo provides a staging environment (“a shadow”) that is a perfect clone of your live site, allowing you to test changes and fix bugs without affecting your visitors. If you don’t have access to a staging environment yet, get in touch with us.
If an issue persists despite all the debugging and troubleshooting, remember that Seravo’s support team is here to help you pinpoint and resolve any issues.
Happy debugging!

