Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Laravel Ray

Laravel Ray Laravel Package

spatie/laravel-ray

Send Laravel debug output to Ray, Spatie’s desktop debugging app. Use a consistent API to inspect variables, arrays, HTML, queries and more, measure performance, and pause execution. Works across Laravel/PHP with Ray’s rich UI.

View on GitHub
Deep Wiki
Context7

Easily debug Laravel apps

Frequently asked questions about Laravel Ray
How do I install spatie/laravel-ray in a Laravel 12 project?
Run `composer require spatie/laravel-ray` and register the service provider in `config/app.php` under `providers`. No additional steps are needed unless you want to publish the config file, which is optional.
Can I use Ray for debugging in production, or is it only for development?
Ray is designed for development. The free tier limits output to 20 messages per session, and exposing debug data in production risks sensitive information. Disable Ray in production or use `Ray::ignore()` for sensitive data.
Will Ray slow down my Laravel application in production?
Ray introduces minimal overhead, but it’s not recommended for production. The free tier throttles messages, and you can disable it entirely in production by removing the service provider or using environment checks.
How do I exclude sensitive data (like API keys) from Ray logs?
Use `Ray::ignore()` to exclude specific variables or data types. For example, `Ray::ignore(fn($data) => str_contains($data, 'secret_'))` will filter out sensitive strings. Combine this with environment-specific configurations.
Does spatie/laravel-ray work with Laravel 13 and PHP 8.5?
Yes, the package officially supports Laravel 11–13 and PHP 8.1+. It includes fixes for PHP 8.5 deprecations, such as null handling in `strtolower()`, ensuring compatibility with modern Laravel stacks.
Can I use Ray alongside Laravel Telescope or Debugbar?
Yes, Ray integrates seamlessly with other debugging tools. Use Ray for real-time inspection of variables, queries, and performance metrics, while Telescope or Debugbar can handle logging and historical data.
How do I measure performance with Ray in Laravel?
Use `Ray::performance()` to start a timer and `Ray::performance('name')->stop()` to measure execution time. Ray displays the duration in milliseconds, helping you identify bottlenecks in your code.
Is there a way to customize what data Ray captures (e.g., only queries or specific variables)?
Yes, Ray supports custom watchers. For example, you can create a watcher for Eloquent queries or Blade templates. Check the [Ray documentation](https://myray.app/docs/php/laravel) for examples on extending Ray’s functionality.
What are the alternatives to spatie/laravel-ray for Laravel debugging?
Alternatives include Laravel Telescope (built-in debugging and logging), Sentry (error tracking and performance monitoring), and Blackfire (profiler for performance optimization). Ray stands out for its real-time, cross-language debugging in a desktop app.
How do I handle Ray licensing for a team of developers?
Ray offers a free tier with limited features. For full access, purchase a license per developer or team. Spatie provides team licenses, and you can manage updates and licenses centrally through their platform. Check [Spatie’s pricing](https://spatie.be/products/ray) for details.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
hexters/coinpayment
rjcodes/rjcms
act-training/laravel-permissions-manager
alimarchal/laravel-chart-of-accounts
babenkoivan/elastic-scout-driver
mkwebdesign/filament-watchdog-v5
renatomarinho/laravel-page-speed
zedmagdy/filament-business-hours
renatovdemoura/blade-elements-ui
devgeek/beacon-admin
benjamin-rqt/data-watcher-bundle
atriumphp/atrium
sandermuller/package-boost-laravel
sandermuller/boost-skills
redaxo/core
yusufgenc/filament-api-forge
l3aro/rating-star-for-filament
leek/filament-subtenant-scope
anil/file-picker
broqit/fields-ai