Tuning the work functions of materials is of practical interest for maximizing the performance of microelectronic and (photo)electrochemical devices, as the efficiency of these systems depends on the ability to control electronic levels at surfaces and across interfaces. Perovskites are promising compounds to achieve such control. In this work, we examine the work functions of more than 1,000 perovskite oxide surfaces (ABO$_3$) by data-driven (machine-learning) analysis and identify the factors that determine their magnitude. While the work functions of BO$_2$-terminated surfaces are sensitive to the energy of the hybridized oxygen p bands, the work functions of AO-terminated surfaces exhibit a much less trivial dependence with respect to the filling of the d bands of the B-site atom and of its electronic affinity. This study shows the utility of interpretable data-driven models in analyzing the work functions of cubic perovskites from a limited number of electronic-structure descriptors.