The green substance resembles mold, but it is not and poses no health risks.

Pizza's been sliced from city school lunches after a bad batch turned up in some cafeterias, Education Department officials said Friday.

The pie-ndemonium started when Schwan’s, the Minn.-based supplier, delivered green pizza to some schools Sept. 9.

The green pizzas contained no mold and posed no health risks to students — but the Department of Education temporarily yanked it from school menus anyway.

But Schwan’s is recalling a shipment of the pizza sent to city schools and will reimburse the city for the cost of the bad food, a company spokesman said.

According to a source with knowledge of the situation, the green pizza slices turned up Friday, Sept. 9, at the Urban Academy Laboratory High School in Manhattan, prompting the pizza ban.

The incident was first reported on the City Limits website Sept. 15.

But the source said some of the shipment of bad pizza had previously appeared in school cafeterias in May. “I wouldn’t want to serve it to my kids,” said the source. “They should’ve destroyed the whole batch.”

The pizza was contaminated with a green muck that resembled mold, the source said.

Education Department spokeswoman Toya Holness said the city is addressing the issue as quickly as possible.

“Out of an abundance of caution, we temporarily suspended the distribution of sliced pizza,” Holness said. “The discoloration was not mold and only affected a limited number of items.”

Schwan’s spokesman Chuck Blomberg said the company received a small number of reports of discolored pizza headed for city schools.

“We have worked with the school district to withdraw our sliced-pizza products from the market, and we will reimburse the school district for those items,” Blomberg said.

City records show Schwan’s holds a $36.1 million contract to provide food to city schools. The contract began in February 2014 is set to expire in December 2018.