Direct numerical simulations of Taylor–Couette flow, i.e. the flow between two coaxial and independently rotating cylinders, were performed. Shear Reynolds numbers of up to
, corresponding to Taylor numbers of
, were reached. Effective scaling laws for the torque are presented. The transition to the ultimate regime, in which asymptotic scaling laws (with logarithmic corrections) for the torque are expected to hold up to arbitrarily high driving, is analysed for different radius ratios, different aspect ratios and different rotation ratios. It is shown that the transition is approximately independent of the aspect and rotation ratios, but depends significantly on the radius ratio. We furthermore calculate the local angular velocity profiles and visualize different flow regimes that depend both on the shearing of the flow, and the Coriolis force originating from the outer cylinder rotation. Two main regimes are distinguished, based on the magnitude of the Coriolis force, namely the co-rotating and weakly counter-rotating regime dominated by Rayleigh-unstable regions, and the strongly counter-rotating regime where a mixture of Rayleigh-stable and Rayleigh-unstable regions exist. Furthermore, an analogy between radius ratio and outer-cylinder rotation is revealed, namely that smaller gaps behave like a wider gap with co-rotating cylinders, and that wider gaps behave like smaller gaps with weakly counter-rotating cylinders. Finally, the effect of the aspect ratio on the effective torque versus Taylor number scaling is analysed and it is shown that different branches of the torque-versus-Taylor relationships associated to different aspect ratios are found to cross within 15 % of the Reynolds number associated to the transition to the ultimate regime. The paper culminates in phase diagram in the inner versus outer Reynolds number parameter space and in the Taylor versus inverse Rossby number parameter space, which can be seen as the extension of the Andereck et al. (J. Fluid Mech., vol. 164, 1986, pp. 155–183) phase diagram towards the ultimate regime.