We study whether the combined significant reduction in the pupil-teacher ratio and increase in parental education observed in Italy between the end of the II World War and the end of the 1980s have had a significant impact on the educational attainment and the labor market returns of a representative sample of Italians born between 1941 and 1970. We find that the lower pupil-teacher ratio is positively correlated with higher educational attainment, but that the overall improvement of parental education has had an even stronger impact on attainment. We also find that the positive impact of better school quality on educational attainment and returns to education has been particularly significant for the individuals born in regions and cohorts with poorer family background. Parental education has had asymmetric effects, positive on attainment and negative on school returns. Better school quality has also had asymmetric effects on the returns to education, positive for individuals with poor family background and negative for individuals born in regions and cohorts with relatively high parental education. Our evidence suggests that better school quality, measured by a lower pupil-teacher ratio, is a technical substitute to parental education in the production of individual human capital. When school quality and family background are substitutes, an increase of public resources invested in education can be used to reduce the differences induced by parental education.