← View All Guides
Mixpanel logo
Integration Guide

How to Analyze Referral Funnels in Mixpanel with GrowSurf

Build referral program funnels in Mixpanel to identify drop-off points and optimize conversion rates.

A referral program is only as strong as its weakest conversion point. Mixpanel's funnel analysis reveals exactly where participants drop off β€” is it after receiving their referral link? After sharing but before friends sign up? Or after friends sign up but before they convert? With GrowSurf referral events flowing into Mixpanel, you can build detailed funnels that pinpoint optimization opportunities.

This guide covers sending GrowSurf referral events to Mixpanel, building referral-specific funnels, analyzing conversion rates at each step, segmenting funnel performance by user properties, and using Mixpanel's insights to improve your referral program's conversion rate.

Integration Steps

Step 1: Send GrowSurf Events to Mixpanel

Set up the integration that sends referral events from GrowSurf to Mixpanel's ingestion API.

  • Use Mixpanel's Track API: POST https://api.mixpanel.com/track
  • Events to track:
    • Referral Program Joined
    • Referral Link Shared (if trackable via client-side SDK)
    • Referral Friend Signed Up
    • Referral Converted
    • Referral Reward Earned
  • Include properties: distinct_id (user email or ID), referral_code, referrer_id, campaign_name
  • Set user profiles with referral properties for segmentation

Step 2: Build the Core Referral Funnel

Create a funnel in Mixpanel that shows the complete referral journey.

  • Go to Funnels in Mixpanel
  • Add funnel steps:
    • Step 1: Referral Program Joined
    • Step 2: Referral Link Shared
    • Step 3: Referral Friend Signed Up
    • Step 4: Referral Converted
  • Set the conversion window (e.g., 30 days)
  • View the overall conversion rate and drop-off at each step

Step 3: Segment the Funnel by User Properties

Break down funnel performance by user segments to find patterns.

  • Segment by acquisition source: do referred participants convert better than organic?
  • Segment by plan type: do premium users refer more successfully than free users?
  • Segment by sign-up date: is funnel performance improving or declining over time?
  • Segment by share method: does email sharing convert better than social?

Step 4: Analyze Drop-Off Points

Identify the biggest drop-offs in your referral funnel and hypothesize solutions.

  • High drop-off at "Link Shared": participants aren't sharing β€” improve onboarding, make sharing easier
  • High drop-off at "Friend Signed Up": shares aren't converting β€” improve landing page, strengthen offer
  • High drop-off at "Converted": referred sign-ups aren't buying β€” improve onboarding for referred users
  • Compare drop-off rates month-over-month to track improvement

Step 5: Set Up Funnel Alerts

Configure Mixpanel alerts when funnel metrics change significantly.

  • Set alerts for: overall funnel conversion rate drops below a threshold
  • Alert when any step's conversion rate changes by more than 10% week-over-week
  • Monitor funnel volume: alert if daily referral event volume drops significantly

Step 6: Build a Referral Program Dashboard

Combine funnel analysis with other referral metrics in a Mixpanel dashboard.

  • Create a dashboard with:
    • Referral funnel conversion chart
    • Daily referral events trend line
    • Top referrers by conversion count
    • Referral source breakdown (share method distribution)
    • Average time between funnel steps
  • Share the dashboard with your growth team for regular review

Code Snippets

// Send GrowSurf referral events to Mixpanel
const Mixpanel = require('mixpanel');
const mixpanel = Mixpanel.init(process.env.MIXPANEL_TOKEN);

app.post('/api/growsurf-to-mixpanel', async (req, res) => {
  const { event, participant, referrer } = req.body;

  const eventMap = {
    'PARTICIPANT_CREATED': 'Referral Program Joined',
    'PARTICIPANT_REFERRED': 'Referral Friend Signed Up',
    'CAMPAIGN_REFERRAL_CONVERTED': 'Referral Converted',
    'PARTICIPANT_REACHED_REWARD': 'Referral Reward Earned'
  };

  const mixpanelEvent = eventMap[event];
  if (!mixpanelEvent) return res.json({ skipped: true });

  // Track event for the participant
  mixpanel.track(mixpanelEvent, {
    distinct_id: participant.email,
    referral_code: participant.referralCode,
    referrer_email: referrer?.email || null,
    referrer_id: referrer?.id || null,
    campaign_id: participant.campaignId,
    referral_count: participant.referralCount || 0,
    is_referred: !!referrer
  });

  // Set user profile properties
  mixpanel.people.set(participant.email, {
    $email: participant.email,
    $first_name: participant.firstName,
    $last_name: participant.lastName,
    referral_code: participant.referralCode,
    total_referrals: participant.referralCount || 0,
    referral_participant: true,
    referred_by: referrer?.email || 'organic'
  });

  // If this is a referral, also track for the referrer
  if (event === 'PARTICIPANT_REFERRED' && referrer) {
    mixpanel.track('Referral Made', {
      distinct_id: referrer.email,
      referred_email: participant.email,
      referral_number: referrer.referralCount
    });

    mixpanel.people.set(referrer.email, {
      total_referrals: referrer.referralCount
    });
  }

  res.json({ success: true });
});

Tips

Use Time-to-Convert Analysis for Optimization

Mixpanel's funnel analysis shows the median time between each step. If the gap between "Link Shared" and "Friend Signed Up" is 3+ days, your referral landing page may not be compelling enough. If it's under 1 hour, your sharing experience is working well β€” focus optimization efforts on other steps.

Compare Referral Funnels Across Campaigns

If you run multiple GrowSurf campaigns, create separate funnels for each by filtering on the campaign_id property. This reveals which campaign designs, rewards, and audiences produce the best conversion rates, helping you double down on what works.

Export Funnel Data for Advanced Analysis

Mixpanel lets you export funnel data via API. Export weekly funnel data to a spreadsheet for deeper analysis, including statistical significance testing on conversion rate changes. This helps you make data-driven decisions about program changes.

FAQ

How many events do I need before Mixpanel funnels become reliable?

For statistically meaningful funnel analysis, you need at least 100 entries at the first funnel step. With fewer events, conversion rate variations could be due to chance. For segmented funnel analysis, each segment needs 30+ entries at minimum. If your program is smaller, use longer time windows (90 days instead of 30).

Can I create funnels that span both referrer and referred user actions?

Mixpanel funnels track a single user through multiple steps. To analyze the referrer-to-friend journey, you'd need to track events on both users and join them. Instead, create two separate funnels: one for the referrer journey (join β†’ share β†’ friend signs up) and one for the referred friend (click link β†’ sign up β†’ purchase).

How do I track referral link sharing if it happens outside my website?

Client-side tracking captures sharing actions within your app (clicking the share button, copying the link). For shares that happen via email, text, or social media, track the sharing intent (button click) rather than the actual share. Use GrowSurf's link click tracking as a proxy for how many people received and clicked shared links.

Set up your refer a friend program with customer referral and affiliate program software that lowers your acquisition costs, increases customer loyalty, and saves you gobs of time.

Trusted by marketing and product teams at fast-growing B2C, fintech, and SaaS companies