← All modules
Documentation Blog Sign in to your licenses Contact
codingrow.com — Human thought, digital logic. Magento 2 · Google Tag Manager · GA4

The container, the data layer, and the sales Analytics was losing

Your store starts speaking GA4: fourteen ecommerce events built on the server from the real cart and the real order, never read off the page. Works on Hyvä and Luma, on the standard checkout and on the ones that answer on their own route. The container and the four core events cost nothing.

Container and core events

The Google Tag Manager container plus the four events every shop needs: product page, cart, checkout and purchase. No key to paste: it activates by itself for your domain.

Free Container and core events — no key to enter, no payment: they activate automatically on your domain.

We only use your email to send you the download credentials and installation instructions and to create your customer area. Privacy and cookies

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Shopping events

€149.00 + VAT
Indicative total, incl. Italian VAT: €181.78 — the exact amount is calculated at checkout and is waived for EU business buyers with a valid VAT number (reverse charge).

Ten more events, custom dimensions, Google Consent Mode v2 and the recovery of the purchases that never reach Analytics. One payment, one domain, perpetual licence with a year of updates and support.

After the payment you receive, by email, the credentials for the Composer repository and the key for the shopping events.

One licence, one domain, with a year of updates & support included (renew at −35% to keep installing newer releases). The core level keeps working even without the key, so a shop is never left without tracking.

Magento 2.4.x, PHP 8.1 to 8.5, Hyvä or Luma. Installed with Composer, from our repository.

Fourteen events, and where each one comes from

Every event is built on the server from what the shop really has: prices with or without tax as you choose, the attribute you use as the product id, the product categories. Nothing is scraped from the page, so a theme change cannot break it.

Free

  • view_item — the product page
  • view_cart — the cart
  • begin_checkout — the checkout
  • purchase — the thank-you page, with the real order

With the shopping events

  • view_item_list — category and search results
  • select_item — a click on a product in a list
  • add_to_cart and remove_from_cart — the real cart line
  • search — the term searched and how many results it gave
  • add_to_wishlist
  • add_shipping_info and add_payment_info — from inside Magento, on any checkout
  • login and sign_up

The container, already set up

A data layer nobody reads looks like a broken module: until the container has a tag that reads it, nothing reaches Analytics. So a button in the configuration downloads a file to import into Google Tag Manager, with the GA4 configuration tag, the tag that forwards the ecommerce events, the Google Ads purchase conversion carrying the real revenue and the order number, the conversion linker and the variables they need. You import it choosing Merge, look at the preview, publish. The alternative is building some thirty objects by hand.

The purchases Analytics never saw

Roughly one purchase in five never reaches Analytics: an ad blocker, a script that failed, a customer who closes the page too early. Those are sales you made and cannot see, and Google optimises your campaigns without them. With the shopping events the store sends the purchase itself when the browser did not, carrying the identifier that customer had at the time, so the sale lands on the visit and the ad that brought it gets the credit. A panel in the configuration counts them for you: orders, the ones the browser confirmed, the ones the store recovered. And whoever refused to be measured is never recovered.

On a shop we run ourselves: 27 real orders in thirty days, 21 purchases in Analytics. Six sales invisible to the campaigns that paid for them.

Consent Mode v2, in the right place

In Europe a declared consent state is what lets Google model the conversions it did not observe: without it, that data is simply lost. The module declares everything denied before the container starts — which only whoever loads the container can do — and from there you choose: either it grants consent from Magento's own cookie notice, or it waits for your consent extension to call one public function. A line in the configuration tells you which of the two is really happening, and turns red when the setup cannot work.

What you get

Admin in your language

Every field and every explanation in the configuration is translated — including the ones that tell you what not to do:

English Italiano Español Français Deutsch Português Nederlands

The store view language is picked up automatically; English is the fallback.

Requirements

Magento 2.4.x (Open Source or Adobe Commerce), PHP 8.1 to 8.5, Hyvä or Luma. A Google Tag Manager container, which is free. For the recovery of lost purchases, a Measurement Protocol API secret from your own GA4 property.

Documentation

Installation, every field explained, how to import the container and how to check that an event really arrives in Analytics.

→ Read the full documentation

Changelog

What changes, version by version.

v1.4.0New
  • A Google consent group: declare the state before the container starts, or leave the update to your banner.
  • Recover the purchases that get lost: the store sends the sale Analytics never received.
  • A panel counting orders, the ones the browser confirmed and the ones the store recovered.
  • Ten more events, custom dimensions, addresses to leave out and the statuses that count as a sale.