Flare by Spatie
  • Features
  • Pricing
  • Docs
  • Blog
  • LOG IN
  • START TRACKING
  • Home
  • Features
  • Pricing
  • Docs
  • Blog
    • Try Flare for free
    • Sign in
Flare Flare Laravel Laravel PHP PHP JavaScript JavaScript
  • General
  • Introduction
  • Installation
  • Censoring collected data
  • Ignoring collected data
  • Laravel Octane
  • Errors
  • Adding custom context
  • Customising error grouping
  • Handling errors
  • Linking to errors
  • Reporting errors
  • Sending logs to Flare
  • Performance
  • Introduction
  • Sampling
  • Limits
  • Modify spans and span events
  • Data Collection
  • Application info
  • Cache events
  • Console commands
  • Customise error report
  • Database transactions
  • Dumps
  • Errors when tracing
  • Exception context
  • External http requests
  • Filesystem operations
  • Git information
  • Glows
  • Identifying users
  • Jobs and queues
  • Laravel context
  • Livewire
  • Logs
  • Queries
  • Redis commands
  • Requests
  • Server info
  • Solutions
  • Spans
  • Stacktrace arguments
  • Views
  • Older Packages
  • Laravel Flare V1
  • Ignition

Ignoring collected data

Ignoring exceptions

By default, all exceptions will be reported to Flare. You can change this behaviour by filtering the exceptions with a callable:

use \Spatie\LaravelFlare\Facades\Flare;

Flare::filterExceptionsUsing(
    fn(Throwable $throwable) =>  !$throwable instanceof AuthorizationException
);

Ignoring reports

Additionally, you can provide a callable to the Flare::filterReportsUsing method to stop a report from being sent to Flare. Compared to filterExceptionsCallable, this can also prevent logs and errors from being sent.

Flare::filterReportsUsing(function(Report $report)  {
    // return a boolean to control whether the report should be sent to Flare
    return true;
});

Ignoring errors

Finally, it is also possible to set the levels of errors reported to Flare as such:

Flare::reportErrorLevels(E_ALL & ~E_NOTICE); // Will send all errors except E_NOTICE errors

Ignoring spans

At the moment, it is not possible to filter out spans since they depend on each other. Removing spans would break the inheritance required for performance monitoring.

Ignoring Flare data collection

Flare collects a lot of data by default. We define many types of collects (queries, requests, etc.) that are sent to Flare. You can ignore these collects in the collects key in your flare.php config file.

Censoring collected data Laravel Octane
  • On this page
  • Ignoring exceptions
  • Ignoring reports
  • Ignoring errors
  • Ignoring spans
  • Ignoring Flare data collection

Monitor your web apps and sites from errors to slowdowns with Flare, the easiest application monitoring platform for Laravel, PHP & Javascript.

  • Platform
  • Error Tracking
  • Performance Monitoring
  • Pricing
  • Support
  • Resources
  • Blog
  • Changelog
  • Documentation
  • Affiliate program
  • Service status
  • Terms of use
  • DPA
  • Privacy & Cookie Policy
Flare