DevOps

Xdebug – PHP debugging and profiling extension

Xdebug is a PHP extension that provides debugging, profiling and diagnostic tools for developers. It helps identify errors, investigate application behaviour and analyse performance problems in PHP code.

The extension integrates with development environments such as PhpStorm and Visual Studio Code, allowing developers to step through scripts, inspect variables and follow execution paths. It also provides tools for analysing function calls, memory usage and test coverage.

Xdebug can be used when developing web applications or command-line scripts. Its individual capabilities can be enabled as needed, allowing developers to concentrate on a particular debugging or performance analysis task.

This is free and open source software.

Key Features

  • Interactive step debugging through IDEs and editors supporting the DBGp protocol, including PhpStorm and Visual Studio Code.
  • Set breakpoints, step through code, inspect variables and evaluate expressions while an application executes.
  • Enhanced error reporting with detailed stack traces showing function calls, arguments, file names and line numbers.
  • Improves PHP’s var_dump() function with formatted output for arrays, objects and nested data structures.
  • Record function calls, arguments, return values and variable assignments to trace application execution.
  • Profile PHP applications to identify performance bottlenecks and excessive memory consumption, with output compatible with KCacheGrind and QCacheGrind.
  • Generate trace data for CPU-time and memory-usage flame graphs, which can be visualised using external tools.
  • Collect code coverage information, including executed lines, branch coverage and path coverage, for use with testing frameworks such as PHPUnit.
  • Analyse garbage collection activity through dedicated statistics.
  • Detect excessive recursion and provide diagnostic information about execution and memory usage.
  • Activate debugging, tracing and profiling selectively using request triggers or environment variables.
  • Supports remote debugging, allowing PHP applications running on a server to communicate with a developer’s local IDE.
  • Provides a command-line debugging client for interactive debugging without a graphical IDE.
  • Cross-platform support – runs on Linux, macOS, and Windows.

Website: github.com/xdebug/xdebug
Support:
Developer: Derick Rethans
License: Xdebug License v1.03

Xdebug is written in PHP and C. Learn PHP with our recommended free books and free tutorials. Learn C with our recommended free books and free tutorials.


Related Software

Debuggers
LLDBNext generation, high-performance debugger
GhidraSoftware reverse engineering framework
DelveSource level debugger for the Go programming language
GDBThe GNU Debugger
ValgrindA memory debugger and profiler
Radare2Portable reversing framework
BugStalkerRust debugger
XdebugExtension for PHP to aid debugging and development
SeerGUI frontend to GDB
iaitoGraphical interface for radare2
KDbgGraphical user interface to GDB
straceDiagnostic, debugging and instructional userspace utility
rrRecord-and-replay debugger
gfLightweight GDB interface with source, stack and memory views
drgnProgrammable debugger that puts scripting at the centre
cgdbLightweight console frontend to the GNU debugger
PuDBConsole-based visual debugger for Python
nndPartially inspired by RemedyBG
bashdbSource-code debugger for bash; follows the GDB command syntax
PINCEMemory scanning, process manipulation and reverse engineering
edbLow-level debugging with disassembly and register inspection
SysprofProfile an application or entire system
crashLinux kernel crash analysis utility

Read our verdict in the software roundup.


Best Free and Open Source Software LinuxLinks helps you discover the best free and open source software for Linux. Explore our extensive collection of recommended applications, including alternatives to popular proprietary software.

We also publish software reviews, Linux tutorials, hardware reviews, free programming books and articles covering the wider open source community. Browse our Linux resources to discover more.

Know a useful free and open source Linux application we haven't covered? Suggest a program for inclusion.

Has your software been featured on LinuxLinks? Display one of our Featured on LinuxLinks badges on your website or GitHub README.
Subscribe

Please read our Comment Policy before commenting.

Notify of
guest
0 Comments
Oldest
Newest Most Voted