A DDEV addon that replaces Xdebug with php-debugger — a lightweight fork focused on step-debugging only.
Xdebug adds ~324% overhead even when loaded but inactive. php-debugger strips profiling and coverage to achieve only ~4% overhead, while remaining a drop-in replacement for step-debugging (same DBGp protocol, same xdebug.* INI settings).
- DDEV >= v1.23.5
- PHP 8.2 or later
- Any architecture: pre-built binaries for amd64, compiles from source on arm64 (Apple Silicon)
ddev add-on get jeandavid/ddev-php-debugger
ddev restartFor local development / testing:
ddev add-on get /path/to/this/repo
ddev restartThe addon is transparent — use DDEV's built-in xdebug commands as usual:
# Enable step-debugging (now powered by php-debugger)
ddev xdebug on
# Verify
ddev exec php -v
# Shows: "with PHP Debugger v0.1.0-dev"
# Disable
ddev xdebug offYour IDE configuration (PHPStorm, VS Code, etc.) remains unchanged — php-debugger speaks the same DBGp protocol.
At container build time, the addon:
- Detects the PHP version and architecture
- On amd64: downloads the matching pre-built binary from GitHub releases
- On arm64: compiles php-debugger from source (first build takes ~40s)
- Backs up the original
xdebug.so→xdebug.so.original - Replaces
xdebug.sowith the php-debugger binary
The addon also overrides xdebug.mode to debug (instead of DDEV's default debug,develop) since php-debugger only supports step-debugging.
This means ddev xdebug on loads php-debugger instead of Xdebug, with zero UX change.
ddev add-on remove php-debugger
ddev restartThis removes the custom Dockerfile — the next build uses the stock Xdebug.
bats tests/test.bats