-1

I am looking at the "Shopping Behaviour" data in Google Analytics and realised that there are no sessions with add to cart but there are sessions with checkout. How is that possible? A person who has attempted or completed checkout should must add product to the cart first right? Can anyone please help me understand this?GA - Shopping Behaviour Screenshot

1 Answers1

0

This is because you are sending Enhanced Ecommerce checkout interactions info to Analytics but not add to cart info.

Example to measure checkout (ecommerce --> checkout --> step --> products):

<script>
function onCheckout() {
  dataLayer.push({
    'event': 'checkout',
    'ecommerce': {
      'checkout': {
        'actionField': {'step': 1, 'option': 'Visa'},
        'products': [{
          'name': 'Triblend Android T-Shirt',
          'id': '12345',
          'price': '15.25',
          'brand': 'Google',
          'category': 'Apparel',
          'variant': 'Gray',
          'quantity': 1
       }]
     }
   },
   'eventCallback': function() {
      document.location = 'checkout.html';
   }
  });
}
</script>

https://developers.google.com/tag-manager/enhanced-ecommerce#checkoutstep

Example to measure add to cart (ecommerce --> add --> product):

dataLayer.push({
  'event': 'addToCart',
  'ecommerce': {
    'currencyCode': 'EUR',
    'add': {                                // 'add' actionFieldObject measures.
      'products': [{                        //  adding a product to a shopping cart.
        'name': 'Triblend Android T-Shirt',
        'id': '12345',
        'price': '15.25',
        'brand': 'Google',
        'category': 'Apparel',
        'variant': 'Gray',
        'quantity': 1
       }]
    }
  }
});

https://developers.google.com/tag-manager/enhanced-ecommerce#cart

Michele Pisani
  • 13,567
  • 3
  • 25
  • 42