We investigate the physics driving the cosmic star formation (SF) history using the more than 50 large, cosmological, hydrodynamical simulations that together comprise the OverWhelmingly Large Simulations project. We systematically vary the parameters of the model to determine which physical processes are dominant and which aspects of the model are robust. Generically, we find that SF is limited by the build-up of dark matter haloes at high redshift, reaches a broad maximum at intermediate redshift and then decreases as it is quenched by lower cooling rates in hotter and lower density gas, gas exhaustion and self-regulated feedback from stars and black holes. The higher redshift SF is therefore mostly determined by the cosmological parameters and to a lesser extent by photoheating from reionization. The location and height of the peak in the SF history, and the steepness of the decline towards the present, depend on the physics and implementation of stellar and black hole feedback. Mass loss from intermediate-mass stars and metal-line cooling both boost the SF rate at late times. Galaxies form stars in a self-regulated fashion at a rate controlled by the balance between, on the one hand, feedback from massive stars and black holes and, on the other hand, gas cooling and accretion. Paradoxically, the SF rate is highly insensitive to the assumed SF law. This can be understood in terms of self-regulation: if the SF efficiency is changed, then galaxies adjust their gas fractions so as to achieve the same rate of production of massive stars. Self-regulated feedback from accreting black holes is required to match the steep decline in the observed SF rate below redshift 2, although more extreme feedback from SF, for example in the form of a top-heavy initial stellar mass function at high gas pressures, can help.