Tracking the same event on both Client & Server

  • 5 August 2020
  • 1 reply

In my company we have been discussing our Mixpanel integration a lot lately. This is due to our newly launched application which relies on a different business model than before and therefor the tracking in Mixpanel has changed.

Some employees want to use Mixpanel for reporting purposes, mostly wanting exact numbers on stuff like transactions and number of sign ups. So my first thought were to place those events on the server which would make them as close to 100% reliable. My second thought was that funnels and insight might get unreliable now that the server events are sent 100% of the times and client events are sent 80% of the time (not exact number). Also we won’t get a lot of the client meta data.

Maybe I am overthinking this or maybe there is a better solution.

I would love to get some feedback on this.

1 reply


Hey Daniel,


There’s 2 different ways to think about this issue - where these events happen in the funnel, and why you’d be getting less data client-side and what that means for server-side tracking.


Where the events happen in the funnel:

Generally, when we talk about events that would be server-side, we’re talking about conversion events -- completing a purchase flow, completing a sign-up flow, etc. Because these events tend to happen last in the funnel, there actually won’t be any affect on your funnel reporting if you include the final step but don’t include the preceding steps for a single user. In other words, imagine a user needs to do A->B->C to complete a funnel and A and B are sent client-side and C is sent server-side. In the case that a user isn’t sending events A and B, then even if they do send event C, the funnel won’t change as the funnel requires the user to have done step A and B before we even consider the importance of C. The only impact here would be you would be closer to your true count of conversions/signups.


Discrepancies between client and server tracking:

In the case of client-side, a good portion of missing client-side data is due to users opting out of cookies under GDPR/CCPA regulations. In this case, it’s best practice to adhere to that opt-out in both client and server-side tracking. Essentially, if a client opts out of client-side tracking, it is best practice for you to also stop any events from your server sending events for that user to us. That being said, I am not a lawyer and there are cases where sending tracking is allowable when a client opts out if the data is sufficiently anonymized or meets other criteria. This is something that you should discuss with your legal team and get their guidance on what level of tracking they’re comfortable with.