: Google Analytics not same with my database records I got a website which will track all the post's visitor view and store each of them in a table with IP address, referrer website and user
I got a website which will track all the post's visitor view and store each of them in a table with IP address, referrer website and user agent. But I found that in one day I got 100+ rows (pageviews) in my database table, but Google Analytics showed that it has only around 40 pageviews that day.
Besides, when I found out my database got a new row and I went to see the Real-Time report in Google Analytics, it shows that my website got 0 visitors in the past 30 minutes.
I did tried accessed my website using my own phone and computer, both database and Google Analytics will record my view, anyone know why?
More posts by @Caterina187
1 Comments
Sorted by latest first Latest Oldest Best
There are a number of reasons why Google Analytics may not be showing the traffic your database shows...
Your Code Is Positioned Poorly
Your GA tracking code should be in the head section of the document, some webmasters put it in the bottom to improve load times however this can sometimes mean that the user has come to your site and then bounced right back out before GA has finished loading.
(https://support.google.com/analytics/answer/1008080)
User Has Javascript Disabled
GA depends on javascript to run. Some users have javascript switched off in their browsers for security reasons. Most web crawlers don't process javascript either and so a crawler won't show up in GA while your server logs and database log will show the traffic from the crawler.
User Has Opted Out of Analytics
Google provides a browser add-on to opt out of Google Analytics. When this add-on is detected GA will not log any details about the browser and as far as your GA report the user never connected.
(https://support.google.com/analytics/answer/181881?hl=en)
High Volume
In some instances where GA data is consistently off base with your own analytics it can indicate that Google has decided to start sampling your data instead of showing all of your data. This is generally due to a high amount of traffic but I have been unable to find any details on the Google support page (https://support.google.com/analytics/answer/2637192?hl=en) about what sort of traffic limits there are before sampling comes into place. The only way to avoid this is to use another analytics provider as it is forced into GA free to limit excessive loads on the GA network.
As you can see there are a number of reasons why Google Analytics will not show all the records your database or server analytics do and these aren't all the reasons, just the most common. You will probably find that the large discrepancy is to do with multiple issues some of which will be in this list. As a side note the only one of these issues that can be fixed is the code position, the other issues can't be fixed.
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.