How Google Analytics Actually Tracks Engagement

When Google Analytics is deployed to record the amount of traffic one's website is receiving, one of the more important data points reported to the owner is the length of time a given user is recorded staying on the site. This stretch of time is commonly referred to as a web session, and it presumably represents a period throughout which the user actively engages with the website's content.

Google Analytics technically works by first loading itself for a given viewer who loads any page within the domain for the first time. This initial interaction is registered as the "starting hit," and each clicked link that brings the viewer to either another page or an external website is registered as a "subsequent hit." The time that elapses between the starting hit and the most recent hit is recorded as the session duration, and it is updated whenever a subsequent hit overtakes the previous one.

Because session durations are rather strictly dependent on there being at least one "ending hit" to correspond with a starting hit, Google Analytics can sometimes report seemingly anomalous data points. The data can appear as though a fraction of the website's traffic for the day only stayed on the site for a single second each, for example. This is caused by Analytics recording the duration of the session as "zero seconds" whenever a newly arrived viewer leaves the site by closing the page they had just opened; how long the viewer stayed on the same page beforehand does not make a difference.

Evidently, a person who is not making any additional page impressions can still be seen as actively "engaging" with a site's content if their needs are being served by spending a lot of time reading the same page. Since Google Analytics does not efficiently tally time for sessions that lack concluding hits, many websites implement additional syntax in their pages that recognize instances of viewers scrolling beyond particular thresholds at designated points on a given page to be "events" in their own right. Google Analytics can be made to interpret these events as hits. For more information click here https://www.reddit.com/r/SEO/comments/jjg65f/91organicuserscametomysiteyesterdayonly_2/.