Przejdź do głównej zawartości

Commerce events: auto or manual

Ta treść nie jest jeszcze dostępna w Twoim języku.

Commerce events are things like “viewed a product”, “added to cart”, “started checkout” and “placed an order”. The funnel is built from them. The commerce option of init sets where they come from:

auto (the default) manual
Where events come from Detected: your GA4 dataLayer, page types, add-to-cart buttons and requests, your own rules Only your qm.commerce calls
qm.commerce calls Ignored Sent, exactly as written
Code needed None One call per event
Best for Shops that already send GA4 e-commerce events, and shops on WooCommerce, PrestaShop or Shopify Custom shops that want full control and exact data
qm("init", { key: "pk_live_…" }); // auto
qm("init", { key: "pk_live_…", commerce: "manual" }); // manual
  • Only your code sets the mode. Install & setup shows which mode your pages use, and warns if it changed in the last 7 days.
  • Custom events and everything recorded automatically work in both modes.
  • auto mode cannot see everything: no payment redirect, payment return or rejected coupon. See Auto mode.
  • A buyer who closes the tab on the payment page never reaches your confirmation page, so no order is sent in either mode.
  • Your shop pushes GA4 e-commerce events? Use auto. You are done.
  • WooCommerce, PrestaShop or Shopify without GA4 e-commerce? Start with auto and add your own rules for what is missing.
  • You build the shop yourself and can add a line of code per event? Use manual for full product, cart and order data.