At local, galaxy properties are well known to be clearly different in different environments. However, it is still an open question how this environment-dependent trend has been shaped. We present the results of our investigation about the evolution of star-formation properties of galaxies over a wide redshift range, from z ~ 2 to z ~ 0.5, focusing its dependence on their stellar mass and environment (Lee et al. 2015). In the UKIDSS/UDS region, covering ~2800 square arcmin, we estimated photometric redshifts and stellar population properties, such as stellar masses and star-formation rates, using the deep optical and near-infrared data available in this field. Then, we identified galaxy cluster candidates within the given redshift range. Through the analysis and comparison of star-formation (SF) properties of galaxies in clusters and in field, we found interesting results regarding the evolution of SF properties of galaxies: (1) regardless of redshifts, stellar mass is a key parameter controlling quenching of star formation in galaxies; (2) At z < 1, environmental effects become important at quenching star formation regardless of stellar mass of galaxies; and (3) However, the result of the environmental quenching is prominent only for low mass galaxies (M* < 1010 M⊙) since the star formation in most of high mass galaxies are already quenched at z > 1.