This is a quick walk through on how to track site search in Google Analytics. To be specific, we’ll be tracking your internal site search in Google Analytics. This is one of the more basic functions, but Google’s resource on this topic is not explicitly clear and the site search data does not show in Google Analytics in real time making for some unknown between implementing and tracking of site search in Google Analytics.
Your site search data will clean your URLs and deliver a report for you such as the below, and, yes, I know I chose some real mature keywords for this example:
Before I get into how to track site search in Google Analytics one might ask:
Why Track Site Search In Google Analyctics?
Tracking your site search in Google Analytics provides you with insight not on what you’re doing well, but potentially on what you’re missing. You see how people search and this is a lost metric since Google decided to hide organic keyword referral data. Site search generates page views, so you can back into your site search data via your content break down, but this is far more clean.
What your visitors are searching for is what they did not find on your landing page.
How to Track Site Search In Google Analytics
Fortunately, it is incredibly easy to track site search in Google Analytics.
1. Test a search on your site and note the term, or letter, just before the “=” sign. Specifically this is known as the search query parameter and will differ by site architecture. For example, a test on my site reveals that this term is simply “s” without the quotes. Note that it will typically be “s,” “q” or “search.” For me, the “s” is all I need. Do not include the “?” or “=” because it will not work and I think this is where Google missed the mark in the instructions:
2. Specify your query parameter in Google Analytics. This is specific to view, so make sure you’re in your right Google Analytics view. Note the letter or word from the previous step. You can have up to five separated by commas. Google Analytics > Admin > View Settings > Toggle Site Search Tracking On > Set Query Parameter from step One > Do not check “Strip query parameters out of URL” > Save
3. Allow time for Google Analytics to capture your site search. This activity will not show in real time reports per my testing.
4. View site search tracking in Google Analytics. Reporting > Behavior > Site Search
That’s how to track site search in Google Analytics. You can make this more robust if your site search is a bit more sexy to include categories etc., but I don’t have that implementation to share on this site. Note that tracking site search this way Google Analtyics has stripped the equal sign as well as “&submit=search” making for a clean report with very easy configuration.