Search is the most direct path between a user’s intent and your content — and ElasticProbe gives WordPress sites the speed and relevance of Elasticsearch. But fast search alone isn’t enough: you need visibility into how people search and what they click. Piping ElasticProbe signals into Google Analytics (GA4) — including both site search and Autosuggest interactions — turns raw behavior into actionable intelligence for product, content and commerce teams. This article explains why this matters and gives a clear, step-by-step guide to enable both search-term tracking and Autosuggest analytics using Google Analytics and Google Tag Manager (GTM).
What you gain by combining ElasticProbe and Google Analytics
Understand intent at scale. See which queries bring users to your site and what they do next (click a result, refine the query, bounce).
Measure interaction with suggestions. Track which Autosuggest suggestions users click to measure usefulness and surface improvements to the suggestion set.
Identify content gaps & merchandising opportunities. Frequent queries with poor results point to content you should create or products to surface.
Optimize conversion funnels. Link search interactions to conversions and revenue to prioritize search improvements that move the needle.
These capabilities are straightforward to unlock because ElasticProbe can emit analytics-friendly events and GA4/GTM can capture, enrich and report on them.
Part A — Enable basic site-search tracking in GA4
If you only need to capture the terms users type into your site search and see them in Google Analytics, GA4 has a built-in Site Search toggle:
Sign in to Google Analytics and choose the appropriate property/stream.
In Admin → Data Streams, open the active data stream.
Under Enhanced measurement, make sure Site search is turned on.
After that, create or configure a report in GA to display the site search terms (GA reports or Explorations).
That’s the minimal setup for seeing what terms visitors enter on your site. For richer, event-level insight (especially for typeahead/autosuggest interactions), follow the Autosuggest + GTM flow below.
Part B — Track Autosuggest interactions: full setup (ElasticProbe + GTM + GA4)
ElasticProbe can push Autosuggest interactions into the data layer; GTM forwards those events to GA4 and you register custom dimensions to analyze the data.
Step 1: Enable GA events in WordPress

In your WordPress admin go to ElasticProbe → Features → Autosuggest.
Check Trigger Google Analytics events and Save changes.
This turns on the client-side behavior that pushes Autosuggest events to the data layer.
Step 2: Create Data Layer Variables in Google Tag Manager
When a user clicks an autosuggest item, ElasticProbe sends two values to the data layer: the search term and the clicked URL. In GTM create two User-Defined Variables (Data Layer Variable type):
Title: EP Autosuggest – Clicked URL
Data Layer Variable Name:ep_autosuggest_clicked_urlTitle: EP Autosuggest – Search Term
Data Layer Variable Name:ep_autosuggest_search_term
Create each variable once as above so GTM can reference them in tags.
Step 3: Create the GA4 Event Tag (GTM)
In GTM → Tags → New → choose Google Analytics: GA4 Event.
Name it e.g. Autosuggest GA4 Event.
For Measurement ID, use your GA4 Measurement ID (or the variable you already use for GA).
Set Event name to
ep_autosuggest_click.In Event parameters, add two parameters:
ep_autosuggest_search_term→ value{{EP Autosuggest – Search Term}}ep_autosuggest_clicked_url→ value{{EP Autosuggest – Clicked URL}}
Configure the trigger to fire on the custom event ElasticProbe uses (test in Realtime to discover the exact event name if needed), save the tag, then Publish your GTM container. Don’t skip publishing — the page stresses saving and publishing your GTM version.
Tip: After publishing you can confirm events in Google Analytics → Realtime → Event count by Event name — your
ep_autosuggest_clicktests should show up there shortly.
Step 4: Register custom event parameters as custom dimensions in GA4
To use the search-term and clicked-URL strings in reports and Explorations, register each event parameter in GA4:
In GA → Admin → Property → Custom definitions → Create custom dimension.
Create one for EP Autosuggest Clicked URL with event parameter
ep_autosuggest_clicked_url.Create one for EP Autosuggest Search Term with event parameter
ep_autosuggest_search_term.
(One custom dimension per parameter.)
Step 5: View and analyze
Events Report: Go to Reports → Life cycle → Engagement → Events to find the
ep_autosuggest_clickevent and counts.Explorations: For deeper analysis (queries vs. clicked URLs, conversions after suggestion clicks), create a custom Exploration, add your new custom dimensions, and shape rows/columns as needed. This gives you flexible tables and funnels built from Autosuggest events.
Note: GA data can take time to appear in standard reports (Realtime shows immediate tests, but full processing can be delayed).
Practical tips & best practices
Naming & consistency: Use clear event and parameter names (the
ep_…convention used above is good) so reports stay readable.PII caution: Never push personally identifiable information to analytics. Restrict and sanitize any user-submitted strings if needed.
Test thoroughly: Use GTM Preview + GA Realtime to confirm that variables and events are firing with expected payloads before publishing widely.
Iterate on suggestions: Use Autosuggest click data to surface high-performing suggestions, retire misleading ones, and prioritize content creation for frequent queries that return poor results.
Combine with conversions: Link suggestion-clicks/search-terms to downstream conversions to quantify business impact.
Pairing ElasticProbe with Google Analytics (and GTM for the Autosuggest flow) converts search behavior into a measurable product signal: what users are looking for, what they select, and whether search leads to success. With a handful of GTM variables, a single GA4 event, and two custom dimensions, you’ll have the instrumentation to improve search relevance, boost conversion, and close content gaps — all driven by real user intent. Follow the quick GA4 site-search toggle for basic term capture, and use the Autosuggest + GTM recipe when you need event-level insights.
Further reading: