Magento 2 Admin Log & Audit Trail

Admin Activity Log

Free Magento 2 admin log and audit trail: field-level change history, admin login history, active session control, security notifications and an admin IP allowlist.

  • Magento 2.4.6 – 2.4.9
  • PHP 8.2 – 8.5
  • Hyvä and Luma
  • Version 2.0.3

Free

No payment needed, with 12 months of updates.

Add it to your cart and complete the free checkout. Your ZIP downloads and Composer access will be in your account.

What is included

  • Install with Composer, or download a zip from your account
  • Licence for one production domain, staging and development copies included

No subscription or automatic renewal. Keep using the versions included in your update period. Update and licence details

Key features

  • Field-level change history (old and new value)
  • Catalog, CMS, customers, sales, price rules, configuration and admin users
  • Mass actions and imports logged
See all features

Composer package commercegears/module-admin-activity-log

Admin Activity Log Free

"Who changed this price?" is a question every Magento team asks sooner or later, and Magento Open Source keeps no record that answers it (Adobe Commerce has its own action log). This free admin activity log for Magento 2 records who changed what in the admin, field by field with the old and the new value, plus every admin sign-in, the active sessions and alerts for suspicious sign-ins.

What the admin log records

  • Changes. Products, categories, CMS pages and blocks, customers, orders and their documents, cart and catalog price rules, configuration (also from bin/magento config:set), admin users and roles, mass actions and imports.
  • Sign-ins. Successful and failed sign-ins with the reason, lockouts and sign-outs, and the country when Cloudflare is in front of the store.
  • Sessions. The admin users signed in right now, with Terminate.

Security, not just history

You get alerts for repeated failed sign-ins and for sign-ins from a new IP or country, and an optional admin IP allowlist (IPv4, IPv6 and CIDR ranges) with a CLI way back in. Passwords, tokens and API keys are always masked in the log, and a daily clean-up keeps it to the number of days you choose.

  • Answer "who changed this?"

    Every admin change is recorded with the admin user, time, IP address and the old and new value of each field.

  • Spot attacks early

    Repeated failed sign-ins, account lockouts and sign-ins from a new IP address or country raise an alert by email and in the admin.

  • Light on the admin

    Tracking runs in the admin only, uses data Magento has already loaded and writes the entries in one insert at the end of the request.

All features

What is included

What is logged

  • Products, categories (including moves), CMS pages and blocks
  • Customers, orders, invoices, shipments, credit memos and comments
  • Cart and catalog price rules
  • Configuration, also from bin/magento config:set
  • Admin users, roles and permissions, mass actions and imports

Sign-ins and sessions

  • Successful and failed sign-ins with the reason
  • Lockouts, blocked IPs and sign-outs
  • Country from Cloudflare's CF-IPCountry header
  • Active sessions grid with Terminate and mass Terminate

Security

  • Alerts for failed sign-ins from one IP and for lockouts
  • Alerts for sign-ins from a new IP or country
  • Admin IP allowlist with single IPs and CIDR ranges, IPv4 and IPv6
  • Passwords, tokens and API keys stored masked
  • Changes to the log settings kept by the clean-up

Admin and developers

  • Retention in days with a daily clean-up
  • Exclusions by entity type and configuration path
  • Separate ACL permissions
  • CLI: clean and allowlist
  • Extension point for your own entities

Feature tour

Everything your shoppers and your team see

01 / 06

Every change in one grid

Save, Delete and mass actions, named as in Adobe Commerce, with admin user, entity, changed fields and IP address. Filters right under the column headings, keyword search, saved views and CSV or XML export.

02 / 06

Old and new value per field

Each entry shows exactly which fields changed, with a link to the record and to other changes made in the same request.

03 / 06

Every sign-in and failed attempt

Successful and failed sign-ins with the reason, lockouts, sign-ins blocked by the allowlist and sign-outs, with IP address and browser.

04 / 06

See who is signed in now

Every admin session with IP address, browser, sign-in time and last activity. Terminate one or several; the admin is signed out on their next click.

05 / 06

Alerts you can tune

Choose the failed sign-in threshold and time window, new IP and new country alerts, recipients and email templates.

06 / 06

Retention and IP source

Switch each log on or off, choose how long entries are kept and whether the client IP comes from the web server or Cloudflare.

Live demo

Try it before you install it

A full Magento store with the module installed, on Luma and on Hyvä. The admin demo signs you in with one click.

Compatibility

Requirements and compatibility

Compatibility of Admin Activity Log
Magento2.4.6 – 2.4.9
PlatformsMagento Open Source and Adobe Commerce
Storefront themes Luma Blank Hyvä
PHP8.2 – 8.5
Latest version 2.0.3
composer.json requires php ~8.2.0||~8.3.0||~8.4.0||~8.5.0 magento/framework ~103.0.6 commercegears/module-core ^2.0 free, installed by Composer with this module magento/module-admin-notification * magento/module-authorization * magento/module-backend * magento/module-config * magento/module-cron * magento/module-email * magento/module-security * magento/module-store * magento/module-ui * magento/module-user *

Installation

Up and running in minutes

Get it free, create a Composer key in your account, then in the root of your Magento project:

  1. 01Add the repository and your key (once per project)

    composer config repositories.commercegears composer https://repo.commercegears.com
    composer config --auth http-basic.repo.commercegears.com PUBLIC_KEY PRIVATE_KEY
  2. 02Install the module

    composer require commercegears/module-admin-activity-log
  3. 03Enable it

    bin/magento setup:upgrade
    bin/magento setup:di:compile
    bin/magento setup:static-content:deploy
    bin/magento cache:flush

    The last three are only needed in production mode.

Prefer a zip? Every version you are entitled to can be downloaded from My modules. More about Composer access

User guide

Setting up Magento 2 Admin Log & Audit Trail

The user guide has its own page: how to install Magento 2 Admin Log & Audit Trail, what each option does and how to use it in your store. Written for version 2.0.3; a copy ships with the module.

In the guide

Read the user guide

Changelog

Release notes

2.0.3

Latest
  • Improvement: the module is now free.

2.0.2

  • Improvement: compatible with Magento 2.4.6 (PHP 8.2).

2.0.1

  • Improvement: user guide screenshots and links updated for the CommerceGears name

2.0.0

  • Improvement: renamed to CommerceGears (new Composer package, admin menu and settings paths)

FAQ

Questions, answered

Something else on your mind? The developers who wrote the module answer before and after you buy.

Ask a question →

Already installed it? Open a support ticket

What does the module record?

Changes made in the Magento admin (create, update and delete with the old and new value of each field), every admin sign-in attempt and sign-out, and the admin sessions that are active right now.

Which records are covered?

Products, categories (including moves in the category tree), CMS pages and blocks, customers, orders, invoices, shipments, credit memos, order and document comments, cart price rules, catalog price rules, configuration, admin users, admin roles and role permissions. Grid mass actions, the product "Update attributes" action and imports under System > Data Transfer > Import are logged too.

Are changes made outside the admin logged?

Configuration changes made with bin/magento config:set are. Changes through the REST or SOAP API, cron jobs, command-line imports and direct SQL are not. Records that Magento or other extensions write with direct SQL (for example some stock updates) only appear as the mass action that started them.

Are passwords and API keys stored in the log?

No. Passwords, tokens, API, private and licence keys, card fields, hashes, encrypted configuration fields and configuration paths Magento declares sensitive are stored as **, so you still see that they changed. A failed sign-in with an unknown username that looks like a password is stored partly masked.

Does it slow down the admin?

Tracking only runs in the admin area. The diff is built from data Magento has already loaded, the entries are kept in memory and written with one multi-row insert at the end of the request, and nothing is written if the database transaction is rolled back. The storefront is not affected.

How long are entries kept?

90 days by default. A daily cron job deletes older entries in batches; set 0 to keep everything. Changes to the Activity Log's own settings are always kept, so shortening the retention or switching logging off stays on record.

Can I leave some records or settings out?

Yes. Under Exclusions choose entity types that are never logged, and list configuration paths (with * wildcards, for example design/*) that are never logged.

Which alerts are there?

A number of failed sign-ins from one IP address within a number of minutes (default 5 within 15), lockouts of an admin account, and sign-ins from an IP address or country the admin has not used before. Alerts go to the admin notification inbox and, if you enter recipients, by email. The new IP and new country alert can also go to the admin user's own email address.

How does the country detection work?

From Cloudflare's CF-IPCountry header. New country alerts and the country column therefore need the store to be behind Cloudflare with IP geolocation switched on.

Can I end another admin's session?

Yes, under Active Sessions with Terminate (single or mass action). The admin is signed out on their next click. Your own session cannot be terminated; use Sign Out instead.

How does the IP allowlist work, and can I lock myself out?

When the allowlist is on, only the listed IP addresses and CIDR ranges (IPv4 and IPv6) can sign in and use the admin. The module refuses to save a list that does not include your current IP address. If you are locked out anyway, for example after your IP address changed, run bin/magento commercegears:activity-log:allowlist --disable on the server.

My store is behind Cloudflare and the log shows Cloudflare IP addresses. What should I do?

Either configure the web server to pass the real visitor IP (for example nginx real_ip with Cloudflare's ranges), or set "Client IP Address From" to Cloudflare. The CF-Connecting-IP header is then trusted only on requests that come from Cloudflare's published address ranges.

Can I export the log?

Yes. The Admin Actions and Login Log grids export to CSV and XML, with the filters you have set.

Why do older entries show "Save" and "Mass Update" after updating to 1.4.0?

Since 1.4.0 the action names follow the Adobe Commerce action log ("Save" instead of "Create" and "Update", "Mass Update" and "Mass Delete" instead of "Mass action", "Login" and "Logout" in the Login Log). bin/magento setup:upgrade converts the stored mass action and order Cancel / Hold / Unhold entries, so filters and exports use the same names for old and new entries.

Which Magento and PHP versions are supported?

Magento Open Source and Adobe Commerce 2.4.6 to 2.4.9, PHP 8.2 to 8.5 (Magento 2.4.6: PHP 8.2). The module is admin only.

Is Admin Activity Log free?

Yes. Admin Activity Log is free to download from commercegears.com and is installed with Composer like our other modules. It needs commercegears/module-core, which Composer installs automatically.

Support

Help from the developers who wrote it

Need more?

Keep a record of customer consent and data requests too

GDPR Data Rights adds consent checkboxes with a consent log, a versioned privacy policy, a privacy tab in My Account and a request desk with a reply timer, with anonymisation that keeps your orders intact.

See GDPR Data Rights →

What GDPR Data Rights does

  • Consent checkboxes on registration, account, contact, newsletter and checkout
  • Consent log with policy version, store view, date and a hashed IP
  • Versioned privacy policy with an accept window and change e-mails
  • My Account privacy tab: download, consents, anonymise, ask for deletion

From the blog

Guides and articles