摘要:Aims. It is well known that the presence of baryons affects the dark matter host haloes. Exploring the galaxy assembly history together with the dark matter haloes properties through time can provide a way to measure these effects.Methods. We have studied the properties of four Milky Way mass dark matter haloes from the Aquarius project during their assembly history, betweenz = 0 − 4. In this work, we used a published SPH run and the dark matter only counterpart as case studies. To asses the robustness of our findings, we compared them with one of the haloes run using a moving-mesh technique and different sub-grid scheme.Results. Our results show that the cosmic evolution of the dark matter halo profiles depends on the assembly history of the baryons. We find that the dark matter profiles do not significantly change with time, hence they become stable, when the fraction of baryons accumulated in the central regions reaches 80 per cent of its present mass within the virial radius. Furthermore, the mass accretion history shows that the haloes that assembled earlier are those that contain a larger amount of baryonic mass aforetime, which in turn allows the dark matter halo profiles to reach a stable configuration earlier. For the SPH haloes, we find that the specific angular momentum of the dark matter particles within the five per cent of the virial radius atz = 0, remains approximately constant from the time at which 60 per cent of the stellar mass is gathered. We have explored different theoretical and empirical models for the contraction of the haloes through redshift. A model to better describe the contraction of the haloes through redshift evolution must depend on the stellar mass content in the inner regions.