Based on the discovery of the duality between Jackiw–Teitelboim quantum gravity and a double-scaled matrix ensemble by Saad, Shenker and Stanford in 2019, we show how consistency between the two theories in the universal random matrix theory (RMT) limit imposes a set of constraints on the volumes of moduli spaces of Riemannian manifolds. These volumes are given in terms of polynomial functions, the Weil–Petersson (WP) volumes, solving a celebrated nonlinear recursion formula that is notoriously difficult to analyse. Since our results imply linear relations between the coefficients of the WP volumes, they therefore provide both a stringent test for their symbolic calculation and a possible way of simplifying their construction. In this way, we propose a long-term program to improve the understanding of mathematically hard aspects concerning moduli spaces of hyperbolic manifolds by using universal RMT results as input.