New visitors Mixpanel vs Google Analytics - google-analytics

I can't figure out why there's a quite significant (~30%) difference between new visits figure I get from Mixpanel and GA. Here's how I implemented this metrics with Mixpanel:
if(!mixpanel.get_property("First visit")) {
mixpanel.register_once({ "First visit": $.now() });
mixpanel.track("Visit");
}
Is there anything wrong with this code? Is there any better way to do it? I want to implement a signup funnel with mixpanel (first visit -> sign up form -> sign up), but can't afford tracking every single visit, so I track just the first one. Though daily "Visit" events differ by 30% from New Visitors from Analytics and spoils the funnel.

Your code functioning correctly(i've checked)
Well the difference is due the way both services track users
Google Analytics relies exclusively on keeping track of users via a cookie (the average time of a cookie expires in 30 days).
With Mixpanel, you can utilize a user_id or any other id that makes sense for your business which will always last longer than a cookie.
Here are the differences in mixpanel and google analytics
https://mixpanel.com/help/questions/articles/how-is-mixpanel-different-than-google-analytics
How to improve your first user setup in mixpanel;
https://blog.mixpanel.com/2015/01/06/community-tip-tracking-first-time-users/
Hope this will help you

Related

GA: How much time have my 100 most "obsessed" users spent on my site

Does Google Analytics have enough information to answer the question of how much time have my top 100 users spent on my site? I don't need their user information, I don't care about ID or name which I know it doesn't even have. Just the identification of individual users by the cookie GA uses, and a report of how much time the top 100 loyal users spent on my site.
is such a thing possible at all with GA?
From your comment on Colwin's answer:
I don't need google if I have to track this for GA, I just hoped it already has this information such as "page visit duration" on a per-user, ongoing basis. If I had to feed Google that information myself, I can feed my own database and run analytics on it. Thanks anyway.
The Google analytics sessions is
a group of user interactions with your website that take place within a given time frame. For example a single session can contain multiple page views, events, social interactions, and ecommerce transactions.
Average session duration will be calculated as
total duration of all sessions / number of sessions
I don't think this is available from GA out of the box. But you can build something like this with Custom Dimensions available within GA
This will let you setup and send custom metrics dimensions for users that you can then create reports for.
Google Analytics doesn’t allow you to out in PII but random visitor id's should be fine. You can then compare against your own database outside of GA if needed too.
This will allow tracking the same visitor even without them being logged in to your site.
Sending the custom dimensions could possibly look like this.
ga('send', 'pageview', {
'dimension5': '1234567890'
});
You get 20 free custom dimension slots with GA and 200 with GA 360 -> More info here
I think this article has what you are looking for
https://webanalyticsguy.com/2018/01/18/google-analytics-capture-client-id-reporting-purposes/
It shows how to capture the client id which is a decent way to track a specific user. And goes further to explain how to associate that with a metric, in this case the author uses PageView.
You could change this to Average Session Duration or another metric that gives you a sense of time spent.
I guess that you are looking for something like this:
http://www.analytics-ninja.com/blog/2015/02/real-time-page-google-analytics.html
You can get the counts of the users on your site. You can get the seconds they spent on your website page.
I guess this answer will be helpful too: https://qr.ae/TWpkI0

Google AdWords Conversions not matching database entries

I've just set up a tool on a client site that users can use to request a quote from our client. To do this the user lands on a form page, fills in their details, submits and then lands on a thank-you page. Pretty basic.
I set this process up as a goal in Google Analytics, using the destination type goal: "begins with /thank-you" and shared that goal as a conversion in Google AdWords.
I decided to run a few Google AdWords ads to promote the tool. I also wanted to double-check the conversion data that AdWords gives you so I set the destination URL in Adwords to www.example.com/form-page?adsrc=adwords1 (2, 3, 4 etc. for each ad) and I configured the DB so that there was a column that tracked which URL the user was on when filling in the form (this would be the column I counted to get the number of conversions that came from AdWords so I could compare)
Further to this, I made sure that the initial URL parameters that the user landed on were stored in the session so that if the user browsed to other pages and came back to fill in the form later, it would still attribute the conversion to AdWords.
I tested this thoroughly on a staging and production environment and everything was working correctly.
I ran the campaign for a week and when I checked, the conversion results in the Data Base vs the ones coming from AdWords are wildly different. The DB tells me I've had 5 conversions while AdWords gives me 21.
Is there anything in the way Google uses its gclid that may be causing this issue? Or is there a problem with the way I've set up the measurement structure?
This can be caused by few things, but I think this is the GA/AdWords issue, more than your DB/session set-up.
Gclid shouldn't influence your goal, since it is used only for AdWords/Analytics interactions, Goals should not be affected in your set-up.
https://support.google.com/analytics/answer/2938246?hl=en
Probable cause: If your goal set-up only contains "begins with /thank-you", isn't it possible, that you are counting all the sessions which reach thanks-you page? Not just AdWords?
Solution: if you need to count conversions in AdWords (for performance improvements), use AdWords conversion code at the same page, this counts only those users, who clicks an ad and reach your thank-you page in x (default 30) days. Be sure to count only unique conversions (users by cookie).
Differences between GA/AdWords conversion count:
https://support.google.com/analytics/answer/2679221?hl=en
Google attributes conversions to the last marketing channel, where direct visits do not count as a marketing channel (if you look at their attribution flow visualization you see that the penultimate step is to check for existing campaign information for the user). So GA might overcount Adwords visits (or other campaigns) and conversely shows fewer conversions for direct visits.
On contrast your database probably records the last traffic channel without an elaborate attribution model, so it will show less campaign traffic.
Also IIRC the adwords interface records the conversion for the time of the ad click, not the actual goal conversion, so the timeframes for the conversions differ.

Google Analytics - Visit duration 0 sec

I am using Google Web Analytics Online Tool to monitor visits on my site.
What bugs me is that often I see that records contain the folloowing entries:
Page Visits: 1.00
Average Visit Duration: 00:00:00
Bounce Rate: 100%
What does that mean?
If the visitor comes to my site it should stay at least couple of seconds until he leaves?
Could that mean that something is wrong with accessing my site (I had similar problems before, but I am convinced I fixed them since I am not getting any errors when I try to access my site from different computers.)
When a visitor comes to your page google analytics sets a cookie where a timestamp is stored. When the user visits a second page in your site Google compares the stored timestamp to the actual time and calculates visits duration from the difference between the two. If all your visitors have bounced there is no second data point to compare the stored value to and google is unable to compute a duration.
A common workaround is to set a javascript timeout and trigger an event after ten seconds or so (with the "interaction" flag in the event set to true, see Google Analytics event tracking docs for details). The assumption is that somebody who looks for more than ten seconds at you page is not actually a bounce (I think that since "bounce rate" has so hugely negative connotations people try to avoid high bounce rates even at the price of introducing bad data; you should realize that "bounce rate" simply means that there are not enough data points to say anything meaningful about those particular visitors).
Personally I do not like that approach because it means to redefine inaction of a visitor as action. A better idea (IMO) is to implement a meaningful interaction point - like a "read more" link that loads content via ajax or something like it - and track that via event tracking or virtual page view.
Event tracking guide:
https://developers.google.com/analytics/devguides/collection/gajs/eventTrackerGuide
Short Update: With Universal Analytics the technical details have changed (i.e. there are no longer cookies with timestamps, all information is processed on the GA servers). So the first paragraph is no longer up to date, however the rest of the answer is still valid.
I'm having a similar issue, i monitor those placements and recently found out the traffic is hardly getting to my site, recent experiment showed that those are placements triggered via clicks from GDN, but people have not even reached my page, were blocked by pop-up blocker or other similar software

How do I calculate conversion rate using Google Analytics?

I have created a goal in Google Analytics that is met when the user completes the sign up process. The page that they end up at is
http://my_url.com/?just_signed_up=true
In order to calculate my conversation rate, I need to do this calculation:
goal (sign ups) / new visitors
I know that in order to use new visitor numbers, I can either set up a profile with a new visitor filter or just apply a new user advanced segment on my normal profile.
My problem is that the Google Analytics tracking code is on every page in my site, including my landing page. The sign up process goes like this:
Landing page -> Sign up form -> http://my_url.com/?just_signed_up=true
When the user ends up at the URL above, am I correct in thinking that Google Analytics will no longer consider them a new user, as they would have the cookie from when they landed on the landing page at the start of the sign up process? If so, then there will never be a new visitor that meets the goal. How would I calculate my conversion rate in this scenario?
A returning visitor is someone who starts an additional Google Analytics session while using your site. To start a new session they need to close their browser or stop using the site for a period of at least 30 minutes. Browsing around your site clicking links isn't considered stating a new session. This means that, in most cases, signups from new users will be from people (or at least browsers with a set of cookies) who have not visited your site before.

Inundated with marketing tracking pixels (Campaigns with multiple vendors)!

We have some third parties that are sending us traffic and have asked us to put a tracking pixel on the confirmation page so they can track through the sales.
We are currently using Google analytics for our own usage.
Google will remember the original referral through cookies. This may be a good or bad thing. If someone purchases through company B's link but they had originally found our site through company A - then company A still gets the 'referal'. That doesn't seem fair, but it seems to be the way google analytics works:
For example, if this is the user's
first visit to your site, the tracking
code will add the campaign tracking
information to the cookie. If the user
previously found and visited your
site, the tracking code increments the
session counter in the cookie.
Regardless of how many sessions or how
much time has passed, Google Analytics
"remembers" the original referral.
This gives Analytics true
multi-session tracking capability.
Currently we only have one tracking pixel on our 'receipt page' from a company that we're not even doing business with. Having a second company ask me for us to add one makes me thing 'wait a minute - we're going to suddenly be inundated with these things!'. Plus it means someone can look at the source and see all the people we do business with.
This isn't Oprah - you cant ALL have tracking pixels. Right ?
How should we manage sales from multiple traffic sources in the most honest way for both sides - especially if they already have a system set up that they insist on using?
Here's how I solved the problem at our company: we gave our partners a URL that has a parameter in the query string. This parameter triggers a cookie. On the "goal"/confirmation page (where the tracking pixel is usually inserted), we insert some logic to see if the cookie value is correlated with a one of our recognized partners (chained if-else or switch statement). If a match is found, then the tracking pixel is displayed.
Even though you asked this question a while ago, I hope that this still helps you or someone else with the same problem!

Resources