Site Search Analytics and GA4: How to See What Your Visitor is Searching for on Your Website

By Andy Crestodina

It’s that little search box in the header of your website. Visitors use it to search for things. It’s often called “Site Search,” and it helps people find what they’re looking for fast. It’s a way to help your visitors.

But for you, the marketer, it’s a listening tool.

The site search tool gives you a peek into what your visitors want from you and your website. And sometimes, it shows you what your visitors can’t find.

It’s an amazing way to find and fix content gaps. In this post, we’ll do four things:

  1. Setup/Reporting: How to see your site search terms reports in GA4
  2. Listen: How to analyze these reports
  3. Empathize: Check to see if visitors are finding what they’re looking for
  4. Take Action: Create (or optimize) content based on your new insights into your visitors’ needs

We’ll do it all using a custom dimension and a “free form” exploration. We’ll walk through the steps for setting this up in GA4.

A lot of websites don’t even have a search tool (only 54% do according to our research). Some sites have them in just one section (on this website, it’s just on the blog), and some sites have more than one search tool!

Here’s how to do site search analysis in GA4.

Site Search setup in Google Analytics 4 (GA4)

Just as Google Search Console shows search activity on Google, this GA4 Exploration shows search activity on your site. As long as the GA4 tag is installed in your Google Tag Manager container, you’re ready to get started.

There’s just one thing to check first: the search parameter. It’s easy to check. When your visitor does a search on your website (suppose their searching for “avocados”), the keyword they searched for appears in the URL on the search results page (www.website.com/?keyword=avacado). The word or letter that appears before the equal sign is your search parameter.

By default, GA4 looks for a few specific search parameters. They are q, s, search, query and keyword. If yours is one of those, you’re all set. If not, you’ll need to add it. from the “Admin” section, follow these instructions:

  • Go to Property Settings > Data Streams
  • Click on your web address (which is probably the only data stream)
  • In the “Enhanced Measurement” section, click on the gear icon
  • Under “Site search” click “Show Advanced Settings”
  • Enter your parameter in the “Search Term Query Parameter” box and click Save.

Screenshot showing Google Analytics Enhanced Measurement settings with a highlighted note instructing to add a search parameter if it isn’t listed under Site Search settings.

All set! Now we’re ready to create the exploration and see how visitors are using our site search tools…

  • Go to explorations and click on “Blank” 
  • In the top right, give your exploration a name, such as “Site Search Analysis”
  • In the Variables column, click the plus sign next to DIMENSIONS.
    A list will slide in from the right. Use the search tool at the top to find “Search Site Terms” and select it. Next search for “Event name” and select it. Click Confirm.
  • In the Variables column, click the plus sign next to METRICS. Again, a list will slide in from the right. Use the search tool to find “Event count.” Select it and confirm.

ga4 report showing how to add a dimension

  • Drag the “Site Search Term” dimension from the Variables column into the Rows box in the Tab Settings column. Drag the “Event count” metric into the Values box.

ga4 report showing how to drag dimensions and metrics

  • Optional… Your exploration is there on the right, but notice how the first row is blank but shows a very high event count. This is the number of times visitors didn’t search. It’s not useful. If you’d like to remove that, you can do so with a filter. Drag the “Event name” dimension into the Filters box. Set the filter to “exactly matches” the event view_search_results.

ga4 report showing how to set up site search

All done! Now we can eavesdrop on our visitors a bit, see what they’re looking for.

How to analyze your Site Search reports in Google Analytics 4 (GA4)

The exploration we created shows the list of the phrases that people search for using your site search tool. It will look like this:

ga4 site search report

Are visitors finding what they’re looking for?

The insights from this search terms report are often so obvious that I’m guessing some of you readers just left and will never finish this article. The usability problems and content gaps are leaping out of Analytics and onto your to-do list for today.

But if you’re still here, let’s do some analysis.

First, pretend you are the visitor and go to your website and search for the top phrases that your visitors are searching for. Look at the search results. What do you see? Anything unexpected? Are you having the same experience you want your visitors to have?

I bet I just lost some more of you. The issues are so obvious that you don’t need any suggestions.

Here are four examples of analysis and actions based on site search data from your Analytics. Each starts with the user’s experience and ends with an action you can take to improve your website.


Jayda Koland Jones
Jayda Koland Jones, BDJ Strategy

“Utilizing data gather sources like GA4 positions you well to collect data, understand the needs of your clients, improve the site experience, and ultimately make decisions using data instead of intuition.” 


Example 1: “I don’t understand your navigation labels”

You are a patio furniture company. You sell all kinds of outdoor stuff for decks, patios and pools. Your navigation might look like this:

sample website navigation with patio chairs, pool supllies and shade solution in the navigation

And here is the GA4 exploration showing the search terms and their relative popularity:

GA4 site search report

See the problem? Your visitors are searching for “umbrellas” because they don’t see it in your navigation. Your navigation says “Shade Solutions” which is a weird term that people never say. Unless you’re a marketer… “It’s going to be hot at the beach today. Don’t forget your shade solution!”

Action! Change your navigation labels to align with the phrases your audience is searching for.

Example 2: “I want to find something faster”

You are a construction equipment dealer. Your website has a resource center with guides for buying all kinds of machines. It’s a big section, so it has a search tool.

website with construction equipment and resources as navigation labels

And here is what your exploration showing search terms look like.

ga4 site search report showing people searched for bulldozer the most

See the opportunity? The page gives them three big options. But since they don’t see what they want, they search.

Action! Add “bulldozers” to one of the labels, give it it’s own section or make one of the images a bulldozer!

Example 3: “The Report of Broken Dreams”

Maybe your visitor is searching, but not finding what they’re looking for…

Imagine you have a toy store. Your site has lots of pages and products, so of course, there is a search tool. When you take a look at your search terms, you can see that visitors are looking for some very specific information: “unicorns”

But what if the visitor searched and left the search results page without clicking on anything? They must not have found what they were looking for. They left without finding anything.

So what are your visitors searching for but not finding? This question is answerable in your Google Analytics account. We just need to see which pages with searches (page path + query string) were also exit pages.

So we need to add the Exits metric to our exploration.

  • In the variables column on the left, click the plus next to Metrics
  • A list of metrics will slide in from the right. Search for “Exits”
  • Check the box next to Exits
  • Click the blue “Confirm” button in the top right corner

Screenshot of Google Analytics showing step-by-step instructions to add the "Exits" metric: add a metric, search for "Exits," check the box, and click confirm.

  • Now drag the Exits metric into the “Values” box in Tab Settings
  • Sort by Exits (descending)

Here’s what you’ll see:

Now you’re looking at a list of what people search for and the last page they visited. You can tell right away that some people are looking for unicorns but not finding any.

They never clicked. They left without the information they needed. That’s why we call this The Report of Broken Dreams. It shows you what your visitors searched for but did not find.

Action! This should be an easy fix now that you have search exit data.

  • Search for the phrase yourself. What do the search results show?
  • If you don’t already have a page on this topic, make one!
  • If you do have a page but it’s not ranking, update the page so it ranks higher for that keyword in your site search results. Put the phrase in the title, header and body text.
  • Now search again. All better?

Site search SEO is a type of optimization that everyone should love. Make your own content rank in your own search tool on your own website.

Example 4: “This page isn’t satisfying”

You are a tax advisor. Your firm offers a lot of services, your site has a lot of pages, so of course, you have a search tool.

In a brilliant act of data-driven empathy, you use Google Analytics to find out where and when people use your search tool. You do this by creating a Path Exploration. Unlike the usual user flow analysis, we’ll start the ending point, which is the search results page:

  • Click to create a path exploration
  • Click “Start over” in the top right
  • Drag the Page path and screen type node type into the Ending Point box

  • A list of pages will slide out from the right. Probably, the URL of your search results page isn’t high on the list, so search for it and select it.

Now you’re looking at a list of the pages from which visitors use your site search tool. Not surprising, a lot of visitors search right from the home page. But what about the other pages? Are they missing some key information? It’s very likely that these pages are not satisfying your visitors information needs.

This is a list of pages with content gaps.

If you reference this list against your list of top search terms, you may quickly realize which pages are missing which information.

Action! Add the missing information to the page. If this info is already on another page, you can also just add a prominent link, directing the visitor to the second page.

Data-driven empathy vs. unmet information needs

Your visitors would rather click or tap than type. They don’t really want to use your internal search tool, but if they don’t see what they want, they’ll use it as a last resort.

It’s a far, far distance from the mouse to the keyboard. It’s even further on mobile. Don’t force them to make the jump. Check your Google Analytics site search reports to see who is crossing that chasm and then build a bridge so your next visitor doesn’t have to.

Looking for ways to use GA4 to measure traffic from organic search?
Read this next 👉 How to use GA4 for SEO: Organic Reports in Google Analytics

There is more where this came from…

The best content from this blog are available all in one place – our book. Now on its 7th edition.

Content Chemistry, The Illustrated Handbook for Content Marketing, is packed with practical tips, real-world examples, and expert insights. A must-read for anyone looking to build a content strategy that drives real business impact. Check out the reviews on Amazon.

Buy now direct $29.95

Book cover of "Content Chemistry" alongside a quote praising it as highly practical for modern digital marketing, attributed to Jay Baer, NYT best-selling author.