Weave 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 Flare Laravel Package

spatie/laravel-flare

Send Laravel errors to Flare. With a valid Flare API key, production errors are tracked and you're notified when they happen. Works with Laravel 11+ on PHP 8.2+, and pairs with spatie/laravel-ignition for beautiful error pages.

View on GitHub
Deep Wiki
Context7

Technical Evaluation

Architecture fit

  • This is not a standalone error handler; it is the first-party Laravel SDK that ships errors, logs, and traces to Flare, Spatie's commercial error-tracking SaaS. The package is a thin Laravel integration layer over spatie/flare-client-php (^3.0 constraint in v3), so the runtime behavior you inherit is largely the client's, not the wrapper's.
  • Integration surface is idiomatic Laravel: a service provider with publishable config/flare.php, env-driven configuration (FLARE_KEY), a custom Monolog channel ('flare') that can be dropped into LOG_STACK, middleware (FlareTracingMiddleware) for request tracing, plus console/queue recorders. That means it fits any conventional Laravel app without touching application code paths — no manual report() calls required for the error path.
  • v3.0 is a substantial architectural repositioning: logs became a first-class signal recorded in OpenTelemetry log format, sampling (RateSampler, DynamicSampler) was added with Laravel-aware rules (route name, route action, queue name, queue connection), and two sender strategies exist (LaravelHttpSender default, DaemonSender for local daemon routing). Meanwhile, error solutions support and reportMessage() were removed. A TPM should treat v3 as a new product surface, not a patch.
  • Operationally relevant platform coverage is real and evidenced in the changelog: Octane (2.0.7), Vapor (2.1.0, 2.2.4), Livewire tracing including v4 and SFCs (2.4.0, 2.7.0, 2.8.0), sync-queue context preservation (2.2.0), streamed HTTP response handling (2.2.3), and a configuring() hook to mutate FlareConfig before boot (3.1.1).

Integration feasibility

  • Low mechanical effort: composer require spatie/laravel-flare, publish config, set the key, optionally add flare to the log stack. Realistic estimate is hours for a working error feed, 1–2 engineer-days including configuration hardening and verification.
  • The actual work is governance, not code: deciding what leaves your perimeter. The package can collect request bodies, cookies, session data, query bindings, route metadata, and git metadata. v2.6.2 added cookie/session censoring and v3.3.0 added max_attribute_size_in_kb — both are acknowledgements that default payloads are sensitive and can be large.
  • A vendor "test command" exists (referenced in 2.6.1, which fixed it early-returning before checking all report callbacks) — use it as the acceptance gate in each environment rather than assuming a green deploy means events are landing.

Technical risk

  • Commercial coupling. The package is MIT and free; the service it talks to is not. Value realization depends entirely on a Flare subscription, an API key, and egress to Flare's ingest endpoints. That is a procurement and vendor-risk item, not an OSS one.
  • Support-matrix inconsistency. The README states Laravel 11+ / PHP 8.2+, while v3.0.0 notes require Laravel 11.47+ / 12.42+ / 13+, and 3.2.0's changelog says "Add Laravel 10 support." These cannot all be true simultaneously. Any team pinning framework minors must verify against the actual composer.json, not the prose.
  • Breaking-change velocity. The 1.x → 2.x → 3.x progression includes a full config-file replacement, removal of reportMessage() and the spatie/error-solutions dependency. Teams that adopted 2.x APIs will need scheduled remediation work.
  • Test fidelity. The test suite has integration tests that require a running workbench server and a queue worker; --exclude-group=integration runs only unit tests. If your CI runs the fast path, the actual send pipeline is effectively untested — a genuine risk for a package whose entire job is a network side effect.
  • Adoption signal is misleading. 13 stars and 0 dependents looks alarming, but this is a vendor SDK where installs flow through Packagist and Flare's docs, not GitHub stars. The overall score of 30.4 is being dragged down by popularity heuristics that don't apply; the 65.66 opportunity sub-score is the more honest read. Do not dismiss it on stars alone, and do not adopt it on stars either.
  • Blind-spot failure mode by design. Since 2.0.6, Flare fully disables itself when no key is set. Correct behavior, but it means a missing env var in a new environment produces silence, not an error.

Key questions

  1. Which signals do we actually need — errors only, or logs and performance traces too? v3 bundles all three, and each expands the data egress surface and the quota burn.
  2. Has Security/Legal signed off on transmitting request bodies, cookies, session identifiers, and query bindings (which may contain PII) to a third-party processor? Do we have a DPA?
  3. Are we already running Sentry, Bugsnag, or CloudWatch? If so, what does Flare replace, and is duplicated spend justified by the Laravel-native tracing quality?
  4. What is our monthly error/log event volume against the Flare plan tier, and what sampling policy will we commit to?
  5. Who owns key provisioning and rotation, and is the key segregated per environment?
  6. If we exit Flare in 18 months, what is the migration cost — are we writing against reportMessage()-style APIs (removed in v3) or relying on standard Monolog channels that survive a swap?

Integration Approach

Stack fit

  • Requires PHP 8.2+ and a modern Laravel (11.47+/12.42+/13+ per the v3 release notes; 3.2.0 claims Laravel 10). Assumes standard Laravel exception handling, the container, Monolog, and — for traces — HTTP middleware registration.
  • Complements rather than replaces spatie/laravel-ignition; the README explicitly says you can install both, with Ignition serving local developer error pages and Flare handling production reporting. Keep that split; do not let Flare's presence change local DX.
  • Strong fit if you are on Octane, Vapor, Horizon, or Livewire — those are the paths the changelog shows active hardening on. Weaker differentiator if you are a plain FPM app already instrumented with an OpenTelemetry collector.

Migration path

  • From nothing / Ignition only: additive. Install, configure, verify with the test command, ship errors first. Lowest-risk entry.
  • From 2.x of this package: treat as a project, not a bump. Config file must be replaced, reportMessage() call sites must be rewritten onto the flare log channel, and error-solutions middleware/config keys removed. Follow UPGRADING.md explicitly.
  • From Sentry/Bugsnag: run parallel, not cutover. Fan out the log stack and register both handlers, compare capture rates and grouping quality on the same traffic for two to four weeks, then retire the incumbent per environment. Payload differences (especially Flare's solution-less v3) will surface during this window, which is exactly when you want them to.

Compatibility

  • Verify the installed framework minor against the v3 constraint before committing — a Laravel 11.20 app is not covered by "Laravel 11+".
  • Confirm spatie/flare-client-php ^3.0 resolves cleanly against existing Spatie packages; 2.0.1's "Use correct dependency" fix shows this coupling has broken before.
  • Livewire v4 and SFC tracing require 2.7.0+/2.8.0+ — check if your instrumentation story depends on it.
  • Run the integration test group in at least one CI lane (vendor/bin/testbench serve + queue:work) so the send path is actually exercised.

Sequencing

  1. Install in a non-production environment with a scoped API key; publish and review the full config file before setting any env values.
  2. Configure censoring (cookies, session), minimal_log_level, and max_attribute_size_in_kb before the first event ships. Retrofitting redaction after data is in a vendor dashboard is not fully reversible.
  3. Enable error reporting only. Validate grouping, notification routing, and the test command.
  4. Add the flare channel to LOG_STACK on staging and observe volume and cost impact for a week.
  5. Introduce tracing with an explicit sampler (RateSampler initially; DynamicSampler once you know which routes and queues are noisy).
  6. Production rollout behind an env flag, starting with a low-traffic or canary service.
  7. Tune sampling and log level against actual quota consumption; document the runbook and the disable switch.

Operational Impact

Maintenance

  • Vendor-maintained with an unusually dense release cadence — dozens of patches across 2.x, three majors, and active 3.x feature work (3.3.0 in the last cycle). This is a live project, not abandoned.
  • The maintenance burden on you is upgrade tracking, not code ownership. Budget a recurring line item for major-version migrations; the 2.x → 3.x delta alone (config replacement, removed APIs) is a real sprint fragment.
  • MIT license removes legal friction on the code, but the operational dependency is the SaaS contract. Renewal, seat count, and quota negotiation are the durable maintenance costs.

Support

  • Two distinct support channels, and conflating them is a common planning error: community/vendor support for the package, contractual SLA for the Flare service. The repo gives you no SLA.
  • With 13 stars and 0 dependents, there is essentially no third-party knowledge base, no Stack Overflow corpus, and no peer benchmark. Escalation is directly to Spatie/Flare. That is acceptable for a commercial relationship but should be reflected in expectations for time-to-resolution on obscure instrumentation bugs.
  • Changelog quality is genuinely good — issues, PR numbers, and fix descriptions are traceable (e.g. "Guard FlareTracingMiddleware::terminate against uninitialized request"). That materially shortens triage when something breaks after an upgrade.

Scaling

  • Default LaravelHttpSender sends over HTTP. At high error volume, or during an error storm, this competes for request/worker time. Evaluate DaemonSender or route sends off the request path before scaling traffic, and confirm fail-open behavior under ingest latency.
  • Sampling is the primary cost and volume lever. DynamicSampler with route-action and queue rules lets you drop health-check and high-frequency job noise while keeping the long tail. Do this before the first quota overage, not after.
  • Octane compatibility is addressed, but per-worker context and the sync-queue context fix (2.2.0) mean you should regression-test under your actual queue topology, not just a default FPM setup.
  • Payload size is a scaling concern on both ends — max_attribute_size_in_kb caps trace attributes, but large request bodies and query bindings remain the usual cause of oversized events and truncated context.

Failure modes

  • Silent disable: no key means no Flare, no warning. Add an explicit startup assertion or health check that the key is present in every environment that should report.
  • Ingest outage / egress block: errors lost, potentially latency added at the worst moment. Verify the client fails open and that a network policy change cannot turn observability into an availability incident.
  • Sampler misconfiguration: the most dangerous failure because it is quiet and selective. An overly aggressive rate can drop exactly the rare exception you needed. Review sampler rules after every major release.
  • PII leakage into the dashboard: irreversible once ingested. Censoring config must be reviewed by Security, not just engineering.
  • Double-shipping: flare added to LOG_STACK alongside existing handlers can duplicate volume and inflate cost; confirm intent before fanning out.
  • Version drift: a framework upgrade outside the supported minor range can silently degrade instrumentation (missing route metadata, broken Livewire traces) without throwing. Pin and test.
  • Queue worker gaps: traces for queued jobs depend on workers actually resolving the package's recorders; a worker running an older container image will produce partial traces that look like missing data.

Ramp-up

  • Install and first useful error feed: under a day for an experienced Laravel engineer.
  • Productive use of traces, sampling rules, and log-level tuning: roughly one to two weeks of iteration against real traffic.
  • Organizational ramp-up is the longer pole: on-call needs to know Flare is now a first-class observability dependency with its own runbook and disable switch; Security needs to re-review the egress payload whenever the collector config changes; Finance needs a quota owner.
  • Net TPM read: low technical risk, low integration cost, and a favorable opportunity score — but the decision hinges on commercial and data-governance questions, not on the 13 stars. Approve as a pilot on one service with redaction configured and sampling defined up front, and gate general rollout on security sign-off and a measured quota.
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.
gmostafa/php-graphql-client
xeviant/paystack
snowsoft/faker
meditationsteps/blogetc
animalyoung/laravel-influxdb
onix-solutions/sms-telera
lonely-lights/prosetta
oxygen/data
oxygen/core
jengo/base
xiloryx/log-collector
a21ns1g4ts/filament-stripe
la-php/laravel-admin
artisan-build/community-prompts
vleroy/smart
ayles-software/laravel-australian-public-holidays
cboxdk/laravel-id-spatie
cboxdk/laravel-id-billing
cboxdk/laravel-id-billing-bridge
simple-as-fuck/php-performance-log