Charitable giving from rural–urban migrants to their hometowns would help reverse ‘rural decline’ in China. Drawing on data from the 2018 China Labor‐force Dynamics Survey, this study discusses the relationship between migrants' structural embeddedness with their hometowns and their giving to public causes there. As the findings show, the deeper embedded the migrants, the more likely they were to donate. Social status compensation and moral constraint, as identified in previous studies, were confirmed in this research as the key drivers of migrant giving. Interestingly, this study found that the lower the degree of hometown embeddedness, the stronger the social status compensation effect, whereas the effect of moral constraint was powerful merely for those highly embedded with hometowns. These findings were also applicable to migrants with diverse types of embeddedness overall. This study contributes to the field of population research by adopting the structural perspective of spatial relationships regarding migrants' behaviours based on the theory of field and embeddedness. It has important implications for rural revitalisation in China as well as for philanthropy study worldwide.