How Web Tracking Works (Part 1)

Chris Vu
Sparkline
Published in
3 min readNov 19, 2020

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

Information including:

1. HTML & CSS

This is the main webpage content plus the instructions for the browsers to structure and format it properly so that it can be read by human.

Destination: Human eyes.

2. Structured Data

This is the supporting information that describes or supplements the main content, formatted to be readable by machines.

Destination: Machines.

Structure data comes in many predefined formats, including:

  • HTML metadata: Page title, page description, regional and language settings, etc. Used by browsers to format the page and also by search engines to index and rank the page.
  • Open Graph: Similar to HTML metadata, it provides richer info about the page such as a title image when sharing it on social media.
  • Schema.org: A widely-adopted format to describe the page content such as the product price, discount, and user ratings.
  • etc.

Structure data can also be (more) format-agnostic. The most commonly used being the Data Layer.

When we’re working on web tracking, we’re basically specifying the supporting information that we need for the web page, and instructing the web developers to push the information in a structured Data Layer.

Let’s debunk some misconceptions about structured data in general.

Will extracting the supporting information increase the web server load?

For the most part, the information has already been extracted by the web server to be displayed on the page. For examples: the user’s name, the product name and price.

We just need the information to be formatted in a structured Data Layer so that it can be read easily by scripts. So the slight increase in web server load is insignificant.

Will the data layer increase the webpage size and load time?

All the supporting information put together is probably smaller than a single typical image on the web page. So the slight increase in webpage size is insignificant.

Is it safe to output the data layer onto the webpage?

Just like when you login to a website and you see “Hello <your name>” greeting on the page, know that only your browser can access this information. It is not exposed to other users on the internet. So this is totally secure.

In the next article we will explain what the Data Layer is.

Sparkline aims to provide data accuracy, comprehension and consolidation, and most importantly, tangible insights for businesses. Get in touch if you’d like to learn more.

--

--

Chris Vu
Sparkline

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