BOSTON (AP) _ Three days before Christmas, doctors told Lynn and Jack Bellingham their 3 1/2 -month-old son Ricky had just days to live. The couple spent the holiday making funeral arrangements.

The infant is still alive - connected to an artificial respirator, fed through a tube in his stomach and sedated with morphine. But the Bellinghams are preparing to go to court to persuade Children's Hospital to remove the child's intravenous tubes and let him ''die in peace, not pain.''

In the past three months, Ricky has undergone three major operations and 10 other surgical procedures, all requiring anesthesia, at a cost of $1 million, his parents said. Doctors told the Bellinghams their son would need at least two more operations in the near future and that his prognosis was uncertain.

''Enough is enough,'' said Mrs. Bellingham, 26. ''My question to the hospital is, 'What do they consider life?' The baby has a right to be at peace like any other human being.''

Ricky has been in the hospital's intensive care unit since he was born Sept. 24, five weeks premature. He has a deformed esophagus and trachea, liver infection, internal bleeding, an enlarged gall bladder and a hernia.

''Because of the infections, he has a decreased brain capacity,'' said Mrs. Bellingham, ''but we don't know how much.''

Last week, the Bellinghams asked the hospital not to perform any further operations and to disconnect the feeding tubes. Mrs. Bellingham said the hospital told her it was considering a court petition to gain custody of the boy to continue medical treatment.

''We said, 'No surgery,' and the hospital told us to get a lawyer,'' she added. ''We will fight it. It's a matter of principle. We had a right to bring a child into the world, and no one should have the right to tell us what's best.''

The Bellinghams said they are poised to file suit against the hospital as soon as it orders more surgery.

Hospital officials refuse to discuss the Bellingham case, citing the infant's right to privacy, but spokeswoman Nancy Collins said Tuesday that, in general, doctors make every effort to preserve life, even when hope is sparse.

''We do not make decisions to preserve or terminate life based on social, economic or lifestyle reasons,'' Ms. Collins said. ''It is hard to know when to stop treating a patient because some cases, especially in pediatrics, things change for the better.''

Ms. Collins said the hospital usually tries to follow the wishes of parents whose children are terminally ill, but if doctors believe a child can be saved, the hospital will seek custody or emergency permission to continue treatment.

Mrs. Bellingham, who has two children from a previous marriage, lives in the suburb of Marshfield with her husband, a 40-year-old construction worker. She said the couple had no idea Ricky was going to be born with physical problems.

''In the beginning, we went along with everything the hospital wanted to do,'' she said. ''We wanted this baby. It is my husband's first son.''

She said the couple decided that the baby should be allowed to die when ''we saw there was no hope for recovery.''

''He has a lot of problems, and we're talking about major problems. Even if he survives, there is no chance he would be normal. The baby should be allowed to die in peace, not pain.

''The bills are just sitting here in a pile. At this point insurance has run out. But this isn't a matter of money.''

Legal and ethics experts interviewed Tuesday said such cases are becoming more common as medical technology makes it possible to prolong the lives of sick infants.

''The real question is, what is customary and reasonable medical care and then, what's in this child's best interest from the child's perspective?'' said George J. Annas, a professor of health law at Boston University. ''The question is, is this child better off dead than being treated this way?

''These are difficult questions. You can't say it's black or white.''