How the Churn Score is Calculated #
This page provides a technical explanation of the churn score algorithm for users who want to understand or validate the scoring.
Calculation Process #
The Churn_Predictor class runs each night as part of the daily metric cron.
For each customer:
Step 1: Gather raw data
– Count failed/cancelled orders in the last 90 days (from WooCommerce orders linked to the customer)
– Count events in the last 30 days and prior 30 days
– Calculate days since last event
– Count support-related events in the last 90 days
– Calculate activation trend (activations in last 30 days vs prior 30 days)
Step 2: Score each factor 0 to 100
– Payment failures: Each failure adds proportional points
– Declining usage: Percentage decline translates to score points
– Inactivity: Days idle mapped to 0-100 scale (50+ days = 100)
– Support tickets: Each ticket adds proportional points
– License utilization: Percentage decline in activations translates to score points
Step 3: Compute weighted total
Apply weights: 30% Payment + 25% Usage + 20% Inactivity + 15% Support + 10% Utilization
Step 4: Store
Scores for all customers are stored in a single WordPress option (dmsi_analytics_churn_scores). The last calculation timestamp is also stored.
Score Storage #
All customer churn scores are stored together in a serialized WordPress option. On sites with thousands of customers, this option can be large. See Performance Considerations for notes on this.
Retaining High-Risk Customers #
DMSI Analytics can send automated retention emails to high-risk customers (score above 70). Configure the retention email template and trigger in Analytics > Settings > Predictive.
