alfrasc/laravel-matomo-tracker
Server-side Matomo analytics for Laravel. Track page views, events, goals, and e-commerce without client-side JavaScript, with a fluent API, configurable sites, and user attribution.
matomo/php-tracker. The real build-vs-buy call is Matomo (self-hosted, no per-event cost, ops burden) vs. a managed vendor (GA4, Plausible, PostHog). This package only reduces the integration cost of the Matomo branch to near zero — it should not itself be treated as a strategic asset.Consider it when:
Look elsewhere when:
matomo/php-tracker (which has a clear license) rather than depend on this repo.Adoption criteria, in order: (1) license cleared; (2) Matomo already deployed or budgeted; (3) package vendored/forked with a named internal owner and a test suite; (4) PHP/Laravel version compatibility verified by you, not assumed; (5) a plan for what happens if the maintainer disappears — which, realistically, is "we already forked it."
To executives (one paragraph): We can capture analytics and conversion data on the server — including payments and renewals that browser-based tracking misses — while keeping all data in infrastructure we control, with no per-event fees and a much stronger GDPR position than a US-hosted analytics vendor. The integration cost is small, but the library itself is a thin, unmaintained wrapper with an unclear license, so the honest framing is: this validates the Matomo direction, not the dependency. Recommendation is to treat it as a reference implementation — spend a short spike confirming it works on our stack, then own a small internal adapter. That keeps the strategic benefits (data sovereignty, no vendor lock-in, accurate conversion counts) and removes the supply-chain and maintenance risk.
To engineering (summary):
matomo/php-tracker's HTTP API: config publish, tracker singleton, MatomoTracker calls for page views, events, goals, e-commerce, custom dimensions, and user ID.matomo/php-tracker (clear license, actively used) in ~1 day. Keep the facade-shaped API so call sites stay clean.How can I help you explore Laravel packages today?