Aller au contenu
SilktideAide

Site search

The Site search screen shows what people type into your site's own search boxes: how many searches there were, the terms searched most, and how any one term rises or falls over time.

It answers questions such as: what are people looking for that they cannot find from the menu? Did a new page stop people searching for it? What did everyone search for after a news story?

Set it up

Silktide records nothing anyone types until you tell it which boxes are search boxes. Go to Analytics > Settings > Data, and under Site search list a CSS selector for each search box, one per line:

#search
input[name=q]
.site-header input[type=search]

Name the box itself, not the form around it: #search-form input matches the box inside the form, #search-form alone matches nothing that can be typed in.

A selector has to name the box by its id, a class or an attribute. A bare input or form input is refused, because it would match every text box on your site.

Saving updates your Silktide Script for you. Visitors' browsers can keep the old script for up to an hour, so the first searches can take that long to appear.

What is recorded

When someone types into one of your search boxes, then moves on or presses Enter, Silktide records what they typed: one line of text, cut to 128 bytes. That is all.

  • Nothing typed into any other field is recorded, including other boxes in the same form.
  • Only text and search boxes are recorded. A selector that matches a password, email or number field records nothing.
  • With no search boxes listed, nothing typed is recorded at all.

People sometimes type personal details into a search box, such as their own name or a reference number. Only list boxes whose purpose is searching your site.

Read the screen

Searches is how many searches were made in the period, with the period before when Compare is on.

Top searches ranks the terms searched most. Select a term to see it on its own over the period; select it again, or Show every search, to go back to all of them. The address keeps the term you chose, so you can share it.

The Search terms table underneath lists every term, with its searches and how many visitors searched for it. Search, sort and export it like any other analytics table.

Terms are counted whatever their capitals, so Parking and parking are one term. Each is shown the way people typed it most.

Get site search through the API

The Silktide REST API gives you the same figures, with the date range and filters every analytics endpoint takes:

  • analytics/site-search-terms lists every term with its searches and visitors. term is the term in lowercase; label is how people typed it most.
  • analytics/site-searches-over-time counts searches per day. Add term for one term.

Create a key on the API screen; full request shapes are in the developer documentation.

Dernière mise à jour

Cette page vous a-t-elle été utile ?

Site search | Centre d’aide Silktide