Analytics 12 min read

Google Analytics 4 for eCommerce: Setup and Tracking Guide

By Born Digital Studio Team Malta

Google Analytics 4 is fundamentally different from Universal Analytics. Its event-based data model, cross-platform tracking, and machine learning capabilities offer powerful insights — but only if configured correctly. Many eCommerce stores are running GA4 with minimal setup, missing critical conversion data. Here is how to set it up properly.

Understanding GA4's Event Model

Unlike Universal Analytics, which tracked pageviews and sessions, GA4 treats everything as an event. Page views, clicks, purchases, and custom interactions are all events with parameters. This model is more flexible but requires intentional configuration to capture meaningful eCommerce data.

GA4 has three types of events: automatically collected events (page_view, first_visit, session_start), recommended events (those Google suggests for specific industries), and custom events you define yourself. For eCommerce, the recommended events are essential — they power the built-in Monetisation reports and audience triggers.

Essential eCommerce Events

These are the events you must implement for meaningful eCommerce analytics:

  • view_item: Fired when a user views a product detail page. Include item_id, item_name, item_category, price, and currency parameters.
  • add_to_cart: Triggered when a product is added to the cart. This is your first conversion micro-step and crucial for measuring purchase intent.
  • begin_checkout: Fired when the user initiates the checkout process. The drop-off between add_to_cart and begin_checkout reveals cart abandonment rates.
  • purchase: The most critical event. Include transaction_id, value, currency, tax, shipping, and the full items array. This powers revenue reporting and ROAS calculations.
  • view_item_list: Fired when product lists are displayed (category pages, search results). This helps you understand which product listings drive the most engagement.

Implementation with Google Tag Manager

We strongly recommend implementing GA4 eCommerce tracking through Google Tag Manager (GTM) rather than hardcoding it. GTM provides a data layer — a JavaScript object that your website pushes event data into — which GTM then forwards to GA4. This separation means marketing teams can modify tracking without developer involvement.

For Shopify stores, the data layer implementation is relatively straightforward using Shopify's built-in analytics hooks or apps like Analyzify. For WooCommerce, plugins like GTM4WP handle most of the data layer population automatically. Custom-built stores require manual data layer implementation, which is more work upfront but gives you complete control over what data is captured.

Configuring Conversions and Audiences

Once your events are flowing, mark key events as conversions in GA4's admin settings. The purchase event should always be a conversion. Consider also marking add_to_cart and begin_checkout as conversions to track your funnel progression.

Build audiences based on eCommerce behaviour: users who added to cart but did not purchase, users who purchased more than once, users who viewed specific product categories. These audiences can be shared with Google Ads for remarketing, significantly improving your ad targeting and return on ad spend.

Reports and Analysis

GA4's Monetisation reports provide purchase revenue, items purchased, and purchase journey analysis. The Explore section lets you build custom funnel reports showing drop-off at each step. Path exploration reveals the actual navigation patterns users take before purchasing. These reports are powerful but require familiarity with GA4's analysis tools.

For deeper analysis, connect GA4 to BigQuery (available on all GA4 properties for free). This exports raw event data to Google's data warehouse, enabling SQL-based analysis, custom attribution modelling, and integration with business intelligence tools. At Born Digital, we help eCommerce businesses set up GA4 properly and build the custom reports that actually inform business decisions.

Need help with analytics?

Born Digital offers expert analytics services from Malta.

Share this article

Help others discover this insight

Born Digital Studio Team

Born Digital Studio is a Malta-based digital engineering studio specialising in eCommerce, blockchain, and digital product development. We build high-performance platforms for businesses across Europe.

Have a project in mind?

If this topic resonates with your business challenges, let's talk about how we can help.