We examine the emergence and consequences of urban slums along a country‘s path to urbanization. Based on salient evidence from Brazilian labor, housing, and education markets, we study the interaction of slums with structural transformation and inequality. Urban slums are an intergenerational stepping-stone only for the lowest educated, explaining their emergence and persistence over time. In the past slums might have helped with Brazil‘s human capital formation but at least since 2010 slums are a hindrance. Countries that missed the opportunity to improve rural schools and avoid the formation of slums should target improving schools in the slums.