Gov. Andrew Cuomo brought his budget battle to a Harlem church on Palm Sunday, highlighting the need to fix troubled NYCHA buildings and track state education funds.

Continuing his public campaign against the beleaguered agency, Cuomo told worshippers at Mount Neboh Baptist Church that failing public housing has created a “home-to-prison pipeline.”

“They talk about the school-to-prison pipeline, where people fail in school, can’t get a job and wind up in prison,” Cuomo said. “It starts before school. It starts in the neighborhood. It starts in the housing complex. And it starts many times in public housing.”

Cuomo has taken several highly-publicized tours of NYCHA buildings recently, where units are plagued with crumbling walls, mold and vermin. And he has directed his ire at Mayor Bill de Blasio and agency officials who fail to make changes.

Last week, Cuomo threatened to withhold his signature for the state budget unless substantial funding for NYCHA is in the mix.

“I am tired of politicians defending the bureaucracy of NYCHA rather than protecting the interests of the tenants,” Cuomo said Sunday, in an apparent swipe at de Blasio without naming him directly.

De Blasio and his administration have dismissed Cuomo’s criticism as political opportunism.

“We understand the governor’s obsession with the mayor has prevented him from learning how NYCHA funding works, but the truth is NYCHA is spending hundreds of millions of dollars each year to fill the hole left by state and federal underinvestment,” said de Blasio spokeswoman Jaclyn Rothenberg in a statement.

“Instead of lying about the facts to feed his political obsession, the governor should give NYCHA tenants the money he has promised and refuses to deliver.”

During the 35-minute speech before a receptive crowd, Cuomo evoked the soaring Tale of Two Cities speech made by his late father, Mario Cuomo, at the 1984 Democratic National Convention, as he spotlighted the inequities between the city’s rich and poor. He also shared painful stories of his father’s depression as his health failed in the final months of his life.

Cuomo is facing a primary challenge from education activist and “Sex in the City” actress Cynthia Nixon, who has questioned his credentials as a progressive lawmaker, saying he is too cozy with state Republicans and big donors.

Her campaign launch last week also echoed the Tale of Two Cities theme as she talked about inequality across the state between rich and poor residents.

Cuomo has addressed the Mount Neboh congregation several times in recent years. In 2016, he announced an education plan for prisoners during a visit to the church.

On Sunday, Cuomo reiterated the need for better accounting of how education dollars are spent, noting that the poorest neighborhoods lag behind in resources. And he blasted the city on its slow timeline to shutter Rikers Island.

“I’m going to go argue for this budget,” Cuomo said. “They don’t want to disrupt NYCHA and they don’t want to disrupt the Rikers bureaucracy and they don’t want to disrupt the education bureaucracy. The people need to stand up and speak.”