Lime-activated fly ash cementitious materials are widely used as masonry cement and autoclaved building materials. This study investigated the effects of MgO on the microstructure and properties of the fly ash/cement-based pastes under hydrothermal conditions. The activator (i.e., CaO + MgO) was fixed at 17 wt%, and CaO was replaced with MgO at 0-30 wt%. The properties assessed were compressive strength, linear expansion, fluidity, porosity and pore size distribution. The microstructure was investigated by means of XRD, TG-DSC and SEM. Experimental results show that the compressive strength depended on the autoclave temperature, time and MgO content. Overall, as the MgO/(MgO + CaO) ratio was less than about 20, 15 and 12% at 140, 180 and 210 degrees C, respectively, MgO contributed to improve the compressive strength. In addition, appropriately extending the autoclave time or raising the autoclave temperature was in favor of strength development. The lower MgO content had a little influence on the expansion, but once the MgO/(MgO + CaO) ratio exceeded 20%, the expansion remarkably increased. Microstructural analyses demonstrated that MgO promoted the formation and crystallization of tobermorite likely through a solid phase or liquid-solid reaction mechanism. Besides, the micromorphology of tobermorite tended to be slender in the presence of MgO.