In our last article, we highlighted how Apple’s ITP impacted (1) macOS Safari browser and (2) iOS Safari browser by effectively decreasing Returning Users in Google Analytics.

And then Apple launched iOS 14 in September 2020, they increased the impact of (2) by enforcing ITP on all browsers, not just Safari.

Since Chrome is the most popular browser in iOS outside of Safari, we can study the impact:


Universal Analytics (UA/GA)

By Cookie / Device ID

Google Analytics tracks users using a cookie or device ID (aka Client ID). If you, for example, use another browser to access the same website, you are considered a different user in GA. Cross-device tracking using Client ID is impossible.

By User ID

If your website provide user logins, you can stitch the User ID and Client ID together in a User-ID view in GA. Essentially, this view only has data from logged-in users. Cross-device tracking is possible when users are logged in.

By Google Signals

Another method is to enable Google Signals for your GA…


Lazy loading is a technique of delaying load of webpage resources until they are actually needed to improve page load performance. This is often used for images and videos.

GTM can automatically track lazy-loaded YouTube videos. If it’s not working for you, it’s most probably due to the way the lazy loading was done.

In order for GTM to track lazy-loaded YouTube videos, the iframe needs to be initially loaded with “youtube.com” or “youtu.be” in the src.

For example, this will NOT work:

//Initial load - iframe with no src
<div id="videoItem"><iframe></iframe></div>
//Lazy load - iframe is later updated with…

In part 1, we talked about the web tracking information flow and how the web server is required to output the structured data (data layer) to the browser. So what exactly is the data layer?

First, a quick and simplified introduction to JavaScript variables. Say you want to store the names and ages of two people. You could have these JS variables:

name1 = “Steve”;
name2 = “Alex”;
age1 = 25;
age2 = 22;

But having a variable for every value is not very scalable. We can improve this by using array variables:

names = ["Steve", "Alex"];
ages = [25…

Google Analytics 4 (GA4), formerly known as App + Web, was launched in late 2019 and we have been encouraged to dual-tag Universal Analytics (UA) and GA4 on websites in order to start experience it.

New technology is good and all, but at the time, I did not quite see what the real benefits were for the users.

After implementing GA4 on a few websites, I’m starting to see it now. Let me share with you what I experienced, so far.

Simplified Set Up

UA has Views where the data buckets sit:


When your web browser requests a webpage from a web server, the server returns information that is more than meet the eyes.


What happens when the users log out?

One popular use of session-scoped custom dimension is to record logged-in user info. For example:

  • User ID (empty means not logged in)
  • Login Status (values can be logged in / not logged in)

However, we need to ask the question — What happens when the user manually logs out during a session? Should the custom dimension value be updated?

When it comes to recording logged-in user info, we need to ask the right questions:

  • Are we trying to find out the LAST login status of each session? In this case then yes, you…

Get rid of PII

There are currently 2 methods that you can use to delete unwanted data such as Personally Identifiable Information (PII) in Google Analytics:

1. Data Deletion Requests

In GA Property admin, you should see this option:


The biggest impact of Apple’s ITP (so far) occured when ITP 2.1 was released to Safari browsers in late March 2019 which limits client-side cookies to a maximum storage of 7 days.

In short, this means tracking pixels on websites such as Google Analytics and marketing tags will not remember you if you return to the website after 7 days.

By default, Google Analytics uses a cookie with an expiry date of 2 years to remember users (technically, the browsers). …

Chris Vu

How did my life bring me to this point being a technical consultant in digital analytics and optimization, I have no idea…

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store