The injection and evolution of turbulence in the intergalactic medium is studied by means of mesh-based hydrodynamical simulations, including a subgrid-scale (SGS) model for small-scale unresolved turbulence. The simulations show that the production of turbulence has a different redshift dependence in the intracluster medium (ICM) and the warm-hot intergalactic medium (WHIM). We show that the turbulence in the ICM is produced chiefly by merger-induced shear flows, whereas the production in the WHIM is dominated by shock interactions. Secondly, the effect of dynamical pressure support on the gravitational contraction has been studied. This turbulent support is stronger in the WHIM gas at baryon overdensities 1 ≲δ≲ 100 and less relevant for the ICM. Although the relative mass fraction of the gas with large vorticity is considerable (52 per cent in the ICM), we find that for only about 10 per cent in mass this is dynamically relevant, namely not associated with an equally large thermal pressure support. According to this result, a significant non-thermal pressure support counteracting the gravitational contraction is a localized characteristic in the cosmic flow, rather than a widespread feature.