From an evolutionary perspective, matriliny presents a puzzle because men in matrilineal societies transmit wealth to their sisters' sons, to whom they are only half as related as to their own sons. It has been argued that such systems would only maximise fitness under unrealistically high levels of paternity uncertainty. In this paper, we propose that matriliny can arise from daughter-biased investment by parents and/or grandparents. We show that daughter-biased investment is adaptive if the marginal benefit of wealth to sons (compared to daughters) does not outweigh the risk of nonpaternity in sons' offspring. We argue that such conditions will be rare where resource-holding polygyny is prevalent but could otherwise be widespread under even moderate levels of paternity uncertainty. The daughter-biased investment model explains two well-known characteristics of matrilineal descent: (a) matriliny's association with high levels of paternity uncertainty and (b) matriliny's ecological correlates, including its association with horticulture, its rarity in pastoralist and agro-pastoralist societies, and the tendency for matriliny to be replaced by son-biased inheritance during economic development. We present data on wealth, sex, and reproductive success (RS) in two African societies, the matrilineal Chewa in Malawi and patrilineal Gabbra in Kenya, which support the daughter-biased investment theory.