  We propose a new strategy to identify the impact of class rank, exploiting a
"visible" primary school rank from teachers' exam grades, and an "invisible"
rank from unreported standardized test scores. Leveraging a unique panel
dataset on Italian students, we show that the visible rank has a substantial
impact on students' perceptions, which affects subsequent academic performance.
However, the effect of being surrounded by higher-SES or higher-achieving peers
remains positive even accounting for the decrease in rank. Higher-ranked
students self-select into high schools with higher average student
achievements. Finally, exploiting an extensive survey, we identify
psychological mechanisms channeling the rank effect.
