Traditional Method
Add the below code to the admin > online store > preferences > Google Analytics > Additional Google Analytics Javascript section
//Start of Checkout Steps for ee labelling window.localStorage.setItem("ecommercetrackingcartstep", 1); var ShopifyCheckoutstep = Shopify.Checkout.step; switch (ShopifyCheckoutstep) { case "contact_information": ga("require", "ec"); ga("ec:setAction", "checkout", { "step": 1, "option": "" }); ga('send', 'event', 'Checkout', 'Option'); break; case "shipping_method": ga("require", "ec"); ga("ec:setAction", "checkout", { "step": 2, "option": "" }); ga('send', 'event', 'Checkout', 'Option'); break; case "payment_method": ga("require", "ec"); ga("ec:setAction", "checkout", { "step": 3, "option": "" }); ga('send', 'event', 'Checkout', 'Option'); } //End of Checkout Steps for ee labelling
Data Layer Method (for Shopify Plus Only)
Add Checkout Labelling in Google Analytics > Admin > View > E-commerce Settings > Enhanced E-commerce Settings if you would like to rename the steps
//Start of Checkout Steps for ee labelling window.dataLayer = window.dataLayer || []; window.localStorage.setItem("ecommercetrackingcartstep", 1); var ShopifyCheckoutstep = Shopify.Checkout.step; switch (ShopifyCheckoutstep) { case "contact_information": dataLayer.push({ 'event': 'checkout', 'ecommerce': { 'checkout': { 'actionField': {'step': 2, 'option': ""} } } }); break; case "shipping_method": dataLayer.push({ 'event': 'checkout', 'ecommerce': { 'checkout': { 'actionField': {'step': 3, 'option': ""} } } }); break; case "payment_method": dataLayer.push({ 'event': 'checkout', 'ecommerce': { 'checkout': { 'actionField': {'step': 4, 'option': ""} } } }); } //End of Checkout Steps for ee labelling
The data will then be available to view in Analytics > Conversions > E-Commerce > Checkout Behaviour