Whoops is a PHP library that improves the debugging experience by handling uncaught exceptions and presenting beautiful error pages. Instead of a cryptic “fatal error,” Whoops catches the exception and renders a detailed stack trace with syntax-highlighted code snippets, variable values, and clickable frames to navigate between calls. It can be integrated into frameworks or standalone scripts so developers consistently get readable, informative pages during development. Beyond error pages, Whoops supports custom handlers, logging, and filtering so exceptions can be gracefully transformed or reported. Because it only activates in development by default, it avoids revealing internal application state in production. Developers use Whoops to shorten debugging cycles, reduce the frustration of tracing issues, and maintain cleaner error surfaces across applications.
Features
- Visually appealing, readable error pages out-of-the-box
- Stacked error handling allowing multiple layered handlers
- Integrates easily as a Composer package
- Developer-tuned interface for quick debugging feedback
- Extensible and integrates with frameworks like Laminas Expressive
- Configurable for production vs. development behavior