Configure Events

The variable is used to record common shopping cart success events as well as custom success events.

Max Size Debugger Parameter Reports Populated Default Value
No Limit events

Shopping Cart Events

Custom Events


An event should be considered a milestone within a site. Success events are most commonly populated on the final confirmation page of a process, such as a registration process or newsletter sign-up. Custom events are defined by populating the events variable with the literal values defined in the Possible Values section below.

By default, success events are configured as counter events. Counter events count the number of times a success event is set (x+1). Events can also be configured as numeric events. Numeric events allow you to specify the number to increment (as might be necessary when counting dynamic or arbitrary values, such as the number of results returned by an internal search).

A final event type, currency, allows you to define the amount to be added (similar to numeric events), but displays as currency in reports, and is subject to currency conversions based on the s.currencyCode value and the default currency setting for your report suite. For additional information on using numeric and currency events, see Products.

Configuring the Variable

The variable is enabled by default for all implementations. The seven pre-configured conversion events are automatically enabled for all new report suites. New custom events (event1-event100 or event1000) can be enabled by any admin-level user using the Admin Console.

Possible Values

The following is a list of possible values for the events variable:

Event Description Reports Populated
prodView Product Views Products
scOpen Open / Initialize a new shopping cart Carts
scAdd Add item(s) to the shopping cart Cart Additions
scRemove Remove item(s) from the shopping cart Cart Removals
scView View shopping cart Cart Views
scCheckout Beginning of the checkout process Checkouts
purchase Completion of a purchase (order) Orders
event1 - event1000 (event100 for point product) Custom events Custom Events

Syntax and Examples

Counter Events

Counter events are set by placing the desired events in the variable, in a comma-separated list (if multiple events are to be passed)."scAdd""scAdd,event1,event7""event5""purchase,event10"

If on H23 code or higher, counter events can have integers greater than one assigned to them."event1=10""scRemove=3,event6,event2=4"

Implementing counter events with assigned integer values treat the event as if it fired multiple times within the image request. Counter events do not allow decimals- it is recommended to use numeric events instead if this functionality is required.

Numeric/Currency Events

Numeric and currency events must be included in the variable, though they typically receive their numerical value (e.g., 24.99) in the s.products variable. This allows you to tie specific numeric and currency values to individual product entries.

With Products"event1"
s.products="Footwear;Running Shoes;1;99.99;event1=4.50""event1,event4"
s.products="Footwear;Running Shoes;1;99.99;event1=4.50|event4=1.99"
Without Products

You can also track these types of events by leaving the product and category fields blank. This was the process to measure data such as tax and shipping before support was added for decimal values outside of the products string. If you want to pass a numeric or currency value but do not want to tie these to an individual product (such as a discount applied to an entire order, or a value captured outside of the product view or shopping cart process), this can be done by using s.products as shown below, but leaving the product and category fields blank."event1"
In the Events List

Numeric/Currency Events that are given a value directly in events list apply to all products in the products list.

This is useful to track order-wide discounts, shipping, and similar values, without modifying the product price or by tracking it in the product list separately. For example, if you configured event10 to contain order-wide discounts, a purchase with a 10% discount might appear similar to the following:"purchase,event10=9.95"
s.products="Footwear;Running Shoes;1;69.95,Running Essentials;Socks;10;29.50"

On Numeric/Currency Event reports, the report total represents the de-duplicated event total (in this example, the total amount of discounts during the reporting period), not the sum of the event values for each product.

Note: if a value for a Numeric/Currency Event is specified in the products string and in the event string, the value from the event string is used.
Combining Counter Events and Numeric/Currency Events

Counter events can be passed along with numeric/currency events by passing all desired events in the variable, and then passing only the numeric/currency events in the s.products variable.

Event Serialization

By default, an event is counted every time the event is set on your site.

See Event Serialization for more information.