HERSHEY, Pa. (AP) _ A man whose heart was expected to give out within hours became the first human recipient Friday of the Penn State artificial heart, which doctors hope will keep him alive until a human donor is found.

The heart, with a new design intended to reduce the danger of blood clots and intended only as a bridge to a human transplant, was implanted in Anthony Mandia of Philadelphia during a nearly five-hour operation at Hershey Medical Center, a spokesman said.

Mandia, 44, was sedated but conscious by Friday afternoon and apparently was not in pain, said Dr. John W. Burnside, Hershey's associate vice president for health affairs.

He said Mandia was in critical but stable condition and there was no sign of any bleeding, which along with clotting and infection are the three chief hazards the patient must face immediately after surgery.

Mandia, who was visited by his family Friday afternoon, was breathing with the aid of a respirator.

Asked about Mandia's prognosis, Burnside said: ''I'd say it's guarded ... This is still an experimental technique ... we are in unfamiliar territory.''

Dr. William S. Pierce, who developed the heart, headed a team of 20 people who started the implant at 6 a.m.

''It was quite clear early this morning that Mr. Mandia was dying,'' Burnside had said earlier. ''As of this point, we would state that it (the operation) is a success because Mr. Mandia is alive.''

Cardiologist Dwight Davis had concluded that Mandia would not have survived another day without a transplant, but no donor heart was available, said Burnside, who briefed reporters in nearby Harrisburg.

Mandia, who is single and employed by the Philadelphia Recreation Department, was transferred to the medical center Monday from Nazareth Hospital in Philadelphia. His father, mother, brother and sister-in-law were in Hershey.

Mandia is the second patient to undergo a federally approved temporary artificial heart implant. Temporary artificial hearts also have been used four times without authorization.

All permanent implants have used the Jarvik-7, developed by Dr. Robert Jarvik. The Hershey model differs in its seamless blood sacs, all plastic valves and an attached mechanism to regulate the heart rate automatically to compensate for changes in body position.

Four men in the United States and one in Sweden have received permanent artificial hearts. Two of the five have died.

The first recipient was Barney Clark, who received a Jarvik-7 at the University of Utah on Dec. 2, l982, and lived 112 days. The longest-lived recipient is William Schroeder, who received the Jarvik-7 on Nov. 25, 1984, in Louisville, Ky.

The surgeon for all the permanent U.S. implants was William C. DeVries, the only surgeon authorized to implant artificial hearts until March 14, when Pierce was given approval to implant the Pennsylvania State University model.

The first patient to receive an authorized heart as a temporary measure was Michael Drummond. He was kept alive for nine days on a Jarvik-7 before a human donor was found Sept. 7, and continues to recuperate at University Medical Center in Tucson, Ariz.

Burnside said doctors want to give Mandia's body time to recover from Friday's surgery before trying to implant a human heart, possibly in about a week.

If Mandia develops an infection, a transplant would be delayed and the artificial heart can remain in him indefinitely, Burnside said.

Mandia, who with his family agreed to the operation within the last day, was suffering from ''severe end-stage'' coronary disease and had had several heart attacks.

His heart continued to fail early Friday despite ''maximum medical therapy,'' Burnside said. He had been given drugs, and an intra-aortic balloon pump had been inserted into his body Wednesday, producing some short-lived improvement. Doctors decided at 4 a.m. to proceed.

Mandia and his family had no reservations and he ''understood the desperate condition that confronted him,'' Burnside said.

Burnside said the physicians charge no fee for the procedure but hospitalization cost $75,000 and the artificial heart cost $2,000.

The mood in the operating room Friday was confident, he said.

''It's one step in what has been a long 15-year walk,'' said Burnside, referring to the work by Pierce and Penn State engineers on the artificial heart. Burnside said reseach continues on improved models.