Customer churn prediction using Azure Machine Learning

NOTE This content is no longer maintained. Visit the Azure Machine Learning Notebook project for sample Jupyter notebooks for ML and deep learning with Azure Machine Learning.

Link to the Microsoft DOCS site

The detailed documentation for this churn prediction example includes the step-by-step walk-through:

Link to the Gallery GitHub repository

The public GitHub repository for this churn prediction example contains all the code samples:


On average, keeping existing customers is five times cheaper than the cost of recruiting new ones. As a result, marketing executives often find themselves trying to estimate the likelihood of customer churn and finding the necessary actions to minimize the churn rate.

The aim of this solution is to demonstrate predictive churn analytics using AMLWorkbench. This solution provides an easy to use template to develop churn predictive data pipelines for retailers. The template can be used with different datasets and different definitions of churn. The aim of the hands on labs is to:

  1. Understand how Azure Machine Learning’s Data Preparation tools can be used to clean and ingest customer relationship data for churn analytics.
  2. Perform feature transformation to handle noisy heterogeneous data.
  3. Integrate third-party libraries (such as scikit-learn and azureml) to develop bayesian and tree based classifiers for predicting churn.
  4. Perform operationalization.

Key components needed to run this example

  1. An Azure account (free trials are available).
  2. An installed copy of Azure Machine Learning Workbench with a workspace created.
  3. This example could be run on any compute context.

Data / Telemetry

Churn Prediction collects usage data and sends it to Microsoft to help improve our products and services. Read our privacy statement to learn more.


This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit

When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (for example, label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information, see the Code of Conduct FAQ or contact with any additional questions or comments.