Alearning-disabledthird-grader who was cruellybulliedby classmates at highly rated PS 6 on the Upper East Side was deprived of her educational rights — and the city must pay for her tuition at a private school, a top appellate court has ruled.

The landmark decision by theUS Court of Appeals for the Second Circuitfound that Principal Lauren Fontana “stonewalled” the girl’s parents, refusing to discuss the bullying or address it in her special-education plan.

The three-member appellate panel unanimously upheld a ruling by federal Judge Jack Weinstein that the city Department of Education violated the US Individuals with Disabilities Education Act.

New research suggests that as students become more popular and climb the social hierarchy of middle and high school, they are at increased risk for gossip, harassment and even physical attacks from rivals competing for status.

And the adverse consequences of that bullying — including increased depression, anxiety and anger, and decreased school attachment — are magnified the more popular the victim, according to the paper published in April’s American Sociological Review.