Exploiting exogenous variation in drought conditions across districts in Tanzania, this paper investigates the effects of climate change on children's education according to the number of siblings and their gender composition. The study highlights how liquidity-constrained households respond to income shocks when formal insurance schemes are not available. They select the children on which they invest according to their perceived educational returns. Whereas boys are not affected, the impact of drought on girls' likelihood of school dropout depends on their younger siblings' gender composition. Younger sisters offset the negative shock on girls, as they offer less competition for limited educational resources, due to higher uncertainty about their probability of educational success. Conversely, older sisters disfavor later-born daughters and reduce their likelihood of being in school during time of hardship. I find that drought decreases the educational attainment of girls with only older sisters by more than 1.3 years, compared to girls with only older brothers. Finally, I demonstrate that underpriviledged daughters help the family overcome climate shocks by increasing their work in agriculture and, for some of them, by leaving the household with their early-marriage.