13
8 Comments

⏱ Setting up our first attribution model in 1 min

At ScrapingBee we wanted to know what were the marketing channels that brought the most 💰.

GA makes it very easy to know where do your visitors/users come from.

But when it comes to customers, and their values, it is harder.

Here is our very simple attribution system that takes 1 minute ⏱ to integrate

First, store in a cookie UTM tags and referrer.

It's important to set up the domain of the cookie if you use a subdomain for your app. And it's also important to set the expiration date otherwise the cookie would disappear on each session.

Here is the snippet we added on every page of our marketing website.

https://gist.github.com/daolf/e66ec71c603cec4e502190788e75a2f6

Then, on your signup pages, add those 2 things:

hidden fields for the info you want

this snippet that will populate those fields with your cookie 👇

https://gist.github.com/daolf/a93371c414aadc0ce7f77b3098acfa31

Store those in your DB, subscription analytics and that's it!

It's not perfect, but it takes 5 minutes to implement and will help us a lot with understanding what marketing channels are worth focusing on 📈.

Curious to know how you do it.

  1. 2

    We do a similar thing and we also add those details to our #sales-trailling channel in Slack which is a feed of new user signups.

    The other thing you can do is use the attribution features of Google Analytics. Are you familiar with those? If not, here's a really good post by Devesh Khanal on how to measure for content marketing but totally applicable for other channels too.

    1. 1

      I used to use GA but I found it hard to set up the user -> customer thing and keeping all the UTM tags and all.

      Will take a look at the article.

      Thank you very much!

  2. 1

    Pierre, it's a nice workaround, but not sure what you're trying to "work around".

    1. Adblock has nothing to do with attribution and tracking. it blocks ads, but shouldn't block GA / http requests - and if adblock was actually blocking something, it would block tracking all together - the visit, goal, event and co...
    2. google has an attribution system that allows you to see first, last and other touch points leading to a conversion.
    3. Goals are indeed built for tracking these actions.
    4. Google Analytics lets you track unique users and their journey (see user explorer),
    5. Avoid using UTM tags for internal linking - Doing this reset your "campaign" sessions / last click attribution. Classic error on setting up internal links.
    6. In the audience section, you have access to cohort analysis and other rich data.

    In essence, when you "workaround" the GA attribution system by "hardcoding" some values, you cut off all possibilities to discover what are your true conversion lifters.
    For example, you run a campaign on FB, and retarget on Google Ads.
    the lead came from FB, but the final acquisition is on from Google Ads.
    Or, you bring leads from social media channels, but the actual "activation" comes from your email sequences.

    By forcing the UTM data, you discard "google ads conversion lifter", which might be 90% responsible for closing the "sale".

    Finally, there are more suitable solutions for user/mrr/churn analytics - i.e. mixpanel.

    Hope that helps.

    1. 1

      Hey there and thank you very much!

      You seem to know a lot more about tracking than I do so don't take what I'll take as a challenge, but rather as what I thought happened.

      1. If AdBlocks blocks GA, how does Google know that the same user did landing -> signup page. How can it be shown in GA? I checked and my AdBlock definitely blocks GA requests.

      2. I did not know about this view but I have trouble finding how to leverage it considering it's all anonymized data.

      3. I don't think this is what I do? I just store UTM tags in a cookie, I don't think I'm changing any internal links

      4. I need to learn to use this 😊

      Those tags and attribution are indeed sent to suitable solutions for us, i.e: MixPanel

      1. 1

        Hey there,
        Yeah, tracking is my tradecraft;)
        Correction regarding ad blockers: you are 100% right about ad blockers - many do block GA, which makes a few of my advice irrelevant.
        Yet, in order to get over the blockade, you need to detect and circumvent the adblockers using server side tracking. There are some interesting posts about it (check simoahava.com's blog).

        GA is not meant to be used for PII data. Therefore, no matter what you try to do, you should consider GA as an aggregated dataset, but use other tools like mixpanel & co to analyze specific users.
        GA has a special view for UserID- where you should send your internal userid and tie it to the GA Client ID, so you can "identify" your users. (The same userid you send to mixpanel).

        UTM's - Again, since GA has its own data processing / attribution, if you override it with your own, you actually "pollute" (excuse the term), the GA dataset and lose the GA powerful attribution capabilities.

        RE Mixpanel, why don't you let mixpanel attribution system work on its own?

        last but not least - if your solution does the job and satisfies you, then perhaps you've got another startup idea at your fingertips;)

        Be well!

  3. 1

    don't you think that GA Goals are made to do just that ?

    Just set a goal url like a thank you page after user have signed up and you are done.

    In GA Dashboard you will be able to back track which channels converted more, etc.

    Or i am confused ?

    1. 1

      This is not as simple.

      Your solution would not work for users with AdBlock.

      And because GA does not allow to uniquely track and identify user it would not allow us to track TLV / Churn rate / MRR per channel.

Trending on Indie Hackers
I make $100K+ ARR from my micro startups. AMA. 76 comments Looking for a super basic analytics app 22 comments How BaseTemplates grew from $500/MRR to $10k/MRR 13 comments Just Launched - TestLocal ly 2 comments Roast my campaign - a free 1:1 with a startup advisor 1 comment Best way to utilise amazing customer testimonials 1 comment