We establish an effective version of the André–Oort conjecture for linear subspaces of |$Y(1)^n_{\mathbb{C}} \approx \mathbb{A}_{\mathbb{C}}^n$|. This gives the first effective nontrivial results of André–Oort type for higher-dimensional varieties in products of modular curves.