Skip to content
Blog

User Flows

Flows let you tag a sequence of pageviews and custom events as a named journey. Once tagged, the dashboard shows a Sankey diagram of how users move through the flow, a table of the most common paths, and a funnel analysis tool for measuring conversion between steps.

Wrap the events you care about with startFlow() and endFlow():

tribe.startFlow("checkout");
// These events are now tagged as part of the "checkout" flow
tribe.track("cart_viewed", { items: 3 });
// ...user navigates to /checkout, pageview is auto-tracked
tribe.track("payment_submitted", { method: "wallet" });
tribe.endFlow();

Every pageview and custom event between startFlow() and endFlow() gets associated with that flow name. The flow name stays active across page navigations until you explicitly end it.

  1. Tag eventsstartFlow("name") sets a flow context. All subsequent events include the flow name until endFlow() clears it.
  2. Daily aggregation — A background job groups events by session and counts transitions between consecutive steps (e.g., /products/checkoutpayment_submitted).
  3. Query in dashboard — The Flows tab on the Analytics page shows the aggregated data as a Sankey diagram, top paths table, and funnel analysis.
tribe.startFlow("onboarding");
tribe.track("signup_completed");
// user lands on /welcome, then /setup
tribe.track("profile_completed", { hasAvatar: true });
tribe.track("first_project_created");
tribe.endFlow();
tribe.startFlow("checkout");
tribe.track("cart_viewed", { itemCount: 2, total: 59.99 });
tribe.track("shipping_selected", { method: "express" });
tribe.track("payment_submitted", { method: "card" });
tribe.track("order_confirmed", { orderId: "ORD-123" });
tribe.endFlow();
tribe.startFlow("export-wizard");
tribe.track("export_started", { format: "csv" });
tribe.track("columns_selected", { count: 8 });
tribe.track("export_completed", { rows: 1250 });
tribe.endFlow();

The Sankey view shows every transition between events in the flow. Thicker bands mean more sessions took that path. Use the filters to adjust:

  • Max steps — how deep to trace the flow (default 5)
  • Min sessions — hide low-traffic transitions
  • Starting event — focus on paths beginning from a specific page or event

A table of the most common event sequences, ranked by session count. Each row shows the full path and average duration from first to last step.

Define a funnel by selecting 2–6 events in order. Tribe calculates:

  • Conversion rate — percentage of sessions that completed all steps
  • Dropoff rate — percentage lost at each step
  • Strict vs. loose — strict mode requires events in exact order; loose mode just checks that each event occurred
<script>
Tribe.startFlow("signup");
// ... user actions ...
Tribe.endFlow();
</script>
  • Flow names should be short, descriptive, and lowercase: checkout, onboarding, export-wizard
  • Unnamed events still appear in the Sankey diagram — flows without a name show all session transitions
  • You can have only one flow active at a time. Calling startFlow() while a flow is already active replaces the current flow name
  • Events are sent via sendBeacon, so endFlow() doesn’t flush anything — it just clears the flow tag for future events
MethodDescription
startFlow(name)Start tagging events with a flow name
endFlow()Stop tagging events with the current flow name