Where it happens
- Internal search
- A search box on your own site
- External search
- A web search engine such as Google or Bing
Internal search is the search box on your own site. See what its queries tell you, how GA4 tracks them, and how to keep its result URLs from wasting crawling.
Internal search, also called site search, is the search function on your own website that lets visitors look for content within it, as opposed to searching the web with Google. Its value is the data: Google Analytics 4 can record each search term, which shows what visitors want and could not find through your navigation.
Four quick questions, then a straight answer.
From your answers, this is quietly costing you traffic and nobody has the hours to chase it. Scaplet finds every affected page, drafts the fixes and tracks how AI answers mention you.
A data platform shipped 46 fixes without a ticket.
This looks handled. Re-check after a redesign, a migration or a big content push; that is when it breaks.
Your site is small and you have the time. Work through the steps on this page, starting with the pages that get the most traffic.
In an enterprise setting the phrase can also mean searching a company's internal documents and apps. This page covers the website meaning, where visitors search a public site.
view_search_results event as firing each time a user is shown a search results page, as indicated by a URL query parameter. By default it looks for one of 5 parameters in the URL: q, s, search, query and keyword. The search term fills the Search term dimension.Google notes that the event only sends the unique_search_term parameter when its value is 1, meaning the string is unique to that session. See Google Analytics 4 for the rest of the setup.
Run a search on your site and look at the address. If it reads /?s=shoes or /search?q=shoes, a default parameter is already covered.
If your search uses another name, such as term, add it in the enhanced measurement site search settings. Google says you can optionally configure the event to look for other query parameters.
Search once on your site, then check that view_search_results appears in realtime reporting or DebugView, with the term in search_term.
/search?q=anything. Google's guidance on faceted navigation describes a similar problem for filter URLs: its most common implementation, based on URL parameters, can generate infinite URL spaces, which leads to overcrawling and slower discovery crawls of new, useful URLs. Google's doorway spam policy also lists creating substantially similar pages that are closer to search results than a clearly defined, browseable hierarchy.If you do not want result pages in Google, Google's robots.txt documentation says robots.txt is used to manage crawling and to avoid crawling unimportant or similar pages. It also warns not to use it as a way to hide pages from Search: a blocked URL can still appear in results, without a description, if other pages link to it. To keep a page out of results, use noindex or password protection.
User-agent: *
Disallow: /search4 questions people ask next, answered from the sources on this page.
A search function inside a website that lets visitors find content on that site, as opposed to searching the web with a search engine. It is also called site search.
External search happens in a search engine such as Google and returns pages from many sites. Internal search happens on one site and returns only that site's content. Internal search terms show you what visitors want after they arrive.
Turn on enhanced measurement for the web data stream. GA4 then records a view_search_results event when a URL contains q, s, search, query or keyword, and fills the Search term dimension.
The Google documents cited here give no rule just for them. They cover the underlying risks: infinite parameter URLs and near-duplicate pages. If you don't want them in Search, use robots.txt to manage crawling or noindex to keep them out of results, and don't rely on robots.txt to hide pages.
The free audit reads robots.txt, sitemaps, status codes, canonicals, redirects and structured data.