About Metrics

Metrics allow you to measure user actions. They help you learn how the changes you are testing affect behavior.

Let's say, for example, that you make a change to your website: you change an image, change the color of a button, or move the content around on the page. These changes are meant to affect how people behave when they are interacting with your website. How do you learn if your changes affect behavior? You build a Metric.

You can use Metrics to measure your KPIs, such as a purchase or form completion. In addition, you can use them to measure secondary indicators, such as add to cart, search results, steps of a funnel, clicks on a button, page views, etc.

Metric Type

The metric type determines what data points your metric will collect when the trigger conditions are met. The options are Event, Numeric measurement, and String capture.

Event
Event metrics will record every time the trigger conditions are met. This could be page views, button clicks, form submissions, or other user actions. In your analytics reports, you will have access to the unique and total hits to the metric.

Numeric measurement
Numeric measurement metrics capture a numeric value along with the unique and total hits. The number can be extracted from the URL, page source, or request payload of the request that matches the trigger conditions. When a metric is configured as a numeric measurement, the value capture conditions are required for the metric to match. 

Your analytics reports will include the captured value in addition to unique and total hits. This is a common choice for tracking order value and item quantity.

String capture
String capture metrics are similar to numeric measurements, but they capture alphanumeric string values. Use this when the strings you are capturing should remain as discrete values, and not be reported as averages or sums. For example, order ID, SKUs added to cart, and categories visited.

The unique and total hits are available in your analytics reports, and the discrete values are also included in the full data exports. 

Method and trigger types

The method determines how you will define when your metric should match. Numeric measurement and string capture are only available with server-side triggers. If you need to capture values from an SPA or PWA website, consider using the custom event listener method.

Trigger
The trigger method allows you to select from a variety of custom, and pre-define global trigger types, such as server-side or client-side URL path, page source, past user behaviors, and request payload content. These triggers can be combined. Triggers are separated into server-side and client-side:

  • Server Side: useful for capturing page views, steps of a flow, form completion, purchases, etc. You can also use this technique to capture events that generate AJAX calls, such as an add-to-cart action. To learn more on creating a Server-Side Metric, see Creating a Metric.
  • Client Side: especially useful for SPAs, or anytime you want to capture a user interaction that does not generate a call back to the server. To learn more about SPAs, see Metrics for Single-Page Applications.

Custom event listener (advanced)
This option will match when a custom event is sent to the SiteSpect EventTrack endpoint. You will include JavaScript code in a global change that sends an event name, and optional value when your action occurs. In your metric definition, you only need to specify the event name. Read more about EventTrack metrics.

Engine API
Useful for capturing user behaviors in a mobile app, Over-the-Top (OTT) devices, kiosks, server side, and any other application that makes HTTP calls. To learn more, visit our developers' site.


For more information on Triggers, see:

To learn how to create a Metric, see Creating a Metric.