Using nationally representative data over three decades for India, we investigate mechanisms underlying parental motivation to invest differentially between their sons’ and daughters’ education. We identify three channels: strong son preference, meta son preference (resulting in “unwanted girls”), and the resource concentration motivation. We find that gender gaps in educational quantity outcomes have declined significantly for all children. However, gender gaps in the quality of education have increased over the period, and the increase is the largest in families with unwanted girls, i.e. due to an intensification of meta son preference, followed by families motivated by resource concentration.