Short answer
To improve on-site search, first collect search terms in GA4 with the view_search_results event, then sort the terms that return nothing by cause. Synonym and typo rules, the results page and the empty page are fixed from that list, and every change is re-measured weekly.
A visitor types “tisort” into the search box of your sportswear shop. The catalogue holds hundreds of products saved as “Tişört”, yet the screen says “0 results found”. The visitor does not try a second search and closes the tab. You never see it, because nobody’s report includes the search box. That is why the first answer to how to improve on-site search in an online shop is measurement: you see what people search for first, then what they cannot find. This guide takes you through that order step by step.
We cover the product page itself in how to build an e-commerce product page and traffic from search engines in our e-commerce SEO guide. Here we look only at the shop’s own search box.
1. Measure the search event in GA4
According to Google’s enhanced measurement documentation, the view_search_results event fires each time a user is shown a search results page, based on the presence of a query parameter in the URL. By default it looks for five parameters: q, s, search, query and keyword. If your shop uses another one, you can add it in the advanced settings. The searched word arrives in the search_term parameter and fills the “Search term” dimension described in the dimensions documentation.
Check the setup like this:
- Run a search in your shop and look at the URL of the results page. Which parameter holds the searched word?
- If it is not one of the five above, have it added in the GA4 enhanced measurement settings.
- If the results URL carries no parameter at all (for instance, results load without a page refresh), you have to send the event yourself. The
searchevent in Google’s recommended events list exists for this, and itssearch_termparameter is required. - Run a search in DebugView or the real-time report and confirm that the event and the term arrive.
For the wider GA4 setup, see the GA4 setup checklist; for reading the reports, see how to read GA4 reports.
2. Read the search terms and sort the ones with no results
Once terms are arriving, we suggest reading them in a free-form exploration. Our setup: the “Search term” dimension in rows, event count and users as values, and a filter on the view_search_results event. Pick the last 30 days and sort from most to least.
For most shops the first 50 terms are enough. Next to each term, write three questions: is it in the catalogue, does the search box find it, and are the first results what the visitor wanted? To answer them you need to type each term into your own search box. The documented parameters of the event do not include a result count. If you want a count next to each term, ask your developer to send it as a separate custom parameter.
The list below is an invented example; it only shows how to read the data.
| Search term | Event count | Results | Note |
|---|---|---|---|
| tisort | 40 | 0 | Turkish characters missing |
| t-shirt | 25 | 0 | The catalogue says “tişört” |
| koşu ayakkabısı | 30 | 12 | First results are walking shoes |
| kargo süresi | 18 | 0 | An information question, no product wanted |
Not every term with no results fails for the same reason. Setting rules without finding the cause just piles them up. The table below sorts the terms into groups and puts the fix next to each.
| Cause | Example term | What to do |
|---|---|---|
| Typo or missing Turkish characters | “tisort”, “ayakkabi” | Typo tolerance, character mapping |
| The customer uses another word | “t-shirt”, “sneaker” | Synonym list |
| Plurals and suffixes | “tişörtler”, “tişörtü” | Stemming setting |
| Code, model or size | “42 numara”, a model code | Add it to product data and filters |
| The product really is missing | A brand you do not sell | Suggestions on the empty page, a catalogue decision if needed |
| Information is wanted, not a product | “iade”, “kargo” | Send them to the help page from the results |
The last two groups in the table are catalogue and content decisions. A crowd that keeps asking for a product you do not sell is a signal for a new product; questions like “kargo” are a reason to update your FAQ page.
3. Set up synonym, typo and Turkish-character rules
Turn the table from step 2 straight into rules:
- A synonym list. Write pairs such as “tişört” and “t-shirt”, or “bot” and “postal”, in both directions. Feed the list from your search data rather than from a dictionary; customers type words the way they use them.
- Turkish-character mapping. Search should treat “tisort” and “tişört”, “ayakkabi” and “ayakkabı” as the same word. “I” and “İ” can get mixed up when text is converted to capitals, so test the mapping with both letters.
- Typo tolerance. Words that differ by a letter or two map to the closest product name. Keep the tolerance narrow for very short terms (three or four letters), or unrelated results appear.
- Plural and suffix analysis. “Tişörtler” and “tişörtü” should resolve to the root “tişört”.
- Field weighting. Matches in the product name, brand and category come before matches in the description. A word that appears once in a long description should not outrank a product that has it in its name.
The tool depends on your platform. If your shop software has a built-in search setting, switch that on first. If it is not enough, you can consider a separate search service; that decision depends on the number of products and how often the catalogue changes.
4. What the results page and filters should show
Even a search that finds the right product loses the sale on a poor results page. Each element below answers a question the visitor has just asked.
- The searched word and the result count sit at the very top: “48 products for tişört”. People want to see what the search understood.
- The product card carries the image, name, price and stock status. Out-of-stock items go to the end of the list.
- Sorting defaults to relevance, with price and newest beside it.
- Filters fit that result set: a search for t-shirts shows size and colour, not a computer filter. If each option shows how many products it will return, the visitor does not land on an empty result.
- Selected filters appear at the top and can be removed in one tap; otherwise people cannot tell why they see so few products.
- On a phone the search box stays open, filters open in a full-screen panel and a “show results” button stays fixed.
How Google treats filter URLs is a separate subject. Google’s faceted navigation documentation says that filters built on URL parameters can generate a very large number of URLs and lead to overcrawling. We cover the decision in the filter and parameter URLs section of our e-commerce SEO guide. We suggest applying the same logic to search result URLs: they are useful to visitors, but they do not need to sit in the index as separate pages.
Watch the opposite direction too. Google’s ecommerce structure documentation says that Googlebot generally does not try to submit searches into a search box. If a product can only be reached through the search box, Google may not find it. Search should stay a way to navigate, and products should also be linked from your categories.
5. Make the “no results” page work
On most shops the empty results page is a one-line warning. Yet it is the only place where the search term is not wasted. Put these on it:
- The searched word exactly as typed, with a “did you mean” suggestion.
- A broader search: the same query without its last word, or a related category.
- Popular categories and best sellers. The visitor needs somewhere to go; the screen should not just end.
- A way to reach a person: phone, email or live chat. Someone who cannot find a product in your catalogue may want to ask.
- Measurement. Give the empty page its own event or page title, so you can count how many searches end there.
6. Re-measure every week and compare
After each change, open the same report. We suggest a weekly rhythm: type the first 50 terms in again, count the ones with no results, and shorten the list. To see the effect, compare the conversion rate of sessions that used search with sessions that did not, as two separate segments in the exploration. You can calculate the rates with the conversion rate calculator. The gap between the two groups alone does not prove the search box works; people who use it may simply have more intent. So compare the same group before and after the change.
For visitors who add a product they found through search to the basket and leave without buying, you can move on to our cart abandonment guide.
Common mistakes
- Not measuring the search box. Without term data, a synonym list is guesswork.
- Squeezing every zero-result term into one rule. A typo and a missing product need different fixes.
- Writing synonyms from a dictionary. The customer’s word is sometimes not in the dictionary; search data comes first.
- Showing the same filters for every search. Irrelevant filters crowd the results page.
- Leaving search result URLs open to crawling. They can create an endless number of URLs.
- Giving no way out on the empty page. If a visitor sees only one sentence, they leave the site.
Common questions
How do I see on-site search in GA4?
According to Google’s documentation, the view_search_results event fires on the search results page, and the search_term parameter fills the “Search term” dimension. You can list the terms with their event counts in a free-form exploration. If your URL uses a different parameter, add it in the advanced settings.
How do I find searches that return no results?
Type the terms that arrive through the GA4 event into your shop’s search box one by one, and note those that return nothing in a table. You can also send the result count as a custom parameter. Sorting the terms into typos, synonyms, missing products and information questions makes the fix easier.
Should search result pages be indexed by Google?
We suggest that search result URLs should not sit in the index as separate pages. Google’s documentation advises blocking crawling of faceted URLs if you do not need them indexed, and the same logic can be applied to search result URLs. The pages you want indexed are your category and product pages.
One thing you can do today
Open GA4, list the 20 most searched terms of the last 30 days in an exploration, and type each one into your own shop’s search box. Note the ones that return nothing or the wrong thing in a two-column table (term, what was found). Your first synonym and typo rules come from that table. If you would like to review your shop’s search together, take a look at the scope of our e-commerce service.
Sources
- Google Analytics Help: Enhanced measurement events (site search: view_search_results)
- Google Analytics Help: Dimensions and metrics (Search term)
- Google Analytics developer documentation: Recommended events (search)
- Google Search Central: Managing crawling of faceted navigation URLs
- Google Search Central: Help Google understand your ecommerce site structure
This article is general information, not legal, financial or technical advice. Platforms, their rules and the law change over time, so some details may have changed since 15 November 2026 or contain small errors. Before you make a decision for your business, check the current official sources or write to us.