Datadog RUM lets you visualize user journeys through your app, not just as a series of page loads, but as discrete, meaningful steps in a conversion funnel.

Let’s say you’re tracking a checkout process. The traditional RUM view shows you users hitting /cart, then /checkout/shipping, then /checkout/payment, and finally /order/confirmation. But what if a user abandons their cart? Or gets stuck on the shipping page? RUM can tell you that, but a funnel view crystallizes it.

Here’s a simplified checkout funnel we’ll track:

  1. View Cart: User lands on /cart.
  2. Start Checkout: User clicks "Proceed to Checkout."
  3. Enter Shipping: User lands on /checkout/shipping.
  4. Enter Payment: User lands on /checkout/payment.
  5. Order Complete: User lands on /order/confirmation.

To track this, we define "View" events in Datadog. These are RUM events that correspond to a distinct user interaction or page load.

Here’s what the RUM configuration looks like for these views:

{
  "applicationId": "YOUR_APP_ID",
  "clientToken": "YOUR_CLIENT_TOKEN",
  "site": "datadoghq.com",
  "service": "my-frontend-app",
  "env": "production",
  "sessionReplaySampleRate": 100,
  "actionSampleRate": 100,
  "viewEventSampleRate": 100,
  "trackInteractions": true,
  "defaultPrivacyLevel": "mask-user-input",
  "allowedHosts": [
    "my-app.com",
    "api.my-app.com"
  ],
  "rumSessionStorageMutationKey": "my-app-rum-session",
  "config": {
    "url_target": "/cart",
    "view_name": "View Cart",
    "tracking_type": "routeChange"
  },
  "config": {
    "url_target": "/checkout/shipping",
    "view_name": "Enter Shipping",
    "tracking_type": "routeChange"
  },
  "config": {
    "url_target": "/checkout/payment",
    "view_name": "Enter Payment",
    "tracking_type": "routeChange"
  },
  "config": {
    "url_target": "/order/confirmation",
    "view_name": "Order Complete",
    "tracking_type": "routeChange"
  }
}

The url_target specifies the URL path that defines the view. view_name is what you’ll see in the Datadog UI. tracking_type: "routeChange" means RUM will automatically create a new view event whenever the URL in the browser changes.

Once this is set up and data starts flowing, you can navigate to the "RUM" section in Datadog, then "Funnels." Click "Create New Funnel."

You’ll then define the steps of your funnel by selecting the RUM Views you configured. For our checkout example, you’d add:

  1. View Cart (defined by /cart)
  2. Enter Shipping (defined by /checkout/shipping)
  3. Enter Payment (defined by /checkout/payment)
  4. Order Complete (defined by /order/confirmation)

Datadog automatically infers the "Start Checkout" step from users navigating from "View Cart" to "Enter Shipping" without a "Start Checkout" view explicitly defined. If you had a dedicated "Start Checkout" button click that triggered a route change to /checkout/shipping, you could define a custom Action and then use that Action as a funnel step.

The funnel visualization will then show you:

  • Total Users: The number of unique users who reached the first step.
  • Conversion Rate: The percentage of users who proceeded from one step to the next.
  • Drop-off: The number and percentage of users who did not proceed to the next step.

You can also drill down into the users who dropped off at each stage to see their session replays, helping you understand why they left.

The most surprising thing about RUM funnels is that they don’t require explicit tracking of "funnel start" events for every step. Datadog can infer transitions between defined RUM Views. If a user is on /cart and then navigates directly to /checkout/payment (skipping shipping), Datadator won’t show them as completing the "Enter Shipping" step in the context of this funnel, even though they technically visited that URL. The funnel is about the sequence of defined views.

This allows you to define a funnel that captures the ideal path, and Datadog will measure how many users actually follow it, highlighting where your application or user experience is failing.

The next step is to analyze your funnel performance across different user segments and device types to identify specific areas for optimization.

Want structured learning?

Take the full Datadog course →