What is Debug Bar plugin?
Debug Bar is a WordPress plugin that adds a debug menu to the WordPress admin bar displaying various debugging information about the current page request. It provides panels for PHP errors and warnings, SQL queries with timing data, query information (loop details, conditional tags, queried object), and WordPress global state information. Debug Bar is an official WordPress.org plugin maintained as part of the WordPress ecosystem.
Compared to Query Monitor, Debug Bar is simpler and less detailed — it shows the same categories of information but with less depth. Where Query Monitor attributes database queries to the calling plugin or theme, Debug Bar shows the queries without caller attribution. Where Query Monitor provides hook tracing and HTTP API call logging, Debug Bar does not. Debug Bar is appropriate for developers who want a lightweight debugging overlay without Query Monitor’s additional panels and interface complexity.
Debug Bar’s value is extended significantly by its add-on plugin ecosystem: Debug Bar Console (JavaScript console in the admin), Debug Bar Cron (scheduled tasks), Debug Bar Actions and Filters Addon (hook tracing), Debug Bar Shortcodes (registered shortcodes), and Debug Bar Transients (stored transients) add specific capabilities without the overhead of a comprehensive tool. For targeted debugging of specific WordPress subsystems, the Debug Bar add-on approach provides flexibility without activating a full-featured profiling tool.
Need Help With Debug Bar Setup, Troubleshooting, or Customization?
Need help with Debug Bar? Whether you are dealing with errors, broken functionality, styling problems, plugin conflicts, or advanced customization, we can help you fix the issue and get the plugin working properly on your WordPress site.
Get Debug Bar Expert HelpKey Features
- Admin bar menu showing debug information
- PHP errors and warnings panel
- SQL queries with timing (requires SAVEQUERIES constant)
- Query information: WP_Query vars, conditional tags, queried object
- WordPress globals inspection
Pros & Cons
Pros
- Simpler interface than Query Monitor — lower information density suits developers who want a focused view
- Official WordPress.org plugin with long maintenance history
- Add-on ecosystem allows targeted expansion for specific debugging needs
Cons
- Less detailed than Query Monitor — no caller attribution for database queries, no hook tracing in the core plugin
- Requires WP_DEBUG and SAVEQUERIES constants in wp-config.php for full functionality (Query Monitor does not require these)
Free vs Premium
Completely free. No paid version.
Common Problems & Fixes
Debug Bar shows no database queries even though the page loads data from the database. How do I enable query logging?
Debug Bar’s SQL query panel requires SAVEQUERIES to be enabled in wp-config.php. Add the following to wp-config.php before the “That’s all” comment: define(“SAVEQUERIES”, true); This constant tells WordPress to store all database queries for debugging. Also ensure WP_DEBUG is set to true for full error reporting. Note that SAVEQUERIES adds overhead to every database query — only enable it during active debugging sessions and disable it afterwards.
Debug Bar is not visible in the admin bar — it was showing before but disappeared. How do I restore it?
Debug Bar only displays when: (1) the user is logged in as an administrator; (2) WP_DEBUG is set to true in wp-config.php. If either condition is false, the Debug Bar menu does not appear. Verify WP_DEBUG = true in wp-config.php. Also check if a CSS conflict with your admin theme is hiding the Debug Bar button — use browser DevTools to inspect the admin bar area for a hidden Debug Bar element.
Debug Bar Console (add-on) is throwing JavaScript errors in the admin — how do I resolve console conflicts?
Debug Bar Console provides an in-browser JavaScript console for executing code in the WordPress context. Conflicts can occur with JavaScript debugger extensions or other admin plugins that modify the browser console. Try: (1) disabling browser extensions (particularly developer tools extensions); (2) testing in a different browser; (3) checking browser DevTools Console for the specific error message — JavaScript syntax errors in the eval’d console code are user error; JavaScript errors from Debug Bar Console itself indicate a plugin conflict or browser compatibility issue.
Customization & Developer Notes
How do I add a custom Debug Bar panel for my plugin?
Create a class that extends Debug_Bar_Panel. Implement the init() method (called on each page load for setup), the prerender() method (called before render, good for data collection), and the render() method (outputs the panel HTML). Add the panel to Debug Bar via add_filter(“debug_bar_panels”, function($panels) { $panels[] = new My_Custom_Panel(); return $panels; }); This pattern allows plugin developers to surface plugin-specific debug data alongside Debug Bar’s standard panels.
Which Debug Bar add-ons are most useful for WordPress development?
The most valuable Debug Bar add-ons: (1) Debug Bar Console — execute PHP/jQuery code in the browser against WordPress context; (2) Debug Bar Actions and Filters — shows hooks fired on the current page (similar to Query Monitor’s hooks panel); (3) Debug Bar Cron — displays scheduled WP-Cron events and their next run times; (4) Debug Bar Transients — shows stored transients with expiration times; (5) Debug Bar Constants — lists all defined PHP constants active during the request. Install only the add-ons relevant to your current debugging task to minimize admin overhead.
Frequently Asked Questions
Should I use Debug Bar or Query Monitor?
Query Monitor is the recommended choice for most WordPress developers in 2025. It provides all the functionality of Debug Bar plus database query caller attribution, hook tracing, HTTP API logging, REST API inspection, and block editor data — without requiring WP_DEBUG or SAVEQUERIES to be enabled in wp-config.php. Debug Bar is a simpler alternative for developers who want a focused tool with lower information density, or who need the specific capabilities of Debug Bar add-ons not available in Query Monitor.
Does Debug Bar slow down the WordPress frontend?
Debug Bar itself adds minimal overhead to the page response — it collects data during the request and displays it in the admin bar. The most significant performance impact comes from enabling SAVEQUERIES (required for SQL query display), which stores all database queries in PHP memory throughout the request. On pages with many queries, this can add measurable memory and time overhead. Disable SAVEQUERIES when not actively using Debug Bar’s query panel.
Can Debug Bar break after updates?
Yes, that can happen, especially on older sites with many plugins. This usually happens when the plugin, theme, and add-ons are updated out of sequence. In most cases, testing on staging catches the issue before it reaches the live site. From experience, backups and changelog reviews save a lot of cleanup time.
What should I check before installing Debug Bar?
Start by checking whether another plugin already does the same job. In most cases, overlap is what creates avoidable conflicts and performance issues. A common issue is installing a plugin because it looks convenient without checking the stack first. From experience, a short compatibility review avoids most of the pain later.