- Shoppers who use the search box are telling you, in their own words, what they want to buy. Most stores collect those words and never read them.
- Start by tracking searches properly in GA4, then fix zero-result queries with synonyms, redirects and better product data, and decide what ranks first for your top terms.
- Review search data monthly: it shows product gaps for purchasing, vocabulary for product pages and SEO, and a direct list of conversion leaks to fix.
What is ecommerce site search, and why does it matter for profit?
On-site search is the search box on your store and the results page behind it. It is the one place where a shopper types exactly what they want, without you guessing from clicks.
Someone who types “waterproof hiking boots women 8” has already chosen a category, a feature and a size. If the results show the right boots in stock, the path to the cart is short. If they show nothing, the shopper often leaves, and the click that brought them in is wasted.
Search also shows demand in the customer’s vocabulary. Your team writes product names; buyers write queries. The gap between the two is where revenue leaks.
How do you track site search in GA4?
Google Analytics 4 can record searches automatically through enhanced measurement. According to Google’s documentation, the site search option sends a view_search_results event each time a shopper sees a search results page, and it detects that page through a URL query parameter. By default it looks for the parameters q, s, search, query and keyword, and you can add others in the enhanced measurement settings.
The event carries a search_term parameter, which fills the built-in Search term dimension. Google’s documentation also lists a unique_search_term parameter, sent when the search string is unique to that session.
How that maps to the common platforms:
| Platform | Typical search results URL | What to check |
|---|---|---|
| Shopify / Shopify Plus | /search?q=... |
q is a default parameter, so enhanced measurement usually catches it. Confirm in DebugView. |
| WooCommerce | /?s=... (often with post_type=product) |
s is a default parameter. Check that product searches and blog searches can be told apart. |
| Magento / Adobe Commerce | /catalogsearch/result/?q=... |
q is a default parameter. Custom search modules may use different URLs. |
| Search apps or headless | Varies, sometimes no URL change | If the URL does not change, enhanced measurement cannot see the search. Send a custom event through your data layer instead. |
Three gaps to watch:
- Predictive search. If the shopper clicks a product from the dropdown as they type, no results page loads and no
view_search_resultsfires. Those searches need separate event tracking, usually through Google Tag Manager or the search app’s integration. - Result counts. GA4 does not know whether a search returned results. Send a parameter such as
search_results_countand register it as a custom dimension to isolate zero-result searches. - Shopify’s own events. Shopify’s Web Pixels API includes a standard
search_submittedcustomer event. If you run GA4 through a custom pixel, you can map that event to GA4 rather than relying on the URL.
Our GA4 ecommerce tracking guide covers the purchase and product events you need alongside search.
Which search reports should you look at first?
Build one GA4 exploration with Search term as the row and event count, sessions, purchases and purchase revenue as columns. Four views do most of the work:
- Top search terms by volume. Search the top 50 yourself, in your own store.
- Zero-result searches. Queries that return nothing. On Shopify, the report of top online store searches with no results is a fast place to start.
- High-volume, low-conversion terms. Queries that people type often but rarely buy after. The results exist, but they are wrong, sold out or poorly ordered.
- Search exits. Sessions that end on the results page. A high exit rate on a term means the results did not answer the query.
If searchers show a higher conversion rate than non-searchers, do not read it as proof that search causes sales. Searchers often arrive with stronger intent.
How do you fix zero-result searches?
Every zero-result query falls into one of five buckets. Sort the list into them before changing anything.
| Cause | Example query | Fix |
|---|---|---|
| Synonym or customer vocabulary | “sneakers” when you call them “trainers” | Add a synonym group |
| Misspelling | “lether wallet” | Synonyms or a search tool with typo tolerance |
| Product data gap | “vegan” when no product mentions it | Add the attribute to titles, tags or descriptions |
| Non-product intent | “returns”, “shipping”, “size chart” | Redirect to the policy or help page, or include pages in results |
| Real product gap | A product or size you do not sell | Show the closest alternatives and pass the term to purchasing |
Synonyms
On Shopify, the Search & Discovery app lets you create synonym groups. Shopify’s help center says grouped terms are treated as exact matches for one another, each synonym can be one to five words, a group holds up to 20 synonyms and a store can have up to 1,000. Synonyms are not applied to SKU or barcode fields. WooCommerce and Magento need a search plugin or extension for comparable control.
Keep groups tight: “running shoes” may not belong with “sneakers” if it is a separate category.
Product data
Many zero results come from information that exists but is not searchable, such as materials, fits or compatibility. Adding those attributes to titles, tags or structured fields fixes search and product pages together. Our guide on product description writing covers how to write attribute-rich copy.
No dead ends
Even when you have nothing, never show an empty page. Show bestsellers in the nearest category and a link to browse collections.
How do you decide what ranks first in search results?
For your top 20 queries, decide the first row of results yourself instead of leaving it to default relevance.
- Boost the products you want to sell. Shopify’s product boosts let you assign up to 10 search terms to a product, and Shopify says boosts apply only to available products. Use them to push high-margin, in-stock bestsellers to the top for broad terms like “jacket” or “gift”.
- Push sold-out items down. Search & Discovery lets you show, hide or place out-of-stock products last. Last is usually the safer default, so shoppers still find the item and its back-in-stock signup.
- Weigh margin, not only popularity. Boost only among products that already convert, then let margin decide the order.
- Use filters on broad queries. Searches for “dress” return too much. Facets for size, color and price help, and the same logic applies as in faceted navigation on collection pages.
On Shopify, Semantic Search can be turned on in Search & Discovery for English storefronts with fewer than 200,000 products on the Shopify, Advanced or Plus plan. It matches meaning rather than exact words, but it does not replace synonyms for your own brand and product names.
What else can search data tell you?
Search queries are a free research panel. Three teams should see the monthly export:
- Purchasing. Repeated searches for a product or size you do not stock are a demand signal. Watch them for several months before acting.
- Content and SEO. Customer vocabulary belongs in collection names, product titles and FAQ content. If shoppers search “work bag” and you call it “tote”, your organic pages likely miss the same term. See our guide to Shopify collection page SEO.
- Paid media and email. A rising query is worth a quick test in search ads or an email.
Worked example: sizing one search fix (illustrative numbers)
All numbers below are illustrative.
A store records 10,000 searches a month. A review shows that 8% of them, 800 searches, return zero results. Most fall into three buckets: “trainers” (the store says “sneakers”), common misspellings of the brand’s best-known product, and “size guide”.
- Before the fix: assume those 800 searches lead to almost no purchases, because shoppers exit or browse aimlessly.
- The fix: two synonym groups, one redirect from “size guide” to the size chart, and the misspellings added as synonyms. About one hour of work.
- After the fix: if 600 of the 800 searches now show relevant products, and those sessions convert at 3% with a $90 average order value, the store gains about 18 orders and $1,620 in revenue a month.
- Check against margin: at a 40% contribution margin, that is about $650 a month in contribution, or roughly $7,800 a year, from one hour of work.
Measure the same terms for four weeks before and after, and expect seasonal noise.
Monthly site search review checklist
- [ ]
view_search_results(or your custom search event) fires on every search type, including predictive search clicks. - [ ] Search term appears in GA4 with real queries, not blank or “(not set)”.
- [ ] A result count parameter is sent, so zero-result searches can be filtered in GA4.
- [ ] The top 50 queries were searched by hand on mobile and desktop.
- [ ] Every zero-result query in the top 100 is sorted into a cause bucket and fixed or logged.
- [ ] Non-product queries (“returns”, “shipping”, “track order”) lead to the right help page.
- [ ] The first row of results for the top 20 queries shows in-stock products you want to sell.
- [ ] The results page never shows an empty state without alternatives.
- [ ] Product gap queries were shared with purchasing.
- [ ] New customer vocabulary was passed to the SEO and content owners.
FAQ
Does GA4 track site search automatically?
Partly. Enhanced measurement sends a view_search_results event when a search results page loads with a recognized URL parameter, such as q or s. It misses searches that do not load a results page, such as clicks from predictive search dropdowns, and it does not record how many results each search returned. Those need custom events.
Should we buy a dedicated search app?
Fix the basics first: tracking, synonyms, zero-result handling and boosts for top queries. If you have a large catalog, many attributes or frequent misspellings and still see high search exits after that, a dedicated search tool with typo tolerance and merchandising rules can be worth testing. Judge it on revenue per search session, not on features.
How often should we review search data?
Monthly for the full review, and weekly around a big launch or seasonal peak. Search terms shift with the calendar, so boosts set in spring may need changes before the holidays.