We study how cities’ amenities and restrictions on the housing supply contribute to aggregate wage inequality and affect housing prices through the sorting of heterogeneously skilled workers. We develop a general equilibrium model where workers differ along a continuum of skills and compete for limited housing. Our analysis suggests that spatial sorting accounts for 7.5% of the aggregate wage dispersion, increases average housing prices by 20–40% in constrained cities, and makes the economy 1.9% more productive. In addition, we evaluate a place-based policy that aims to expand the supply of houses in 1% in constrained cities and find that it improves aggregate productivity between 0.2% and 0.4%. However, the place-based policy has an unintended consequence of aggravating aggregate wage inequality by the same magnitude.