1. Home
  2. Work
  3. 02

Project 02 · cosmetics shop clickstream, 5 monthly CSVs

Funnel & Retention

The funnel leaks before the cart, not after it: 77.0% of sessions that view a product never add one, while cart-to-purchase is a comparatively gentle 15.8%. $23.99M of $29.86M in cart value never converts.

Data
Five monthly event files, October 2019 to February 2020, from a public Kaggle dataset
Scale
20,692,840 events, 4,535,941 sessions, about 2.3 GB
Reproducibility
22 of 22 figures reproduced exactly on the 2026-09-07 fresh pull, including the cohort retention table.
01

The question

Where do sessions actually drop out between viewing, carting and buying, and once someone buys, do they buy again?

02

The data and its scale

20,692,840 events from 2019-10-01 to 2020-02-29 with no date gaps, loaded into DuckDB in a single glob read of the five files.

03

What the source did

  1. ·category_code is null on 98.3% of events, so category-level analysis was ruled out before it was attempted. brand is 42.3% null, user_session 0.02% null, and user_id complete.
  2. ·The source does not document its currency. Values are reported in dollars as the likely convention, and stated as an assumption rather than a fact.
04

Method

A session-level funnel across 4,535,941 sessions: did the session view, add to cart, purchase. Then, before building cohorts, a viability check: 16.0% of 110,518 purchasers bought in more than one calendar month, enough repeat behaviour to make retention worth measuring. Purchasers were grouped by first-purchase month and tracked forward. Cart value was summed per session and split by whether the session ever purchased.

05

Finding

Where sessions leave the funnel

Where sessions leave the funnelHorizontal bar chart of 4,535,941 sessions. 94.4% include a view, 4,280,701 sessions; 21.7% add to cart, 985,780; 3.4% purchase, 155,617. 77.0% of viewing sessions never add to cart, while 15.8% of carting sessions buy.0255075100All sessions: 100.0% of sessions, 4,535,941All sessions100.0% 4,535,941Viewed: 94.4% of sessions, 4,280,701Viewed94.4% 4,280,701Added to cart: 21.7% of sessions, 985,780Added to cart21.7% 985,780Purchased: 3.4% of sessions, 155,617Purchased3.4% 155,61777.0% of viewing sessions never cart15.8% of carting sessions buy
Where sessions leave the funnelHorizontal bar chart of 4,535,941 sessions. 94.4% include a view, 4,280,701 sessions; 21.7% add to cart, 985,780; 3.4% purchase, 155,617. 77.0% of viewing sessions never add to cart, while 15.8% of carting sessions buy.0255075100All sessions: 100.0% of sessions, 4,535,941All sessions100.0% 4,535,941Viewed: 94.4% of sessions, 4,280,701Viewed94.4% 4,280,701Added to cart: 21.7% of sessions, 985,780Added to cart21.7% 985,780Purchased: 3.4% of sessions, 155,617Purchased3.4% 155,61777.0% of viewing sessions never cart15.8% of carting sessions buy
Share of 4,535,941 sessions reaching each stage, with session counts.02 · cosmetics shop clickstream
Data behind this chart
Session funnel, 02
StageShare of sessionsSessions
All sessions100.0%4,535,941
Viewed94.4%4,280,701
Added to cart21.7%985,780
Purchased3.4%155,617
  1. Almost every session views something.94.4% of sessions include a view, 21.7% add to cart and 3.4% purchase.
  2. The leak is view to cart.77.0% of the sessions that view a product never add anything to a cart.
  3. Cart to purchase is the gentle step.15.8% of carting sessions go on to buy, about one in six.
  4. Most cart value never converts.$23,993,092 of $29,863,849, 80.3%, belongs to sessions that never bought.

Cart abandonment is where e-commerce write-ups usually look, and for this shop the larger opportunity sits earlier, between seeing a product and wanting it. I reported it that way deliberately.

Month-1 retention is 18.5% for the October cohort, then 9.8% for November, 8.5% for December and 8.9% for January: one sharp step down after October and a flat floor below 10% after it. October also shows a small uptick at month 3 that no other cohort shows. I do not have a clean explanation, and I say so rather than smooth it over.

06

What this cannot tell you

  • Why the October cohort behaves differently.
  • Anything at category level, with 98.3% of category codes null.
  • Whether the currency is dollars.
  • Any business outcome. This is a public dataset and no change was made to any funnel.
07

Artifacts

  • A notebook with every query, and a findings memo
  • Two charts, the funnel and the cohort retention curves
The notebook’s funnel chart: horizontal bars for all sessions, viewed, added to cart and purchased, at 100.0%, 94.4%, 21.7% and 3.4% of 4,535,941 sessions.
The notebook’s funnel chart. funnel_dropoff.png · original in the repository
Repeat-purchase retention by monthly cohort, October 2019 to January 2020: every cohort falls from 100% to below 20% at month 1; October sits highest at 18.5% and the later cohorts between 8.5% and 9.8%.
Retention by first-purchase cohort. retention_by_cohort.png · original in the repository
08

Reproducibility

The CI fetches the five monthly files when they are absent and checks them against their committed sizes, then runs the notebook on a clean checkout. On 2026-09-07 all 22 quoted figures came back exactly.

CI status for this project
Figures in the manifest22
Reproduced exactly, 2026-09-0722
Notebook25 cells, 15.5 s
09

Sources

  1. Cosmetics shop clickstream, a public Kaggle dataset: five monthly CSVs, October 2019 to February 2020, fetched by the CI at their committed sizes.
  2. The findings memo in 02-funnel-retention/memo.