Do charter schools hurt their neighboring schools? A new study of New York City schools says no — they help.

Far from hurting existing schools, new charter schools in New York City have actually helped their neighbors improve, according to a new study.

The study’s surprising conclusion adds some hard data to a divisive debate: Do the privately operated yet publicly funded institutions sap resources and hurt traditional public schools? Or do they exert competitive pressure that lifts all boats?

The answer, at least in New York City, is that traditional public schools should want to be as close as possible to multiple charter schools, and ideally share a building with one.

The study finds that being closer to a charter school led to small increases in math and reading scores, boosts in reported student engagement and school safety, and fewer students being held back a grade. The test score gains increased slightly more in traditional public schools that are co-located with a charter.

Sarah Cordes, a professor at Temple University and the study’s author, suspects that her findings are the result of the competition stoked by charters.

“I think having that close a proximity might really get administrators to get their act together,” she said. “Part of it is just that it’s really hard to ignore a charter school in your building.”

The peer-reviewed study, set to be published in the journal Education Finance and Policy, is based on student-level data from nearly 900,000 third- through fifth-graders between 1996 and 2010. Cordes’s method takes advantage of the timing of when new charter schools opened to isolate their effect on nearby district schools, using performance before and after the charter opens.

A school within a half-mile of a charter school, for instance, saw significant bumps in math and reading scores — estimates that are boosted with greater numbers of nearby charter schools, and schools from “high quality” charter networks such as Success Academy or KIPP.

Test score bumps at traditional public schools were even more pronounced in cases where they occupied the same buildings as charter schools — an arrangement that has drawn intense criticism from many educators and parents, and which often forces the schools to share resources like cafeteria and gym space.

Cordes’s results are consistent with previous research from other districts, which have typically pointed to either neutral or slightly positive test score effects of charter schools on their neighbors.

The critics get something from the study, too: evidence that existing schools do lose some students when charters open nearby. When a charter was between one-half to one mile from a district school, for instance, the district school tended to lose roughly 16 general education students. But Cordes concluded that the population changes weren’t big enough to influence test scores.

So why do the city’s charter schools boost their neighbors’ performance?

One reason, Cordes says, is that the charter sector is working as it was intended: creating pressure on administrators to improve the quality of their schools.

Based on survey data collected by the city, she found that parents reported significantly higher levels of student engagement, and those with children in co-located schools were less likely to describe their schools as unsafe. Teachers reported higher academic expectations and “more respect and cleanliness” after a nearby charter school opened.

Cordes also points to the budgetary effects of charter schools. Somewhat paradoxically, given charter critics’ arguments, competition from charter schools led to more average spending per student at traditional schools — between 2 percent for schools that are further away to 9 percent for co-located schools.

Though she did not look at whether decreases in enrollment had adverse effects on programming that wouldn’t be measured by reading and math test scores or survey data, Cordes said future research should look at whether enrollment drops lead to smaller class sizes, which have been shown to boost learning.