Why is Google Analytics appearing in the source code of my free wordpress.com page?

  • Unknown's avatar

    Hello,

    Since 2012 I am running a free wordpress.com site (monikereggplant.wordpress.com) and am currently in the process of updating my privacy policy in order to make it GDPR compliant.

    While skimming through the source code of my site in different web browsers, I realized that even though I didn’t activate Google Analytics support (in fact, since I am running with the free wordpress.com plan, I cannot activate Google Analytics, since this would need an upgrade to a paid plan), sometimes (not always, strange enough) the following javascript is inserted just before the closing “ tag:

    “`
    window.google_analytics_uacct = ‘UA-52447-2’;

    var _gaq = _gaq || [];
    _gaq.push([‘_setAccount’, ‘UA-52447-2’]);
    _gaq.push([‘_setDomainName’, ‘wordpress.com’]);
    _gaq.push([‘_initData’]);
    _gaq.push([‘_trackPageview’]);

    (function() {
    var ga = document.createElement(‘script’); ga.type = ‘text/javascript’; ga.async = true;
    ga.src = (‘https:’ == document.location.protocol ? ‘https://ssl’ : ‘http://www’) + ‘.google-analytics.com/ga.js’;
    (document.getElementsByTagName(‘head’)[0] || document.getElementsByTagName(‘body’)[0]).appendChild(ga);
    })();

    “`

    Any idea how I can get rid of Google Analytics entirely? Since I have never, and – due to my free plan – cannot even explicitly enable Google Analytics on my site, let alone access the data that is collected, I am confused why it is appearing at all?

    I already tried many different things, like trying from differnet browsers, clearing my cache and starting with a fresh browser profile. The above code seemed to be gone several times when trying this, but in my tests it has always reappeared sooner or later.

    Since I have never seen this code appear on a test blog witht the same theme that I have created with a test account on wordpress.com to cross-check, I suspect that there still has to do something with the configuration on monikereggplant.wordpress.com, but I have no idea where this might come from. This is why I wanted to ask for help here.

    All support articles on wordpress.com regarding site stats all just state that there is the basic WordPress Stats (powered by Jetpack, as far as I understand) always enabled. But for Google Analytics to be enabled along (or on top of) Jetpack (which is not my intention, again: I want to get rid of Google Analytics), I would have to sign up for a paid plan.

    Perhaps you know what’s going on here and can help?

    The blog I need help with is: (visible only to logged in users)

  • Unknown's avatar

    @monikereggplant

    Thanks for your report. It would be interesting to have an explanation about it concerning Google Analytics. I am like you : I am running a free WordPress.com site for my blog. So I can’t activate Google Analytics without an upgrade to a paid plan.

    In your site, do you ask for email in comments or contacts you receive ?

    For me the answer is no, and I would like to have the choice to not receive IP address in my dashboard. I ask the question about that this morning, but my thread has been closed.

    I think that if you don’t ask for name, email and not receive IP addresses, you don’t process in this case personal data, and so you don’t have to ask you about GDPR. What do you think about that ?

    Is it possible to share your privacy policy in order to make your free WordPress.com site GDPR compliant ? And how you technically implement it.

    I unpublished for the moment the articles and comments in my blog, with a message in the home page indicating that I have to verify if my blog is GDPR compliant.

    Thanks in advance for your reply.

  • Unknown's avatar

    Hi @cesa2018,

    do you also see the Google Analytics code on your wordpress.com blog or not?

    I am specifically interested in removing the Google Analytics code that is appearing in the source code of my wordpress.com blog even though it should not be there, because I cannot even enable it. If you have any information regarding this, I’m eager to hear it!

    As far as I understand from the Stats’ help page (https://en.support.wordpress.com/stats/), WordPress’s Stats is a service completely separated from Google Analytics (and therefore my question why Google Analytics code is appearing at all in my blog’s source code). On the help page you can also read that “WordPress.com stats do not track IP addresses or other details not described in this document.” Therefore I think you don’t need to be concerned about collecting IP addresses from your visitors. WordPress Stats doesn’t do this.

    Our privacy policy is available online. But please understand that I don’t want this thread turning into a general GDPR help discussion about my or your or anyone else’s privacy policy.

    I’m merely interested in why Google Analytics javascript code is appearing on my site every other visit?

  • Unknown's avatar

    Hi monikereggplant,

    Thanks for your reply and the precision about your privacy policy.

    I am sorry but I don’t know how to see if the Google Analytics code is appearing in the source code of my wordpress.com blog. But you can tell me how I can examine it, and I could answer you.

    About IP address, I would like to have an option to prohibit this information received with comments and which display on my dashboard. I hope it would be the case with future GDPR tools from WordPress.com .

  • Unknown's avatar

    In my source code I see the quoted javascript code just before the closing head tag. To check your own source code, you can search for “UA-” in it. This is the two letter code that every google analytics ID begins with. If you do not find anything similar to the code quoted above, you should be safe.

    I’d still love to hear from someone at wordpress.com/Atomattic about why this code is appearing in my blog’s source code at all, given that I have a free account and no possibility (and no desire) to activate Google Analytics. I simply want to get rid of it.

  • The topic ‘Why is Google Analytics appearing in the source code of my free wordpress.com page?’ is closed to new replies.