yiisoft/yii2-debug
Yii 2 Debug Extension adds a web debugger toolbar and detailed debug pages for your Yii 2 application. Inspect requests, logs, DB queries, profiling data, and more to troubleshoot performance and errors during development.
Developer Productivity & Debugging Workflow:
Build vs. Buy:
Use Cases:
runtime/debug logs).Extensibility as a Feature:
PaymentsPanel to log Stripe/Webhook failures with transaction IDs.Performance Profiling:
Adopt if:
Look Elsewhere if:
allowedIPs to restrict access.Alternatives to Evaluate:
"This package gives our Yii2 dev team a Swiss Army knife for debugging—like a built-in ‘black box recorder’ for our application. It slashes time spent hunting bugs by surfacing real-time data (queries, performance, logs) in a toolbar, while keeping sensitive info locked down to trusted IPs. For example, during our last feature sprint, it helped us catch a N+1 query issue in 10 minutes that would’ve taken hours with manual logging. It’s also extensible, so we can add custom panels for business-critical metrics (e.g., payment failures) without reinventing the wheel. The cost? Zero—it’s open-source and maintained by the Yii team. ROI? Faster releases, fewer production fires."
*"This is Yii2’s answer to Laravel Telescope—a debug toolbar + detailed panels for queries, requests, memory, and more. Key perks:
'debug' to bootstrap and get a toolbar.Panel class (e.g., track ViewsPanel or PaymentsPanel).allowedIPs to avoid exposing debug data in prod.Tradeoff: It’s Yii2-only, but if we’re stuck with Yii2, this is the most powerful debugging tool we can get without building it ourselves. Let’s prototype it in staging this sprint."*
*"Imagine Chrome DevTools for your backend:
User::find() calls or API latency).How to start:
composer require yiisoft/yii2-debugconfig/web.php:
'bootstrap' => ['debug'],
'modules' => ['debug' => ['class' => 'yii\debug\Module']],
Pro Tip: Use tracePathMappings for Dockerized apps to fix file paths in stack traces."*
How can I help you explore Laravel packages today?