---
title: "Data & Insights: how to add the tag"
description: "Data & Insights help you figure out the intent your end users have on the website. Combine this data with other data sources in Contentstack Data & Insights and you get a powerful engine to create the content your users want. This video explains three ways to add the tag to your website."
date: "2025-06-16T09:43:57.000Z"
url: "https://timbenniks.dev/videos/contentstack/015-vfmm-bj_juk"
youtube_url: "https://www.youtube.com/watch?v=VfMM-BJ_juk"
playlist: "contentstack"
duration: "5:59"
image: "https://img.youtube.com/vi/VfMM-BJ_juk/maxresdefault.jpg"
tags: ["composable-architecture", "cms", "api-design", "content-ops", "cloud-infra"]
---

# Data & Insights: how to add the tag

Data & Insights help you figure out the intent your end users have on the website. Combine this data with other data sources in Contentstack Data & Insights and you get a powerful engine to create the content your users want. This video explains three ways to add the tag to your website.

Watch on YouTube: https://www.youtube.com/watch?v=VfMM-BJ_juk

## Transcript

Data and insights are now available to all current content stack customers. In your base package, you get the following things. The opportunity explorer, the content graph, the audience explorer, and the advanced audience builder. And in this video, I'll show you how to get started quickly. Let's set you up with a data activation layer project. To do that, you go here to your new app switcher, find administration, and now there's a new menu item in the settings here for data activation layer. So, I've already set one up. So, let's have a look at what that looks like. And let's scooch this over a bit so you can see better. So, I have a title for my project. Then, there's the base domain of the entity on the web that you are getting insights from and personalizing later. Then, there's a few things we can connect in this layer. So we can add your CMS stacks. It can be multiple. We can have launch projects if you use launch. And if you have personalization projects in content sec personalize, you can connect them as well. If you don't have one of these, that's totally fine. It still works. And then last but not least, we need a data and insights account connected as well. If you don't have one yet and you hit save, it will take you through a few steps and sets it up for you. In my case, I've done that just now. And so when you have a look at this connection tester, you can see it's all there. Now, if you want to follow your user and gain insights when they browse, what you need is actually a little piece of JavaScript that you can inject in your website. And so there are three ways you can set this up. So let's go over those. The easiest way if if you are um hosting on content stack launch is to go to your project in launch go to your settings and in environment you can see there's this event tracking tab. So let's give a bit more space here. So when you turn this on what launch will do is on the CDN edge it will inject this JavaScript for you and because you have this data activation layer just set up it knows about all your stuff. So it just injects something that just works. So there are other ways. So if you don't host on launch or you want to do it in a different way, we can also just go to our data and insights account and grab that little piece of JavaScript. So let's do that now. So let's go to our system. So you select the the data analytics account that you just created in the project. And so this will now connect me through oath to our LTI account. So it's all connected and safe. And here in our dashboard when we scroll down you'll see install litics. And so I'll make that slightly smaller so you can see again there's actually this install button here. And what this gives you is actually this JavaScript tag. And so this tag can be added in well a multitude of ways but the simplest one is actually grab this and put this in your tag manager. A lot of um our customers and bigger websites actually have a Google tag manager or equivalent where you can just paste this piece of code and it all works. And because this account was set up through our data activation layer, this ID is personalized to you. So you can just copy paste and it just works. However, if you don't have that option or you don't want to, you can also grab this code and actually put it in your codebase. You can just go to your front end code and tell your developers, can you please put this in? There's one note here that if you have something like a single page app where maybe the pages show up but your browser doesn't always refresh. This is like there's many ways to do this but a lot of our meta frameworks now do this. Make sure that on every page change so when the routing changes listen to that and fire this page view function so that makes sure that every time a user sees a new piece of content this page view is sent. All right. So before I show you how this all looks and what the JavaScript tag actually extracts from the user, it's important to notice that you have to take into account the GDPR and privacy policies of your company. Out of the box, this will never actually find any information that's super personal from the user unless you give it to the system. So make sure to follow your GDPR and privacy rules to send information here and you're all good. So to see what this JavaScript tag is actually doing is right now I have implemented a little bit of code that of course you won't do in production because this shows you the insights that you have on your user right it can see there's a bunch of little interests here and stuff and so when I actually go to another page let's say I go to this page and then maybe we go to another one this starts to actually fill up with a bunch of more information that the JavaScript tag that's running on this website is finding about the user Right? We can see the frequency, we see momentum, we see all these different interest. And so the more you browse around, you can start informing information about this user. And in this case, and that's I'll show you how that works in a different video. When we actually browse more earring related content, for example, these earrings, we go to those earrings. Maybe one more. Is there something else? Yeah, these ones, the more classical ones. When I open this up now, it actually says, "Hey, this person is interested in earrings and I've now been put into the audience for earrings and also I like gold apparently." Well, when I now go back to the homepage, I now have a new homepage specifically about earrings. And so, this is what you can do when you have audience insights. You can then talk to your CMS and the contact personalized product to actually personalize your page. What you should know though is that the personalized product is not out of the box for free included in this new release. This is all for now. If there are any questions, we are around. We have built this thing. We have just released it. We're ready to help you get on board. Um, happy coding. Cheers.
