Custom events let you track interactions that don’t fit the 13 standard event types. Wishlist adds, quiz completions, loyalty point redemptions, product configurator steps — any meaningful customer action can be captured as a custom event and forwarded through the Upstack pipeline.Documentation Index
Fetch the complete documentation index at: https://docs.upstackdata.com/llms.txt
Use this file to discover all available pages before exploring further.
Naming Conventions
Custom event names follow these rules:- Use PascalCase:
WishlistAdd,QuizComplete,LoyaltyRedeem - Keep names descriptive and specific:
ProductConfigSavedis better thanCustomAction1 - Avoid names that collide with standard events —
PageView,Purchase, etc. are reserved - Maximum length: 64 characters
- Allowed characters: letters, numbers, underscores
Property Structure
Custom events use the same envelope as standard events. You control thecustom_data payload — Upstack attaches user_data and context fields automatically.
custom_data. For best compatibility with destinations, reuse the standard property names (content_ids, value, currency, content_name) wherever they apply.
How Custom Events Flow Through the Pipeline
Custom events follow the exact same path as standard events:- Capture — The Upstack Pixel sends the event to the edge API. You can fire custom events using the JavaScript tracking API on your storefront.
- Resolve — Upstack ID attaches identity data to the event. Session stitching and cross-device linking work the same as for standard events.
- Enrich — UTM parameters, click IDs, and product catalog data are merged if applicable
content_idsare present. - Activate — The event is forwarded to destinations that accept custom events.
Destination Support
Not all destinations handle custom events the same way:| Destination | Custom Event Support |
|---|---|
| Meta CAPI | Supported as Custom event type. Meta receives the custom event name and all properties. Useful for building custom audiences and optimization. |
| TikTok Events API | Supported. Custom events can be used for audience building but not standard optimization. |
| Klaviyo | Fully supported. Custom events appear as distinct metric types in Klaviyo for flow triggers and segmentation. |
| GA4 | Supported. Custom event names map directly to GA4 custom events. Properties become event parameters. |
| Webhook | Fully supported. The raw event payload is forwarded as-is. |
Meta and TikTok ad optimization algorithms work best with standard events. Use custom events for audience building and measurement, but rely on standard events (Purchase, AddToCart, etc.) for campaign optimization signals.
Firing Custom Events
To fire a custom event from your storefront, use the Upstack JavaScript API:user_data) are attached automatically — you only need to provide the event name and custom_data properties.
Upstack-native custom purchase events
In addition to user-defined custom events, Upstack fires two built-in custom events that segment every order by customer status. They are sent alongside — not instead of — the standardPurchase event.
nc_purchase
nc_purchase
Fires when an order is placed by a customer with no prior completed Shopify order history. Used to optimize Meta campaigns toward new-customer acquisition instead of repeat buyers.When it fires: Order confirmation, when the customer has zero prior completed orders in Shopify.Properties: Same payload as the standard
Purchase event (value, currency, content_ids, order_id, etc.) plus Upstack’s identity enrichment (em, ph, fn, ln, fbc, fbp, client_ip_address, client_user_agent).See Set up custom events → NC Purchase for Meta setup steps.rc_purchase
rc_purchase
Fires when an order is placed by a customer with one or more prior completed Shopify orders. Used for retargeting audiences, retention measurement, and keeping prospecting campaigns honest about who they’re actually converting.When it fires: Order confirmation, when the customer has at least one prior completed order in Shopify.Properties: Same payload as the standard See Set up custom events → RC Purchase for Meta setup steps.
Purchase event (value, currency, content_ids, order_id, etc.) plus Upstack’s identity enrichment (em, ph, fn, ln, fbc, fbp, client_ip_address, client_user_agent).Example payload:The standard
Purchase event still fires for every order regardless of customer status. nc_purchase and rc_purchase fire in addition to Purchase, not instead of it.Standard Events
Review the full list of built-in events before creating a custom event.
Properties & Context
See all available property fields you can include in custom_data.