Events are the building blocks of analysis in the Contentsquare Experience Platform. Use events to measure interactions such as viewing a product, clicking Add to cart, submitting a form, or completing a purchase.
Think of data collection and event definition as separate:
- Collection records activity from your website or app.
- Defining an event selects matching activity and gives it a reusable name.
How the user-centric data model works
Experience Platform is user-centric: it starts with the people using your website or app and connects their activity across sessions, devices, and data sources. Sessions and pageviews provide context, but events let you describe and measure specific actions.
Experience Platform organizes activity into four levels:
- Users are the people who use your website or app.
- Sessions are periods of activity from a user.
- Pageviews or screenviews describe the page or screen being viewed.
- Events describe specific behaviors that happen during that activity.
- Pageviews or screenviews describe the page or screen being viewed.
- Sessions are periods of activity from a user.
For example, a customer may:
- Visit your website as one user.
- Start a session.
- View a product page.
- Click "Add to cart".
- Complete checkout.
You can define events such as "Add to cart clicked" and "Completed checkout" so that you can analyze those actions repeatedly.
The same activity can answer different questions depending on what you count:
- Users: How many distinct people performed the action?
- Sessions: During how many visits did the action occur?
- Events: How many times did the action occur?
This model lets you move from a broad question, such as “What did users do?”, to a specific question, such as “How many users clicked Add to cart but did not complete checkout?”
How many events should I define?
To start analyzing your data, define a small number of events that answer specific questions. You do not need to create your entire tracking plan before you begin. Add more event definitions when new questions come up.
Before creating an event, open Definitions → Events and check what already exists. Available event types depend on your data sources and tracking implementation.
Types of events and event inputs
Defined events
A defined event is a reusable selection of collected activity with a business name and criteria. You can create a definition manually, visually, or from an interaction received in Data Feed.
A new definition can match relevant activity that was already captured and is still available. New tracking or a property added later cannot recover data that was never collected.
Custom Events
Use a Custom Event when the signal you need is not available in collected activity or when you need a backend or success signal.
Examples include:
- A confirmed order.
- A successful cart update.
- A payment validation.
- A backend process completing.
- A business event with additional context.
When the required signal is not available, ask a developer to send a Custom Event through code or Google Tag Manager. A signal that already exists in the site’s data layer can be relayed this way, but it does not automatically become an event definition. Validate that the signal appears in Data Feed before using it in analysis.
How to create an event
Experience Platform has four ways to create events: manually, visually, from Data feed, and by combining existing events.
Create an event manually
Use manual event creation when you want to define an event based on a data source, data type, and filter criteria.
Navigate to Definitions → Events → Create event → Manually.
Give the event a name, description, then set Type and Filter to describe the action.
You can also use simplified attribute selectors to match data attributes:
[key]Targets elements with a key attribute[key=value]Target elements with a key attribute that's value.[key*=value]Targets elements containing value.[key^=value]Targets elements starting with value.[key$=value]Targets elements ending with value.
Use visual event creation
Use visual event creation when selecting an element on the site is straightforward. Even if you don't know the exact target element you want ahead of time, you will see suggested target elements (which you can also edit).
Visual Event Creation currently supports:
- Clicks
- Changes
- Form submits
To create an event visually:
- Navigate to Definitions → Events → Create event → Visually
- Choose your Data Source and URL.
- Click Launch
- Select the relevant element or interaction on your website.
- Click Edit if you want to pick a different target element or filter by text, attributes, or conditions.
- Give the event a clear name.
- Save the event.
Use Data Feed
Data Feed is useful when the event needs to enter Experience Platform through a data pipeline rather than from a visual interaction on a Web page.
Data Feed shows activity generated by your instrumented website or app. Opening Data Feed by itself does not generate test activity.
To create an event from a website interaction:
- Open Data → Records → Data Feed in one browser tab.
- Select the correct website data source.
- Make sure the feed is running, not paused.
- Select My data only.
- In a second tab, open the website in the same browser profile. Use a normal browser tab outside the visual-definition overlay.
- Complete any prerequisites for the action and follow the normal consent process.
- Perform one deliberate action.
- Return to Data Feed and wait a few seconds for the interaction to arrive.
- Select Pause when you see the interaction.
- Match the timestamp, page URL, target, and properties to the action you performed.
- Select Create on the row of the interaction you want to name as an event.
- Review the source, type, and criteria, give the event a business name, and save it.
- Resume the feed and repeat a positive test, followed by a negative test.
The negative action may still appear as a raw interaction. It should simply not match the saved event criteria.
For a mobile app, perform the action on an instrumented test device and use the available device or app filters to isolate the activity. Do not assume that the desktop My data only filter identifies the app user.
Combine events
If you have multiple separate events that you want to analyze together, create one combined event that represents both. For example, create a “Trial Signup” combined event from the “Free Trial” and “Sign Up” events.
To create combined event:
- Navigate to Definitions → Events → Create event → Combine
- A checkbox column will appear; select the events you want to combine
- Click Combine
Organize and validate events
Naming conventions
Use a business name, not a technical selector, as the event name. "Slot selection viewed" is clearer than click "div.flex".
Use a consistent naming pattern, such as:
Location — Action — Object
Examples:
- Homepage — Click — Sign up button
- Product page — Click — Add to cart
- Checkout — Submit — Payment form
- Account settings — Click — Change password
Choose one tense and use it consistently. For example, use either "Start checkout" or "Started checkout" throughout your event library.
Add a short description that explains:
- What the event includes.
- What the event excludes.
- Why the event was created.
- How it differs from similar events.
- Any known exceptions.
Tips for creating reliable event criteria
A single action can appear in several contexts. An Add to cart button may appear on a product detail page, product listing page, search results page, or recommendation widget. The markup and classes may differ between contexts and may change after a redesign.
Event criteria do not support CSS pseudo-classes or direct child selectors.
The UI may allow you to enter these selectors, but they may not match activity. Avoid pseudo-classes such as :first-child, :last-child, and :nth-child(), as well as child-selector chains such as #header > nav > div > button > span. Use stable attributes and Page type or page group filters instead.
Use stable attributes for event criteria whenever possible. The recommended priority is:
data-tracking-iddata-csqdata-heapdata-testiddata-test-id
Reuse an existing quality-assurance attribute instead of adding a new one when it already identifies the action reliably.
For example:
[data-tracking-id="add-to-cart"]
To restrict the event to one context, keep the selector broad and add a Page type or page group filter instead of adding the context to the selector.
Test event definitions
Test every context you intend to include, along with a similar context that should be excluded.
For example, if you define "PDP add to cart", test:
- The Add to cart button on a product detail page.
- The Add to cart button on a product listing page, if it should be excluded.
- A similar button that should not match.
Naming an event "PDP add to cart" does not restrict it to product detail pages. The criteria must do that.
Use events in analysis
Charts
Open Reports → Charts → New chart and start with one event and one metric. Set the data source, metric, counting unit, event or behavior filter, date range, and any breakdowns you need.
Choose the counting unit deliberately:
| Counting unit | What it counts |
| User | Distinct tracked users who meet the criteria. |
| Session | Distinct periods of activity that meet the criteria. |
| Events | All matching instances of the selected action. |
If one user performs an action four times across two sessions, the result is one User, two Sessions, and four Events.
Before interpreting a metric, check what triggered it, which pages or platforms it covers, and whether repeated actions are expected. Four real clicks can correctly count as four Events without being a tracking error. A click count does not prove four successful cart additions.
Funnels
Open Reports → Funnels to measure an ordered path. Choose event definitions for steps such as pageviews, clicks, form interactions, Custom Events, or errors.
A funnel can measure users across sessions or sessions within one visit. Check the analysis scope and conversion window before interpreting drop-off.
Event examples by industry
E-Commerce & Retail
- Product Search Performed: Triggered when a user submits a keyword search on the site.
- PDP Add to Cart: Triggered when a user clicks the main cart addition button on a Product Detail Page.
- Cart Updated Successfully: Custom success signal sent when an item is confirmed added to the shopping basket.
- Delivery Slot Selected: Triggered when a user chooses a pickup or delivery window.
- Checkout Started: Triggered when a user initiates the checkout process.
- Order Completed: Triggered on the order confirmation/thank-you page or via a transaction success event.
- Store Locator Clicked: Triggered when a user interacts with the physical store locator tool.
SaaS & B2B Web Platforms
- Registration Started: Triggered when a user begins the sign-up or trial flow.
- Free Trial Started: Triggered upon initial account registration completion.
- Demo Requested: Triggered when a prospect submits a sales lead or demo request form.
- Account Created: Triggered when user registration is successfully validated and completed.
- Pricing Page Viewed: Triggered when a user views plan tiers or pricing tables.
- Key Feature Used: Triggered when a user performs a core value action inside the web app (e.g., exporting a report or inviting a team member).
Media, Publishing & Content Portals
- Article Search Performed: Triggered when a user searches for content topics.
- Newsletter Subscribed: Triggered when a visitor submits an email subscription form.
- Resource Downloaded: Triggered when a user clicks to open or download a guide, whitepaper, or PDF.
- Video Started: Triggered when a user initiates media playback.
- Paywall Encountered: Triggered when an unauthenticated or non-subscribed user reaches a restricted content barrier.
- Subscription Purchased: Triggered upon successful transaction for a paid content subscription.
Marketplaces & Service Booking
- Search Filter Applied: Triggered when a user refines results by category, price range, or location.
- Listing Saved: Triggered when a user bookmarks or favorites an item, property, or service provider.
- Booking Request Sent: Triggered when a user submits a reservation or service request form.
- Provider Contacted: Triggered when a user clicks to reveal contact details or send a direct message.
- Review Submitted: Triggered when a customer posts feedback or rates a past transaction.