Context : Aims : We study the coevolution between the black hole accretion rate ( BHAR ) and the star formation rate ( SFR ) in different phases of galaxy life : main-sequence star-forming galaxies , quiescent galaxies , and starburst galaxies at different cosmic epochs . Methods : We exploited the unique combination of depth and area in the COSMOS field and took advantage of the X-ray data from the Chandra COSMOS-Legacy survey and the extensive multiwavelength ancillary data presented in the COSMOS2015 catalog , including in particular the UVista Ultra-deep observations . These large datasets allowed us to perform an X-ray stacking analysis and combine it with detected sources in a broad redshift interval ( 0.1 < z < 3.5 ) with unprecedented statistics for normal star-forming , quiescent , and starburst galaxies . The X-ray luminosity was used to predict the black holeAR , and a similar stacking analysis on far-infrared Herschel maps was used to measure the corresponding obscured SFR for statistical samples of sources in different redshifts and stellar mass bins . Results : We focus on the evolution of the average SFR-stellar mass ( M _ { * } ) relation and compare it with the BHAR-M _ { * } relation . This extends previous works that pointed toward the existence of almost linear correlations in both cases . We find that the ratio between BHAR and SFR does not evolve with redshift , although it depends on stellar mass . For the star-forming populations , this dependence on M _ { * } has a logarithmic slope of \sim 0.6 and for the starburst sample , the slope is \sim 0.4 . These slopes are both at odds with quiescent sources , where the dependence remains constant ( \log ( BHAR / { SFR } ) \sim - 3.4 ) . By studying the specific BHAR and specific SFR , we find signs of downsizing for M _ { * } and black hole mass ( M _ { BH } ) in galaxies in all evolutionary phases . The increase in black hole mass-doubling timescale was particularly fast for quiescents , whose super-massive black holes grew at very early times , while accretion in star-forming and starburst galaxies continued until more recent times . Conclusions : Our results support the idea that the same physical processes feed and sustain star formation and black hole accretion in star-forming galaxies while the starburst phase plays a lesser role in driving the growth of the supermassive black holes , especially at high redshift . Our integrated estimates of the M _ { * } -M _ { BH } relation at all redshifts are consistent with independent determinations of the local M _ { * } -M _ { BH } relation for samples of active galactic nuclei . This adds key evidence that the evolution in the BHAR/SFR is weak and its normalization is relatively lower than that of local dynamical M _ { * } -M _ { BH } relations .