A 605-foot coal vessel, carrying 36 crew members, capsized before dawn yesterday in heavy seas and gale-force winds off the Virginia coast. Only three men were believed to have survived.

The Marine Electric, a collier carrying 12,000 tons of coal and registered to an American firm, foundered in 12- to 15-foot waves about 30 miles east of Chincoteague, Va., and 35 miles southeast of Ocean City, Md., according to a Coast Guard spokesman. The capsized vessel remained afloat for more than seven hours before sinking at about 12:30 p.m. in 120 feet of water.

"It's sort of a nightmare," Lt. J.G. Chris Canty, a member of the Coast Guard rescue crew, told United Press International. "There's a lot of bodies in the water," he said. "There's a lot of debris. The ship's screws are the only thing visible, and maybe three, four feet of the aft part is showing . . .

"They must have gone down pretty quick. That's all I can say. It was pretty cold and the winds were 25 knots."

The three survivors were pulled from the frigid waters shortly after 5 a.m. in a dramatic rescue by Navy and Coast Guard helicopter crews, the spokesmen said. Two of the survivors were spotted adrift in a life raft and the third was found floating in the water.

In the predawn darkness, a Coast Guard helicopter crew tried to pull the three men from the ocean by lowering a steel basket to them, said Coast Guard spokesman Bruce Pimental. But the men, weakened by exposure to the 37-degree water, were unable to grasp the basket.

Then a Navy helicopter lowered a rescue worker, clad in a survival suit, into the ocean. The Navy crewman, identified as Petty Officer 2.C. James D. McCann, swam to the stricken sailors and helped them into the Coast Guard rescue basket. The basket was lowered three times to pick up each of the survivors, who were flown to Peninsula General Hospital Medical Center in Salisbury, Md., for treatment of hypothermia.

"Swells were breaking over my head. It was cold out there," McCann, 27, of Emporia, Va., said in a telephone interview last night. "There were just a lot of bodies floating around. . . . I put them in the basket as fast as I could." McCann said he spent more than an hour in the water, helping to rescue survivors and recover victims' bodies. "I picked up a lot of people," he said.

By midafternoon, the Coast Guard reported that 24 bodies had been pulled from the water and nine other crew members were missing. A search was continuing last night though officials held out little hope of finding any of the missing crewmen alive. In 37-degree water, the Coast Guard spokesman said, a person normally can survive for no longer than 2 1/2 hours.

A Peninsula General spokesman identified the three survivors as Robert M. Cusick, 59, of Scituate, Mass., who was listed in serious condition and being treated in the hospital's intensive care section; Eugene S. Kelly, 31, of Norwell, Mass., and Paul C. Dewey, 28, of Granby, Conn., both in fair condition.

The cause of the Marine Electric's capsizing and sinking was not known yesterday, officials said. Both the Coast Guard and the National Transportation Safety Board announced plans to investigate the incident.

"We will be looking at why people who got off the boat didn't survive," said safety board spokesman Ira Furman.

The board recently recommended that oil-drilling rigs be equipped with special thermal suits to help assure workers' survival, Furman noted, after a probe into the capsizing a year ago of a rig in which 84 persons died.

The Marine Electric sent out a radio distress signal at 3:13 a.m., saying that waves were breaking over her bow, and the vessel radioed again about 4 o'clock to say that the crew was abandoning the ship, according to Coast Guard spokesmen. A gale warning was in effect and visibility was reported low, spokesmen said.

Five crewmen were pronounced dead at Peninsula General and the bodies of other victims were temporarily being held aboard rescue vessels. The identities of the dead and missing were withheld, pending notification of next of kin.

The Marine Electric is owned by Marine Coal Transport Corp. of New York and has a Wilmington, Del., home port.

Pimental said the Marine Electric took part in a rescue Friday when it came to the aid of a stricken fishing vessel which was taking on water off Chincoteague. The Marine Electric stood by the vessel for eight hours until a Coast Guard rescue vessel arrived.