The Ecommerce Expert

Successful Ecommerce Businesses Start Here

  • Home
  • Services
    • Ecommerce PPC Management
    • Conversion Rate Optimization
    • Ecommerce Consulting
    • Website Design / Redesign
  • Free Resources

Image Search Keyword Tracking With Google Analytics

By Eric Leuenberger 5 Comments

I recently had a question from a user of my Simple Google Analytics zen cart module about how to differentiate between searches and keywords that come from Google Image Search vs. those that come from other Google search channels. As of this writing, Google will automatically log referrers from its image search engine; however, it lumps all keywords into one lump source as ‘(not_set’).

To get a more detailed keyword breakdown you need to customize the code you use within your Google Analytics tracking script.

The method I will describe here works for anyone using Google Analytics on their site regardless of how it is implemented.

The first thing you have to do in order to get this to work is to be running either the ga.js or the Asychronous version of the tracking script.

Depending on which version of the tracking script you have chosen you’ll then need to customize it with one of the following snippets, adding it to what you already have. Be aware that the order and placement of this code within the original tracking script is very important.

If you are using the ga.js version of the tracking script you’ll need to add the following lines of code (highlighted in bold) to that.



If you are using the ga.js tracking script your additions would look like this:




Doing this should breakout the individual searches by keyword so you have a more complete picture of what is happening with regard to the traffic that comes from Google Image Search.

Google help also offers more information on customizing search engines and referral traffic with your analytics tracking script.

Have you tried this method or have another way of doing it? I’d love to hear it. Post a comment below to join the discussion.

Related posts:

  1. New Release: Yahoo Search Marketing Conversion Tracking for Zen Cart
  2. Google Analytics Demystified: Part 2 – Vanilla Google Analytics
  3. Tracking Google Product Search Traffic in Google Analytics
  4. Google Analytics Demystified: Part 3 – E-Commerce Tracking

Filed Under: Website Analytics Tagged With: google analytics image search, image search google, track image search keywords

Books by The Ecommerce Expert

Google Analytics Uncovered: How to Set Up and Maximize Ecommerce Data in Google Analytics
Available on Amazon Now!

About Eric Leuenberger

Ecommerce conversion marketing expert who has been helping store owners since 1995 increase sales and build more profitable, more sustainable ecommerce businesses.

Comments

  1. Big_Berny says

    April 25, 2011 at 6:37 am

    Thanks a lot for that script! Works great.

    But unfortunately there’s a “bug”: Some image searches won’t be tracked correctly and still show as referred by google.com/imgres. Thats because the domain isn’t always images.google.* . So a better way to detect image serches is looking for imgres or imglanding in the url. Like stated here: http://blog.semetrical.com/the-new-google-images-and-why-youre-probably-not-tracking-it-properly/

    Can your script be changed modified to work with the other detection?

    Reply
    • Eric Leuenberger says

      April 25, 2011 at 10:22 pm

      Thanks for the info there. Yes, my script can be changed to accomodate. No new programmimg required. It does this out of the box if you use the ‘custom’ code section in the admin.

      Just include the new tracking criteria as part of your custom code and save. Should work just fine.

      Reply
  2. Big_Berny says

    April 25, 2011 at 6:38 am

    And a last thing: Is it possible to tell Google Analytics what the filename of the selected image was? That would be great as we have slideshows with multiple similar images on our page.

    Reply
    • Eric Leuenberger says

      April 25, 2011 at 10:31 pm

      This I am not sure of. I would guess you might be able to accomplish it with some added triggers attached to each image (to indicate what the image is.)

      Reply
  3. Big_Berny says

    April 26, 2011 at 5:19 am

    Ok, I think I found a solution:
    var ref = document.referrer;
    if (ref.search(/(images|www).google.([^/]+)/(images|imghp|imgres|imglanding)/) != -1 && ref.search(/prev/) != -1) {
    var regex = new RegExp(“google.([^/]+)/.*&prev=([^&]+)&”),
    var match = regex.exec(ref);

    _gaq.push([‘_addOrganic’,’images.google.’+match[1]+,’q’,true]);
    _gaq.push([‘_setReferrerOverride’, ‘http://images.google.’+match[1]+unescape(match[2])]);
    }

    Now the only thing I’m still looking for is tracking of the image file name which has been clicked on. Any idea?

    Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Categories

  • Blogging
  • Conversion
  • Customer Retention
  • Design & Usability
  • E-Commerce Optimization
  • Email Marketing
  • Featured
  • Google Adwords
  • Increase sales
  • Marketing Strategies
  • Mobile Commerce
  • Search Engine Optimization
  • Search Marketing
  • Security
  • Shopping Cart Abandonment
  • Social Media
  • Website Analytics
  • Zen Cart
  • Zen Cart Contributions
  • Popular
  • Recent

About

The Ecommerce Expert offers products and services that help move ecommerce businesses toward growth and success. Our products and services help store owners maximize their ROI, decreasing expenses and increasing revenue. The net result is sustainable growth and stability with above average results.

Services

  • Conversion Rate Optimization
  • Search Engine Marketing (SEM)
  • Ecommerce PPC Management
  • Social Media Marketing
  • Ecommerce Consulting
  • Website Design / Redesign

Copyright © 2023 | Privacy Policy

We use cookies on our website to give you the most relevant experience by remembering your preferences and repeat visits. By clicking “Accept”, you consent to the use of ALL the cookies.
Do not sell my personal information.
Cookie SettingsAccept
Manage consent

Privacy Overview

This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience.
Necessary
Always Enabled
Necessary cookies are absolutely essential for the website to function properly. These cookies ensure basic functionalities and security features of the website, anonymously.
CookieDurationDescription
cookielawinfo-checkbox-analytics11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Analytics".
cookielawinfo-checkbox-functional11 monthsThe cookie is set by GDPR cookie consent to record the user consent for the cookies in the category "Functional".
cookielawinfo-checkbox-necessary11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookies is used to store the user consent for the cookies in the category "Necessary".
cookielawinfo-checkbox-others11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Other.
cookielawinfo-checkbox-performance11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Performance".
viewed_cookie_policy11 monthsThe cookie is set by the GDPR Cookie Consent plugin and is used to store whether or not user has consented to the use of cookies. It does not store any personal data.
Functional
Functional cookies help to perform certain functionalities like sharing the content of the website on social media platforms, collect feedbacks, and other third-party features.
Performance
Performance cookies are used to understand and analyze the key performance indexes of the website which helps in delivering a better user experience for the visitors.
Analytics
Analytical cookies are used to understand how visitors interact with the website. These cookies help provide information on metrics the number of visitors, bounce rate, traffic source, etc.
Advertisement
Advertisement cookies are used to provide visitors with relevant ads and marketing campaigns. These cookies track visitors across websites and collect information to provide customized ads.
Others
Other uncategorized cookies are those that are being analyzed and have not been classified into a category as yet.
SAVE & ACCEPT