yii3 / debug
Yii3 adapter for the PHP Forge debug core.
Requires
- php: >=8.3
- composer-runtime-api: ^2.2
- php-forge/debug: ^0.4
- php-forge/debug-core: ^0.1
- psr/container: ^2.0
- psr/event-dispatcher: ^1.0
- psr/http-factory: ^1.1
- psr/http-message: ^1.1 || ^2.0
- psr/http-server-handler: ^1.0
- psr/http-server-middleware: ^1.0
- psr/log: ^3.0
- ui-awesome/html: ^0.6
- ui-awesome/html-core-component: ^0.4
- yiisoft/aliases: ^3.1
- yiisoft/assets: ^5.1
- yiisoft/data: ^2.0
- yiisoft/db: ^2.0
- yiisoft/definitions: ^3.4
- yiisoft/di: ^1.2
- yiisoft/event-dispatcher: ^1.1
- yiisoft/html: ^4.2
- yiisoft/http: ^1.3
- yiisoft/log: ^2.2
- yiisoft/network-utilities: ^1.2
- yiisoft/profiler: ^3.0
- yiisoft/router: ^4.0
- yiisoft/var-dumper: ^1.7
- yiisoft/view: ^12.2
- yiisoft/yii-dataview: ^1.3
Requires (Dev)
- httpsoft/http-message: ^1.1
- infection/infection: ^0.34
- maglnet/composer-require-checker: ^4.1
- php-forge/coding-standard: ^0.3
- php-forge/inertia: ^0.5
- php-forge/vite: ^0.5
- phpstan/extension-installer: ^1.4
- phpstan/phpstan: ^2.2
- phpstan/phpstan-phpunit: ^2.0
- phpstan/phpstan-strict-rules: ^2.0.3
- phpunit/phpunit: ^12.5
- xepozz/internal-mocker: ^1.4
- yiisoft/config: ^1.6
- yiisoft/db-sqlite: ^2.0
- yiisoft/mailer: ^6.1
- yiisoft/mailer-symfony: ^4.0
- yiisoft/rbac: ^2.1
- yiisoft/router-fastroute: ^4.0
- yiisoft/user: ^2.3
Suggests
- php-forge/vite: Captures resolved Vite assets in its own panel. Register its collector and panel under `yii3/debug.collectors`/`yii3/debug.panels` and route `AssetsResolved` to the collector in `events-web`; see docs/configuration.md.
- yii3/inertia: Registers the Inertia collector, panel, and listener through its own configuration groups; see docs/configuration.md.
- yiisoft/mailer: Captures every sent message in the built-in Mail panel and stores it as a downloadable `.eml` file.
- yiisoft/mailer-symfony: Stores each captured message as its RFC 5322 source and reads its body and headers the way the Yii2 debugger does.
- yiisoft/rbac: Lists the roles and permissions assigned to the captured identity in the built-in User panel.
- yiisoft/user: Captures the identity of the current user in the built-in User panel.
Provides
None
Conflicts
None
Replaces
None
This package is auto-updated.
Last update: 2026-10-30 14:36:26 UTC
README
Debug
Debugger and toolbar for Yii3 applications
Shared Debug Core UI, scoped CSS, light/dark mode, and application-registered extension panels
Warning
Development only. Never enable the debugger in production. Keep access restricted to trusted development IPs
and install production dependencies with composer install --no-dev.
Features
Quick start
Installation
Requires PHP 8.3 or newer and a Yii 3 application using Yii Config Plugin. Version 0.1.0 is available as a stable Composer release. The debugger is development-only runtime tooling, so keep it in the development dependency set:
composer require --dev "yii3/debug:^0.1"
The ^0.1 constraint selects stable releases from 0.1.0 up to, but not including, 0.2.0. A stable Composer version
does not promise API compatibility with future 0.x minor lines.
The application must already provide the yiisoft/router-implementation and yiisoft/db-implementation virtual
packages. Keep its existing router and database driver; if either provider is absent, choose one that matches the
application before retrying installation.
Integrate the application
Run the application with APP_ENV=dev. The debugger also accepts debug and test; it stays disabled when the
runtime environment is missing, unknown, or production. Setting the runner's configuration environment alone is
not enough.
Rebuild the merged configuration after installing or updating the package:
composer yii-config-rebuild
Installation publishes configuration, but the application still owns its aggregate configuration groups, logger, and middleware list. Complete the Getting started guide to connect all of them. Installing the package or seeing it in the merge plan alone does not prove that the debugger can resolve from the container or capture a request.
Basic usage
Open an application page, expand the toolbar at the bottom, and select a panel chip to inspect the request.
Use the Yii chip for Configuration and the PHP chip for PHP info. Switch between light and dark themes from the
toolbar, and press Escape to close the drawer.
Open /debug to browse retained requests. Select two captures in History to compare request metrics and panel
changes, then open either capture for its details. Comparison shows structural counts without exposing panel values.
Configuration
The debugger runs with its default options out of the box. See the configuration reference for options, collectors and panels, provider integrations such as Inertia and Vite, database thresholds, and IDE links. See the application integration examples for copyable container, logger, middleware, and runner recipes.
Security
The toolbar and debugger routes allow 127.0.0.1 and ::1 by default. Access checks use the direct client address,
not forwarded proxy headers. Add only trusted development addresses to allowedIPs; never expose the debugger publicly.
Request captures redact sensitive fields and URL query values; hand the same capture policy to a provider collector that records user data, as the configuration reference shows. In Logs, the log message is not redacted; the PSR-3 context is redacted by the capture policy; SQL diagnostics can include substituted query values. Treat stored captures as sensitive and review them before sharing. In the Events panel, context capture and source traces are disabled by default; this does not affect source traces in Logs or Database.
Documentation
- ๐ Getting started
- โ๏ธ Configuration reference
- ๐ก Application integration examples
- ๐ผ๏ธ Panel screenshots
- ๐ค AI assistance
- ๐งช Testing guide
AI assistance
AI agents should start with the documentation index and use the package-owned
yii3-debug-integration skill for installation, container wiring, and functional verification. The
hosted Yii3 Debug documentation publishes this adapter;
do not substitute the similarly named yii2-extensions/debug guide or its Yii 2 module APIs.
Match the guidance to the installed package files. If a hosted source is unavailable or does not match, use the repository guides, skill source, source PHPDoc, and changelog.