How do we implement an e-commerce tracking plan? Documentation
When tracking your data, it’s important to set yourself up for success. E-commerce and retail companies want to use their data to understand why some customers fall out of their funnels or why customers become repeat buyers. They want to understand the key lifecycle events that lead up to the sale of a physical good, so they can, for example, test whether personalized shopping experiences yield higher conversions or build a multi-channel cart abandonment campaign. But first, they need to make sure those lifecycle events are being captured in their datasets.
That’s where a tracking plan comes in. A tracking plan is a living document that can be used across your organization to record what events and properties to track, where you’ll be tracking them in your code base, and why you’re tracking them.
In this guide, we’ll share with you the core events most relevant to e-commerce companies that can get you started immediately in understanding your customers and driving sales.
Talk to a product specialist today about building a clean, high-quality data spec so you can focus on brand engagement and sales growth.
Identifying your customers
Before diving into specific event tracking, you’ll want to make sure you track who your users are with the the .identify()
call. You should call .identify()
.identify()
call creates or updates a record of your customer with a set of traits in your tools and warehouse. But how do you choose which traits about your user to include?Traits are pieces of data that you track about a specific user. Read our guide about selecting traits to learn more.
Here are the most common user traits e-commerce companies include in their tracking:
first name
last name
email
Here are a few examples of other helpful user traits:
locale
currency
phone
lifetime_value
order_count
Here is a sample .identify()
call for Segment:
In analytics.js:
analytics.identify({
first_name: 'Andy',
last_name: 'Jiang',
email: '[email protected]'
});
In analytics-ios:
[[SEGAnalytics sharedAnalytics] identify:nil
traits:@{ @"email": @"[email protected]",
@"first_name": @"Andy",
@"last_name": @"Jiang",
@"experiment_viewed": @"Coupon" }];
In analytics-android:
Analytics.with(context).identify(new Traits().putValue("first_name", "andy").putValue("last_name", "jiang").putValue("experiment_viewed", "Coupon").putValue("email", "[email protected]"), null);
The main benefits of using the traits listed above are:
You can use the traits to personalize content in your email or push notification tools by inserting their information. For example:
You can create cohorts based on the traits in any of your tools. For example, you could use
order_count
to determine how many of your users are first or repeat, orexperiments
to determine how many have seen this particular experiment variant
Given the power you have in your downstream tools to create cohorts based on these dimensions, you may be tempted to throw more contextual data into the traits
, such as UTM params, IP addresses, and userAgents. But if you’re using Segment’s client-side analytics.js library, then all of these contextual pieces of data are automatically collected.
Selecting key e-commerce and marketing events
Now that you are tracking who your users are, you can work on what they’re doing on your website or in your app with a .track()
call. Tracking customer events lets you learn about your customers, measure the impact of your marketing efforts and product decisions, and proactively engage your customers in a meaningful way that drives sales.
E-commerce businesses, unlike SaaS or consumer apps that optimize for product engagement, focus on directing users down their funnels to a conversion goal, like purchasing a product. To best understand why customers convert, it’s important to track and measure all key funnel events.
Product Viewed
Product Added
Checkout Started
Order Completed
There are also auxiliary actions to track to measure your customer’s engagement with your site. These actions are good to track so you can better understand their intent on your website.
Products Searched
Product List Viewed
Product List Filtered
Lastly, we have a set of semantic campaign events that are automatically collected so you can understand the conversions within these particular channels:
Email Opened
Email Link Clicked
Push Notification Received
Push Notification Tapped
Deep Link Clicked
Deep Link Opened
You may notice a pattern in the event names. We’ve selected the “Object Action” naming convention to ensure that all of our event data is clean and easily analyzable, while choosing “snake_case” for the traits and properties. It doesn’t matter what you choose, so long as it’s consistent. Without a uniform and enforced naming framework to guide developers that add tracking code later, your data could get marred with conflicting naming structures. Learn more about the importance of naming conventions.
We recommend tracking core checkout activity on the server-side. Learn more about tracking on the client vs. server.
Selecting your properties
Properties are similar to traits, but they’re associated with specific actions, rather than with an individual user. Each .track()
call can accept an optional dictionary of properties
, which can contain any key-value pair you want. These properties
act as dimensions that allow your end tool to group, filter, and analyze the events. They give you additional detail on broader events.
For e-commerce, since most events are customers choosing, browsing, and checking out products, all of the traits must contain key information about the products themselves:
product_id
sku
price
quantity
currency
These traits must be included because many tools rely on them for analysis. If there was one of them missing, the call would be ignored.
Using a specific tool and want to see how Segment handles sending calls to it? Check out the documentation.
Here is an example .track()
call:
In analytics-node:
analytics.track({
userId: '019mr8mf4r',
event: 'Order Completed',
properties: {
order_id: '50314b8e9bcf000000000000',
total: 20,
currency: 'USD',
products: [
{
product_id: '507f1f77bcf86cd799439011',
sku: '201',
name: 'Folsom',
price: 10,
quantity: 1
},
{
product_id: '505bd76785ebb509fc183733',
sku: '204',
name: 'Brennan',
price: 10,
quantity: 1
}
]
}
});
In analytics-ios
[[SEGAnalytics sharedAnalytics] track:@"Order Completed"
properties:@{ @"order_id": @"50314b8e9bcf000000000000",
@"total": @"20",
@"currency": @"USD",
@"products": @"Coupon" }];
In analytics-android:
Analytics.with(context).track("Order Completed", new Properties().putValue("order_id", "50314b8e9bcf000000000000").putValue("total", 20).putValue("currency", "USD").putValue("products", "Coupon"));
It’s important that these events contain particular properties, such as sku
, otherwise the downstream tools won’t be able to create out-of-the-box revenue and sales reports. Learn more about semantic properties in our e-commerce spec.
Using data to understand why your customers don’t convert
The most successful e-commerce businesses not only efficiently move their customers through the funnel towards conversion, but also have the infrastructure to collect and leverage customer data. Having a tracking plan focused on key funnel events can help e-commerce businesses get a sense of the health of their funnel.
Aside from funnel health, having these key pieces of customer data gives companies the ability to tailor and personalize each interaction, as well as build marketing campaigns around actions taken or omitted.
Without taking this critical step of mapping out key customer events, businesses often spend too much time revisiting their data model or analyzing impartial data sets. Instead they could spend that time understanding and addressing customers’ needs.
Talk to a product specialist today about building a clean, high-quality data spec so you can focus on brand engagement and sales growth.
If you have any questions, or see anywhere we can improve our documentation, please let us know!
相關推薦
How do we implement an e-commerce tracking plan? Documentation
When tracking your data, it’s important to set yourself up for success. E-commerce and retail companies want to use their data to understand why some custo
How do I resize an image using PIL and maintain its aspect ratio?
我有一個資料夾,裡的圖檔是 96×96, 我希望在這一個資料夾下的檔案被異動時,會自動產生縮圖(64×64)到其他的資料夾下。 PIL 是 Python 下最有名的影像處理套件。 這個套件,似乎在升級改版本,把一些比較少人用的屬性或方法在新版本裡拿掉,新版本也加入了更多新的功能。一般人應該都只會使用基本
[java] How do I send an HTML email?
As per the Javadoc, the MimeMessage#setText() sets a default mime type of text/plain, while you need text/html. Rather use MimeMessage#setContent() instea
Ask HN: How do we save the planet?
So, lately I find that I can't really sleep when I read news about how the planet will probably be unlivable within 100 years (https://www.businessinsider.
Ask HN: How do we discourage extreme aptitude tests in the hiring process?
Throughout my entire development career I've dealt with increasingly extreme aptitude tests that other industries simply don't have. For a recent senior ro
How do you design an effective growth team?
2. Building relationships with other teamsAs a growth designer, working well with other disciplines on your team is important, but it’s not enough. A uniqu
Ask Ethan: If Light Contracts And Expands With Space, How Do We Detect Gravitational Waves?
For the past three years, humanity has known a new kind of astronomy from the traditional ones. No longer are we merely detecting light with a telescope, o
How do I decide between Redshift, Postgres, and BigQuery? Documentation
Comparing Redshift and PostgresIn most cases, you will get a much better price-to-performance ratio with Redshift for typical analyses.Redshift lacks some
Think in ISP(image sensor pipe )之How to implement an effecitive AE
方法 建立 avi pan .net article dir help blog How to implement a effecitive AE. AE(自己主動曝光) 1)try Minual exposure //time,
Ask HN: How do I go about selling an unsolicited service to a business?
I am a solo developer with limited professional resume/experience. I have developed a service specifically for a business for which I am a regular customer
How to setup ACRA, an Android Application Crash Tracking system, on your own host
One truth about developing a mobile application is there are so many constraints for example, a hardware limitation (CPU, RAM, Battery, e
How we built an app that manages reviews for popular consumer brands
How we built an app that manages reviews for popular consumer brandsHello, I am Adrian, one of the founders at FeedCheck, an app that manages reviews for p
Ask HN: How do you rationalize working at an ad
I work at a large ad-tech/tracking company that's ruining the internet (not FAANG, but in the next tier). Me personally - this is my first job post-undergr
How Did We Build Book Recommender Systems in An Hour Part 2
Rating infoUser infoBook infoTo ensure statistical significance, we will be only looking at the popular booksIn order to find out which books are popular,
How Did We Build Book Recommender Systems in an Hour Part 1
Virtually everyone has had an online experience where a website makes personalized recommendations in hopes of future sales or ongoing traffic. Amazon tell
Ask HN: How do i prevent Facebook and Instagram from tracking me across devices?
Phone #1: Installed Facebook app on iOS, added PhoneNumberX to 2FA.Phone #2: PhoneNumberX was never used on this phone apart from WhatsApp that had PhoneNu
Human Factors: How We Designed an Adaptive Culture for Our AI Company
When we began as a startup, we didn’t think like a big corporation; that’s the advantage of a small company. But we inherited lots of external pressure and
論文閱讀:《AliMe Assist: An Intelligent Assistant for Creating an Innovative E-commerce Experience》
阿里小蜜:提供創新電子商務體驗的智慧助理論文導讀摘要: 在本文中,阿里團隊介紹了會話機器人平臺“阿里小蜜”。該智慧助理設計提供一種創新性的電子商務體驗,並已經在真實的商業場景中上線。當前,阿里小蜜為客戶提供幫助服務、客戶服務和聊天服務,日處理上百萬的客戶問題。論文標題: AliMe Assist: An In
How do I check if a type is a subtype OR the type of an object?
option parent ive nbsp operate asp tel get another How do I check if a type is a subtype OR the type of an object? To check if a type
How do I find what queries were executing in a SQL memory dump?-----stack
been sea under lba bject ecif tool data- mil https://blogs.msdn.microsoft.com/askjay/2010/10/03/how-do-i-find-what-queries-were-execu