School quality and grade completion by students are shown to be directly linked, leading to very different perspectives on educational policy in developing countries. Unique panel data on primary school age children in Egypt permit estimation of behavioral models of school leaving. The evidence suggests that students perceive differences in school quality, measured as expected achievement improvements in a given school, and act on it. Specifically, holding constant the student's own ability and achievement, a student is much less likely to remain in school if attending a low quality school rather than a high quality school. This individually rationale behavior suggests that common arguments about a trade-off between quality and access to schools may misstate the real issue and lead to public investment in too little quality. Further, because of this behavioral linkage, there is an achievement bias such that common estimates of rates of return to years of school will be overstated. The paper demonstrates the analytical importance of employing output-based measures of school quality.