New York City public schools last week reopened for the year for the sixth time under Mayor Bill de Blasio, with the main cause for celebration being the schools the mayor would rather shut down.

We’re not talking about the selective middle and high schools that Team de Blasio targets as “racist,” but rather the charter schools that serve mostly black and Hispanic children.

On last year’s state exams for grades 3 through 8, only 47.4% of students at schools run by de Blasio’s Department of Education scored 3 or better on the English test and 45.6% in math.

The mayor actually boasted about those numbers, since the stats from the year before were even worse. (He ignored the fact that the state has been gradually dumbing down these exams.)

Other signs suggest that many DOE schools are getting worse. Notably, The Post recently published a poignant warning about the decline in public-school discipline from state Sen. Leroy Comrie (D-Queens). He described “teachers who were assaulted by students” and then had to face the same kids in places like the cafeteria. He’d heard from parents who complained that “nothing can be done to remove [a bullying student] from the classroom or separate that same student from the victim.”

Some parents feel “forced to seek safety transfers to send their kids to other schools,” Comrie wrote. “Those parents who have the wherewithal are pulling their kids out of the city’s public school system, choosing to enroll their kids in private schools.”

Not everyone has the wherewithal for private schools, of course. The best alternative for low-income parents now is a charter.

Charters are public schools but not managed by the DOE. And independent management produces much better results, even though charters get thousands of dollars less in per-pupil funding.

Though admissions are by random lottery, New York’s charter kids vastly outperform students attending the DOE’s schools in the same neighborhoods, year after year after year.

The charter sector now handles about a tenth of the city’s public-school population — yet, sadly, it’s not remotely large enough for the families who enter the admissions lottery. By the count of the New York City Charter School Center, 81,300 applicants applied for just 33,000 seats available in the city’s 259 public charter schools slated to operate in the 2019-20 school year.

Sadder still, the Legislature refuses to increase the cap on the number of charters in the city: Its Democratic majorities are afraid to cross the teachers unions, which see charters (which are mostly non-union) as an existential threat.

De Blasio also hates these public schools that work. “Get away from charter schools. No federal funding for charter schools,” he bellowed at this year’s National Education Association assembly.

Never mind that charters offer by far the best hope to what he used to call “the other New York.”

Look, notably, at the Success Academy network. Last year, as The Post reported in July, “all 467 eighth-grade students in the Success Academy network of charter schools took the [state Algebra exam] this academic year, and 99% passed with a minimum rank of 3, or a score of 65.” A full 56% achieved the top score of 5.

At Success Academy Bronx 2, every eighth-grader not only passed, but “aced it with rankings of 5 out of 5.” Bronx 2 sits in the nation’s poorest congressional district. Ninety percent of the students qualify for free lunch.

Yes, 82% eighth-graders from DOE schools passed the algebra exam with 3 or better — but only a third of all DOE eighth-graders even took the exam, because most of them hadn’t even taken algebra yet.

“It is better to light one candle than to curse the darkness,” President John Kennedy once said. In a tragically dysfunctional school system, charter schools are that candle — yet the mayor insists on cursing it.