DoWhy

DoWhy

โ˜… 4 ๐Ÿ”– 2500 saves ๐Ÿ’ฐ Free GitHub

DoWhy is an open-source Python library for causal inference, maintained by the PyWhy community and published on GitHub with around 8,400 stars. Where most machine learning predicts correlations, DoWhy is built to answer “what if” questions: it makes causal assumptions explicit, then estimates and stress-tests the effect of an intervention.

Overview

DoWhy structures causal analysis into four disciplined steps. First you model the problem with a causal graph describing how variables influence each other. Then it identifies the causal effect from that graph, estimates the effect using a chosen statistical method, and finally refutes the estimate with robustness checks such as placebo treatments and subset validation. The library bundles many estimation methods โ€” propensity score matching and weighting, instrumental variables, regression-based estimators and more โ€” and it interoperates with EconML for advanced causal machine learning estimators. Originally created at Microsoft Research, DoWhy is now the core of the broader PyWhy ecosystem and is widely cited in both academic work and industry experimentation analysis. The codebase is actively maintained, with commits continuing into late 2026.

Key Features

  • Four-step causal workflow: model, identify, estimate, refute
  • Explicit causal graphs make assumptions transparent and auditable
  • Many built-in estimators: propensity scores, IV, regression and more
  • Refutation tests to validate the robustness of causal estimates
  • Interoperates with EconML for double ML and causal forests
  • Backed by an active open-source community and research literature

๐Ÿ’ณ Pricing

DoWhy is free and open source under the MIT license. Install it from PyPI or GitHub and use it without any fees, subscriptions, or hosted-service requirements.

Who Is It For

DoWhy is for data scientists, economists, and product analysts who need defensible causal answers โ€” measuring whether a feature, policy, price change, or treatment actually caused an outcome rather than merely correlating with it.

๐Ÿš€ Visit DoWhy Official Site

๐Ÿšฉ Report an issue