spatie/laravel-activitylog — explained in plain English
Analysis updated 2026-06-26
Add an audit log to your Laravel app so admins can see every change made to records, including the old and new values.
Automatically track when database records are created, updated, or deleted without adding logging code to every model.
Store custom context with each log entry, such as which user triggered the action and which record was affected.
Query your activity log to display a user's action history or build an admin audit dashboard.
| spatie/laravel-activitylog | tijsverkoyen/csstoinlinestyles | vimeo/psalm | |
|---|---|---|---|
| Stars | 5,834 | 5,838 | 5,840 |
| Language | PHP | PHP | PHP |
| Setup difficulty | easy | easy | moderate |
| Complexity | 2/5 | 2/5 | 3/5 |
| Audience | developer | developer | developer |
Figures from each repo's GitHub metadata at analysis time.
Requires an existing Laravel app and running a database migration to create the activity_log table.
This is a PHP package for the Laravel web framework that records what users and the system do inside your application. It stores those records in a database table called activity_log. Think of it as an audit trail: who did what, when, and to which piece of data. You can log things manually with a single line of code. You can attach context to each log entry: which database record was affected (the subject), which user caused the action (the causer), and any additional custom properties you want to store. You can then query all logged activities using a standard Laravel model. The package can also log model events automatically. When a database record is created, updated, or deleted, the package notices and writes a log entry without you needing to add any extra code. For updates, it records both the old values and the new values, so you can see exactly what changed. This makes it useful for audit logging in applications where you need to track changes to records over time. Installation is done through Composer, the standard PHP package manager. After installing, you run a database migration command to create the activity_log table. There is also an optional configuration file you can publish if you want to adjust the package behavior, such as changing the format of the ID fields to match UUIDs instead of integers. Full documentation is hosted at spatie.be. The package is maintained by Spatie, a Belgian web development agency that publishes many open source Laravel packages. It is licensed under the MIT License.
A Laravel package that automatically records what users and the system do in your app, storing an audit trail of who changed what and when in a database table.
Mainly PHP. The stack also includes PHP, Laravel, Composer.
MIT License, use freely for any purpose including commercial projects, as long as you keep the copyright notice.
Setup difficulty is rated easy, with roughly 30min to a first successful run.
Mainly developer.
This repo across BitVibe Labs
Verify against the repo before relying on details.