AN EPIC child-custody battle is dividing the Upper East Side. Only this tug of love, waged over ador able twin 6-year-olds, is being fought not by par ents but by two sisters — each with a crazy past.

On the one side of this sad and bizarre feud is the twins’ mom, Dr. Robin Recant, a physician with the city Health Department’s sexually transmitted disease bureau.

She’s a single mom and former mental patient who claims that her unmarried, childless sister is trying to steal her kids.

The sister she’s at war with is former Criminal Court Judge Donna Recant, a Giuliani appointee and Post cover girl who was censured by the state Commission on Judicial Conduct in 2001 for, among other things, chaining a defense lawyer to a bench for being “disrespectful” and handcuffing a defendant for blowing bubble gum.

Donna, who left the judgeship in disgrace in 2005, now has temporary custody of the twins, and she wants to keep them.

She insists this is the only way to protect the children from the unstable, paranoid woman who gave them life.

But Robin Recant swears that her sis has wanted to take her kids away from the day they were born.

As the case drags on through Family Court, one has to wonder, “Where is the father?”

There is none. Perhaps the saddest aspect of this twisted tale is that these kids were born through anonymous, in-vitro fertilization in 2002 to Robin, who is now 54. Donna is 53.

So who will raise little Eric and Rebecca?

It all started back in May when — according to Robin — her sister bullied and threatened her into signing over temporary guardianship of her children.

At first, I did not believe that an intelligent woman such as Robin would do such a thing without good reason. Now I’m less sure.

In June, Robin signed herself, voluntarily, into the Payne Whitney mental-health center at New York-Presbyterian Hospital. She claims that her sister threatened her, saying that if she didn’t go for an evaluation, she would try to take away the kids permanently.

Robin was held at the center for 101 days. She underwent nine electro-shock treatments. According to Robin, each time she tried to leave or refuse treatment, she was threatened with involuntary commitment by Payne Whitney doctors, who said she was paranoid.

Payne Whitney, which Robin is suing along with her sister, did not respond to several calls for comment.

Donna’s lawyer, Deborah Schwartz, said, “If Donna had not come to the fore and stepped up to the plate, these children would be in foster care. It’s like when you do a good deed. No good deed goes unpunished.”

But Robin’s high-powered lawyer, Robert Arenstein — who in the ’80s famously won Baby M’s custody for surrogate mom Mary Beth Whitehead — says it’s the case, not his client, that is nuts.

“Robin Recant is not insane,” he said. “She’s still running a job and capable of handling patients and working every day. This is not the mark of someone who’s mentally ill.”

He blamed the former judge, Donna, for unduly influencing the case, saying, “She’s been to the hospital. She’s been everywhere to take these kids away.”

Meanwhile, Robin “loves these children more than life itself,” he said. “These children want to be with their mother. They are not happy being with their aunt.”

Dr. Maureen Packard, a noted child neurologist who treats Eric for a seizure disorder, told me that Robin “is very annoyed and angry, but I don’t see her as depressed. I can understand her frustration with a system that doesn’t give her a chance.”

The doc said Robin’s sister “made a big deal because [Robin] missed a dose of Eric’s medicine,” and he had a seizure.

“You can miss one dose of medicine, and nothing happens,” Packard said. “He’s had some seizures with Donna, and she’s very religious about giving him his medicine.”

Packard said Robin “has a wonderful relationship with her son” and disputes Donna’s claim that Robin prefers her daughter.

Robin claims Donna’s influence is vast — stretching to the management of her East Side apartment building. Nuts, right?

But one night, while interviewing Robin at home when her kids were visiting, I got an angry call from Schwartz, Donna’s lawyer, on my cellphone. How did she know we were there?

And while writing this article, I also got two calls from influential people who pleaded the case for Donna.

I don’t have a dog in this race. But I fear for these children. They will suffer.