6 min read

How to Set Up Alerts for Churn Rate in Amplitude

If you're only checking user retention once a week, you're probably missing the churn spikes that happen between Mondays. Amplitude lets you set alerts on churn rate so you catch problems when they matter — before half your users are gone. Here's how to do it.

Step 1: Track User Activity Events

Before you can alert on churn, you need to measure it. Start by tracking the events that signal a user is still active.

Initialize the Amplitude SDK and track engagement events

Install the Amplitude JavaScript SDK and use amplitude.track() to log user actions. Track meaningful events like logins, feature usage, or purchases. Define what "active" looks like for your product — this becomes your churn inverse.

javascript
import * as amplitude from '@amplitude/analytics-browser';

amplitude.init('YOUR_API_KEY');

// Track active user behavior
amplitude.track('dashboard_opened', {
  feature: 'analytics',
  user_plan: 'pro'
});

// Identify user properties for segmentation
amplitude.identify(
  new amplitude.Identify()
    .set('subscription_tier', 'premium')
    .set('signup_date', '2026-01-15')
);

amplitude.flush();
Track consistent events that indicate active usage. Use identify() to add user traits for segmentation.

Define your churn threshold

Decide explicitly: no login in 30 days? No API calls in 14 days? No feature use in 7 days? Be specific and document it. Your entire team should use the same definition so alerts are meaningful.

Step 2: Build a Retention Cohort in Amplitude

With events flowing in, create a retention metric that shows which cohorts are dropping off and when.

Create a retention cohort in the dashboard

Go to Analysis > Retention, click Create new. Choose your returning user event (e.g., dashboard_opened) and your cohort definition event (e.g., signup). Select Week as your interval. Amplitude calculates retention percentage for each cohort, showing you exactly when churn accelerates.

javascript
// Query retention via Amplitude REST API
const params = new URLSearchParams();
params.append('start', '20260301');
params.append('end', '20260326');

fetch('https://api2.amplitude.com/cohort/retention?app_id=YOUR_APP_ID&' + params, {
  method: 'GET',
  headers: {
    'Authorization': 'Bearer YOUR_API_KEY'
  }
}).then(r => r.json()).then(data => {
  console.log('7-day retention:', data.retention[0] + '%');
  console.log('14-day retention:', data.retention[1] + '%');
});
Retention API returns cohort data. Lower retention % in later weeks = rising churn.

Segment by plan or geography (optional but useful)

Churn rates differ by customer segment. In your retention chart, add a breakdown by User Properties (plan, region, onboarding source). This reveals if certain cohorts are churning faster — often your highest-value users.

Step 3: Create and Configure Your Alert

Now set Amplitude to notify you automatically when retention drops below your threshold.

Add your retention chart to a dashboard

Create or open a Dashboard. Add a new chart and select Retention as the chart type. Configure it with your retention cohort definition. Your chart now shows week-by-week retention in one place.

Set a threshold alert on the chart

Click the three-dot menu on your retention chart and select Create alert. Choose Threshold-based alert, then set the condition (e.g., "Alert if retention falls below 75%"). Select notification channels: Email, Slack, or Webhook. Add recipient emails or Slack channels.

javascript
// Example webhook payload when your alert triggers
const payload = {
  alert_id: 'retention_threshold_001',
  alert_name: 'Weekly Cohort Retention',
  dashboard: 'Product Health',
  metric_value: 72.3,
  threshold: 75,
  condition: 'below',
  cohort: 'Week 0',
  timestamp: '2026-03-26T14:30:00Z'
};

// Your webhook endpoint can trigger automations
if (payload.metric_value < payload.threshold) {
  console.log(`ALERT: Retention dropped to ${payload.metric_value}%`);
  // Trigger: post to Slack, create Jira ticket, page oncall
}
Webhooks let you automate responses — escalate to Slack, create incident tickets, or notify your team.

Test and dial in your thresholds

Start loose (e.g., alert on 10% drops) to establish a baseline for your product. After 2–3 weeks, you'll see typical retention patterns. Then tighten thresholds to alert only on meaningful declines. Set frequency to daily or weekly to avoid alert fatigue.

Watch out: Amplitude's built-in alerts fire based on chart data refresh, not real-time events. For real-time churn detection, use webhooks to push retention data to your own monitoring system.

Common Pitfalls

  • Defining churn too loosely — "inactive user" means different things to different teams. Agree on one definition (e.g., "no login in 30 days") before configuring alerts or you'll get conflicting signals.
  • Ignoring cohort-specific churn — pro users and free users have completely different activity patterns. If you alert on overall retention, you'll miss churn spikes in your high-value segments.
  • Setting thresholds too tight — alert on every 1% drop and you'll get paged constantly for normal variation. Start at 10–15% drops and adjust down after you see your baseline.
  • Not backfilling historical events — churn alerts are only useful if your event tracking is consistent. If your SDK tracking breaks for a week, retention calculations become unreliable and alerts fire at false thresholds.

Wrapping Up

You're now catching churn when it happens, not a week later in a retro. Set your alert, pick your notification channel, and let Amplitude watch retention for you while you focus on product. If you want to track this automatically across tools and correlate churn with feature launches or pricing changes, Product Analyst can help.

Track these metrics automatically

Product Analyst connects to your stack and surfaces the insights that matter.

Try Product Analyst — Free