WordPress Expert Special Offer: Free WordPress Installation, Free WordPress Development Consultation, Budget cut-off for your WordPress customization

Get your own domain name for $10 only! Get the cheapest web hosting for $6 a year, Free WordPress Installation, Free WordPress Development Consultation, Budget cut-off for your WordPress customization, and much more. Get free web hosting to test your website first. Just contact us and we will never charge any cost, and the best part is you can also get free WordPress installation and ready to used for your website. Start today! Get this special offer Now! Don’t waste your time, it’s only until end of this year!

Asynchronous Google Analytics for WordPress

Posted by on November 10th, 2010 in Pluginswith 26 Comment(s). Tagged with: , , , , , .

Download Asynchronous Google Analytics for WordPress Plugin Please ask your questions and make your remarks in the WordPress support forums, I'll answer them there! Want to support me? Donate a small amount through PayPal!

Version 3 Released: Asynchronous Google Analytics for WordPress Multisite Support

After few nights in front of my lovely laptop and spent a little time being coding, finally version 3 released. This is the major step of my Asynchronous Google Analytics for WordPress plugin going into WordPress Multisite environment. Since along time ago i’ve been challenged about how to manage and deal with the Asynchronous Google Analytics tracking code with an easy way, even for non-programming skill at all.

Truly, I found there are still a major problems for non-programming users about how to manage, tracking, and or setup Google Analytics tracking code in WordPress multisite. Especially when the wordpress multisite environment have been setup using sub-domains and the web administrator want to tracking all the sites among their multisite network as easy as setup each site separately. Not only that, sometimes we just want to use 1 Google Analytics Account ID for all sites instead of using separate Google Analytics profile for each sites/sub-domains. Then we can have all Google Analytics tracking results for all our sites/sub-domain in just 1 Google Analytics profile. Does it more efecient?

When wordpress multisite activated in your website, it’s not an easy way to accommodate the functions to adapt and able to track all your site into one Google Analytics Account ID. This is because you must adjust the Asynchronous Google Analytics codes so Google Analytics can track your website and all sites among your wordpress multisite network properly (especially when multisite environment activated using sub-domains instead of sub-directory as i explained above).

Asynchronous Google Analytics tracking for domains and sub-domains required an advanced knowledge about how to setup Google Analytics code and their configuration. But with Asynchronous Google Analytics for WordPress Multisite plugin, it’s becoming easy, fast and even doesn’t need any knowledge about inside Asynchronous Google Analytics code itself. Just a few clicks in your wordpress dashboard, you will be able tracking your website as well as your sub-domains / sites in your wordpress multisite network.

Story Behind The Plugin Development

Google has announced new Google Analytics Asynchronous Tracking Code since december 1st, 2009. The new Google Analytics Asynchronous Tracking Code snippet was an alternative way to track our websites! It provides the following benefits:

  • Faster tracking code load times for our web pages due to improved browser execution
  • Enhanced data collection & accuracy
  • Elimination of tracking errors from dependencies when the JavaScript hasn’t fully loaded

In the beginning, i’ve been used Google Analytics for WordPress plugin to build the Asynchronous version. It’s not as easy as I can imagine. The plugin still need much adjustment in the coding, especially the javascript code itself that bring another methods instead of the traditional one. Google bring new tracking method in asynchronous Google Analytics. Especially in their javascript loading and how to deal with the Asynchronous Google Analytics code. But this is gain more benefits, not only for Google itself, but also for all websites owner / blogger that using their service to tracking the websites. Faster website loading is one of the other benefit that we can get when we implement the asynchronous google analytics tracking method in our website.

After a few modifications with the plugin, javascript optimization and read the guides of new Google Analytics Asynchronous Tracking Code, finally the Asynchronous Google Analytics for WordPress plugin released. It has been few months ago since first released and already thousand downloaded and used by wordpress websites and blogger all around the world until now. You can download the Asynchronous Google Analytics for WordPress plugin from the wordpress.org plugins repository directly.

Basically, the plugins still came with the original features of Google Analytics for WordPress plugin, except that the plugin using asynchronous tracking code off course. This plugin also automatically tracks and segments all outbound links from within posts, comment author links, links within comments, blogroll links and downloads, allows you to track AdSense clicks, add extra search engines, track image search queries and it will even work together with Urchin, custom filter tracking for specific posts, pages, categories, tags, even can filtering by logged in user ID, user role, as well as filter tracking for specific visitor IP that can be useful to exclude your own networks for being calculated in Google Analytics tracking.

In the options panel for the plugin, you can determine the prefixes to use for the different kinds of outbound links and downloads it tracks. The best part is, you still have the freedom to choose how the tracking method would be: Using new asynchronous tracking or still want to keep tracking with the traditional method instead. While the default is the plugin using new asynchronous tracking method when it’s first installed.

How to Find My Google Analytics Tracking ID (UA)?

  1. Login to your Google Analytics at https://www.google.com/analytics/
  2. After Login, Go to Google Analytics home by clicking the Google logo in the left top corner of the page
  3. See the example picture below to found which one is your Tracking ID

Google Analytics Account ID

More Google Analytics Resources

Feedback & Donations?

Your feedback and/or donations are hugely appreciated.

Need Custom Plugins or WordPress CMS?

Contact us to set up a free wordpress development consultation. We creates highly-customized blogs and blog-powered websites, taking advantage of the robust WordPress platform and fully optimizing it. We regularly recommend this amazing software and now the majority of our clients happily use WordPress. Learn more about us and the best services we can give.

Bambang Sugiarto

More then 9 years, I have developed a wide range of websites including sites for startup companies, small, medium, and large businesses, and also government institutions. My core competency lies in complete end to end management of a new website, web design, software & web development project using wide range of technology, including and not limited to Delphi, JavaScript, ASP, MySQL, Ajax, XML, X-Cart, osCommerce, Joomla, WordPress, and many more.

Add Comment

Discussion 26 Comments

  1. Bambang,

    Part of the setup of the plugin promises to track visits per category and tags. How do I see those statistics in GA? What do I need to setup?

    Chad

  2. Mars says:

    Please add detection on is_multsite() routine in order to prevent failed on activation.
    function_exists(‘is_multisite’) && is_multisite()

    Thanks, Mars

    • Hi Mars, Thanks for your feedback. You are right, i forgot to add function
      checking ‘is_multisite’. It’s not available in WP prior version 3 right? :)
      Ok, already updated the plugin to version 3.0.5 and should be fixed now.
      Will be available for download at WP plugin repository in a few minutes…
      Thanks!

  3. Christian Brix says:

    Hi!
    Thanks for this great plugin which makes it really easy to integrate GA in the best way!

    I have one problem using it:
    Not mather what I do, this option will not change:
    “Where should the tracking script be placed?:”
    Asynconous GA should really be placed in the header by default, but the plugin keeps reverting back to in the footer ..

    • Hi Christian, Please upgrade the plugin with current latest version (version
      2.0.3). It’s a little bug from the previous version and should already fixed
      in current latest version. Thank you and let me know if you need any help
      with the plugin.

      • Christian Brix says:

        Hi Banbang,
        Thanks for replying.
        I have upgraded but I actually get the same in the newest version.. Strange if it should be fixed already..

        • Hi Christian,

          Did you use any wordpress cache plugin? such as W3 Total Cache or WPSuper
          Cache? If yes, then try to clear / purge the cache first. It’s probably
          because the Cache plugin still have caching your website (website from the
          previous installed AGA plugin still caching). And make sure you didn’t
          checklist the “credit link” option in my plugin setting. If above steps
          didn’t help too, you may download and extract the plugin from
          http://www.minilibra.com/aga.zip and replace all my plugins files in your
          wordpress plugin path with this extracted files (default AGA plugin path is
          wp-content/plugins/async-google-analytics/). That’s it … And let me know
          if you need more help..

          • David Grossman says:

            Using version 3.0.6 of plugin, I’m also unable to change tracking script from footer to header. Do you know if this is still a bug? Thanks.

            Using I have one problem using it:
            Not mather what I do, this option will not change:
            “Where should the tracking script be placed?:”
            Asynconous GA should really be placed in the header by default, but the plugin keeps reverting back to in the footer ..

          • Hi David,

            This isn’t bug. With async method, the code automatically use the standard
            google analytics code snippet that isn’t fully placed on the top (head)
            section or bottom (foot) only. But, instead use split codes. Please read the
            google analytics documentation at
            http://code.google.com/apis/analytics/docs/tracking/asyncUsageGuide.html#Spl
            itSnippet (this is that i implement in my plugins). Thanks.

  4. Ovidiu says:

    I’d like to know how or where I can view details about the downloads tracking and the outgoing links tracking. I mean I have set up those settings within your plugin but where do I find the stats in GA? Or do I have to set up anything else in GA to see it?

    • The tracking results appear in your Google Analytic account. Login to http://www.google.com/analytics and from the Overview page, select the account that has the tracking result you’re looking for. Google Analytics.
      generally updates your reports every 24 hours. This means that it could take 24 hours for data to appear in your account after you have first installed the tracking code in your website/blog.

  5. Arthur says:

    hi
    thx for this plugin
    i just noticed tht it makes my page invalid in the w3c validator. had to chang “&” for “&” in the generated code to make it ok…

  6. Kathleen says:

    Same question as Nasir, where do we find the tracking results of this plugin? I have located and inserted my Tracking ID number..

    • The tracking results was appear in your Google Analytic account. Login to
      http://www.google.com/analytics and from the Overview page, select the
      account that has the tracking result you’re looking for. Google Analytics
      generally updates your reports every 24 hours. This means that it could take
      24 hours for data to appear in your account after you have first installed
      the tracking code in your website/blog.

  7. S Hamdani says:

    Salam,

    Maaf sebelumnya, saya baru nyoba bikin blog dan kesulitan mencari Account ID untuk aktivasi plugin.
    bisa minta petunjuk?
    saya sudah coba aktivasi plugin “Google analitic for WordPress” tapi sama-sama gagal.

    terima kasih sebelumnya.
    sukses selalu

    S Hamdani

    • Tidak perlu minta maaf :) Saya senang sekali jika bisa sharing dengan siapapun :) Jawabannya sudah ada di halaman atas ( How to Find My Google Analytics Tracking ID (UA)? ).. semoga bisa membantu. Salam tuk semua blogger Indonesia :)

    Nasir says:

    I just installed the plugin, how and where do I see the tracking ?

  8. Robin says:

    Hi, Great work with the updated code.

    Could you confirm if it will work across domains ie with a main website and separately hosted WP blog using a single UA reference?

    http://www.mysite.com blog.mywebsite.com
    UA 111111 UA 111111

    The main scenario where this is relevant is to capture initial referrer data to the blog but where a conversion event takes place on the main website

    Many thanks

    Robin

    • Hi Robin, thanks for asking.

      1. The plugin can be used for tracking across a domain and its sub-domains. As example, if you want to track www .mysite .com and blog .mysite .com, then you just need to set the “Domain Tracking” field with value “.mysite.com” (without double quotation mark, and prefix with/without dot follow with domain name. If not prefixed with dot, it will be added automatically when the javascript code generated by the plugin).
      2. In the mean time, the implementation code of tracking across multiple domains and sub-domains as you mentioned not available yet, and will be added in the next release (1.0.2).

      Thanks for your confirm, your feedback will be added into the plugin features request list. Please check back soon to get it’s status in the next plugin release.

  9. Please ask your questions, feedback, features request, and make your remarks here or in the WordPress support forums, I’ll answer and updated in the next released.We do our best to keep up! Thanks.

Add a comment