Measuring Internal Site Search with Google Analytics

Do you have a ‘search’ box on your website? If so, it’s collecting some amazing analytics data. The search terms that visitors use to search your site litereally ‘tells’ you what they’re looking for. Are you ‘listening? If you’re using Google Analytics you can ‘listen’ to your visitors. It’s a conversation you don’t want to miss!

By the way, this topic is not new. There are numerous ,blog posts, articles and even a book that deal with ‘search analytics’. As usual, I hope to discuss the topic from a GA point of view.

Measuring internal site search with Google Analytics is possible. However, it depends on your website architecture. To track internal search terms with Google Analytics your internal search engine must pass the search term entered by the user in the query string. Google Analytics captures all of the data in the location bar of the browser, including the query string. If the search term is missing from the query string then GA will not be able to track it.

Here’s an easy way to see if GA can track your site search. Go to your website and do a search. On the search results page, does the URL contains a question mark? If so, this means that the search term is probably listed some place after the question mark (called the query string). Here’s an example:

In the above URL the search term entered by the user is ‘search analytics‘.

GA Dynamic Content ReportOK! Once you’ve verified that you can track your site search with Google Analytics, it’s time to look at some data. This is the fun part! Navigate to the Content Optimization > Content Performance > Dynamic Content report. This report lists all of you site pages and the query string variables that are associated with each page. Remember, the search terms are stored in the query string variables.

Find your search page in the report. Then, click on the little plus sign located at the left hand side of each line item to display the query string variable associated with each page. You should now see a list of all the search terms that people entered and how many times that search term was entered. Good stuff, huh! Now you have a direct window into the needs of your visitors.

Identifying common search terms is just the beginning. Let’s consider some other metrics to help better understand the effectiveness of site search in terms of website goals.

  • How many visitors that use your site search, convert? Use the Top Content report and examine the $Index value for your search page.
  • What are people searching for on your site? Use the Dynamic Pages report to view the search terms and how often they are searched for.
  • Do any of the searches return no results? Run some of the most common search queries and look at the results.
  • How often are visitors using your site search? Use the Top Content report to see how many visits include hits to the search page.
  • Are various segments of your visitors more inclined to search? Use GA’s custom segmentation to ‘bucket’ those visitors that use search and then examine their behavior.

Google Analytics can’t tell you all of this, but it can start your search analytics process. Remember, GA is just a data collection tool. While it will provide some great information, you may need to do more digging to get all the numbers you need for your analysis.

Here’s an example of how you might need to go outside of GA for some data. It’s very important to understand which search terms return no results to your visitors. While you could configure GA to record this data, it may be faster to replicate your visitors’ searches and examine the results.

Thoughts Regarding the Google Search Appliance and the Google Mini

Now, if you’re using a Google Search Appliance or a Google Mini, you have a few more options for measuring site search. I recommend reading the Conversion University article titled Increasing Conversions with Internal Site Search. This article gives a nice overview of search analytics pertaining to GA and the Google Mini/GSA.

There is another option for GSA and Mini owners. Both the GSA and the Mini generate a custom log file. My team at EpikOne has successfully re-designed Urchin to process the log files and create reports specific to search analytics.  The neat thing about our Urchin module is that it can be used for a public facing website or for a Mini/GSA that is used on an intranet.  Many intranet owners prefer not to use GA to track usage due to privacy issues.

If you’re interested in our Search Analytics module for Urchin please contact EpikOne.

Be Sociable, Share!

    Like this post? Sign up to get posts delivered to your inbox.


    1. Justin says

      Hi Elliot,

      The key to measuring internal site search is to tag the page that shows the search results with the Google Analytics tracking code. If you are using the Google Search API then make sure the results page you display has been tagged. If you are sending the visitor from your site to Google try to capture the search when they submit the search form. To do this use the urchinTracker function to create a virtual page hit that contains the search term. Here’s a help article about how to use urchinTracker:

      Thanks for reading and the feedback!


    2. Andres says

      Are you sure this works:

      >>Here’s an easy way to see if GA can track your site >>search. Go to your website and do a search. On the >>search results page, does the URL contains a question >>mark? If so, this means that the search term is >>probably listed some place after the question mark >>(called the query string). Here’s an example:


      >>In the above URL the search term entered by the user >>is ‘search analytics‘.

      when the domain of the searchengine is the same as the site you are measuring?



    3. says

      Thanks for some great articles Justin.
      After spending countless hours converting some of my sites with mod_rewrite to be Search Engine friendly, I’m now seeing that removing all those wonderful ? signs seems to now be stopping me from gathering useful data.
      Have you played around much with GA on sites using mod_rewrite to “tidy” the URLs?


    4. says

      Hey Mark,

      Integrating GA with your site can be challenging, especially when your changes can affect things like SEO. In general, most of our clients have moved to SEO and spider friendly URLs. This means that we need get creative in how we capture user actions.

      On thing that I’ve used successfully is urchinTracker. Using this function we can capture user data in GA.

      Check out the series I’m writing. It covers tracking visitor clicks with GA.


    5. says

      Doh! I need to update a lot of these older posts now that the new interface is live. You can find the query string parameters in the Content > Content Drilldown reprot.

      Thanks for reading!



    1. […] Know What Visitors are Searching For: Optimizing internal site search begins with understanding what visitors are search for, how often, and why. Do users resort to site search because of poor site navigation? Are certain queries performed over and over? Your website analytics must answer these questions (Google analytics recently launched a site search feature). In addition, track what percentage of search queries return no results. As you improve this feature, you’ll have a metrics to benchmark your progress. […]

    Leave a Reply

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

    You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>