Score contribution per author:
α: calibrated so average coauthorship-adjusted count equals average raw count
Using data on primary school children and their teachers, we show that teachers who hold prejudicial attitudes towards an ethnic group create socially and spatially segregated classrooms. Leveraging a natural experiment where newly arrived refugee children are randomly assigned to teachers within schools, we find that teachers' ethnic prejudice, measured by an implicit association test, significantly lowers the prevalence of interethnic social links, increases homophilic ties among host children, and puts refugee children at a higher risk of peer violence. Our results highlight the role of teachers in achieving integrated schools in a world of increasing ethnic diversity.