3

I have set up an eCommerce data funnel on Google Tag Manager/Analytics. For the tunnel I have used recommended events like:

begin_checkout
add_payment_info
add_shipping_info
purchase

The problem with the tunnel is that it does not relay data if the customer has previously completed the shipping form and is logged in.

my question is this - is there a way to determine whether the customer is logged and previously completed the shipping form.

I do not want to take the add_shipping_info event out of the funnel

2 Answers 2

3

If you're having issues with your eCommerce funnel in Google Analytics when users are logged in and have already completed the shipping form, here's a fix.

You can set up a custom dimension or event in Google Tag Manager to track if a user is logged in and has already filled out the shipping form. You'd set a flag when the form is completed and check this flag before firing the add_shipping_info event. If the form's already done, the event won't trigger again, keeping your funnel clean without duplicating data.

Here's a quick example:

  // Example code to check the flag
if (!sessionStorage.getItem('shippingInfoCompleted')) {
    dataLayer.push({
        'event': 'add_shipping_info'
    });
}

Also, consider passing the user_id parameter in Google Analytics to better identify logged-in users and fine-tune your reports. This way, you can create specific audiences and improve your funnel analysis.

2

Funnel Issues

If there is an issue with the tags that you created for building the funnel, I would look into the firing conditions. By default, unless you are specifying in the triggers not to fire for logged in / already completed, it should still be firing for those users in the event count. The only time it wouldn't be tracking is if you have selected "Once per user" in the key event.

ID'ing Logged in Users

If you are dealing with logged in users, you can pass the information over to GA4 in the user_id property. If you pass this parameter with the event, you will now have access to a new dimention: Signed in with ID Y/N value. Google has good documentation on passing this value and the do's and don'ts.

Audience Triggers

If you are looking to categorize users of past events, you can create specific audiences based on whether they have completed events or not. I suspect you can pair this with your funnel (and hopefully the above signed in parameter) to tailor your report to your needed. There is some documentation on Audiences from Google.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.