About half a dozen of the 40 remaining American passengers and crew from hijacked TWA Flight 847 are believed to be in the custody of the militant Hezbollah, or Party of God, according to a well-informed source here and a key U.S. official in Washington.

According to the Beirut source, the original hijacking was carried out by members of Hezbollah, and the mainstream Shiite Amal militia took over the operation early Saturday after one of the original hijackers shot and killed an American passenger. In return, Hezbollah took five or six hostages with Jewish sounding names off the plane, the source added. They are believed to be safe, but still in the custody of Hezbollah. The remaining passengers were taken off the plane Sunday.

In Washington, President Reagan's national security adviser, Robert McFarlane, also said that the group is under the control of Hezbollah. Asked whether the United States knows where the hostages are, McFarlane said: "We are assured that they are under the control of Amal militia leader Nabih Berri. Others are being held by more extreme elements -- half a dozen or so. The crew of the plane is, we believe, on the plane."

Asked if this was the group with Jewish sounding names that is reported to have been removed from the plane Saturday, McFarlane answered: "That's correct."

When asked to identify further the "more extreme elements," he responded: "Hezbollah."

Hezbollah followers are concentrated in the neighborhood of Bir al Abed, a suburb south of Beirut. U.S. intelligence officials believe Hezbollah, a militant Shiite group said to have close ties to Iran and Syria, was behind the suicide car bombings of the U.S. and French embassies in 1983.

Berri, whose Amal militia has emerged as the main Shiite power in Lebanon in recent months, has given assurances that all the hostages are well and that he is supervising their food and daily comfort. But he has been vague when asked publicly about a small group of passengers with Jewish-sounding names who reportedly were taken off the plane Saturday. There have been suggestions that he might not be in control of all the passengers. It is also not clear if Amal militiamen are with the smaller group, along with the Hezbollah gunmen.

At a press conference Monday, Berri said in response to questions that he was not sure whether the hijackers were from Hezbollah, but added that "they are in the same way," meaning Shiite extremists. Berri, who said he supports the hijackers' demands that Shiite prisoners be released by Israel and Spain, has stressed that the hijackers were not members of Amal.

Reports that the crew of the TWA flight was still aboard the aircraft and the original hijackers now off the plane were confirmed today in a dramatic television interview in which the captain of the hijacked plane warned that "we would all be dead" if a rescue mission were attempted to try to free the American passengers and crew still in Beirut.

With an armed gunman sitting at his side at the cockpit window of the Boeing 727, Capt. John Testrake told reporters on the tarmac below that life for himself and fellow crewmen had settled into a period of waiting since the remaining passengers on the plane had been removed Sunday night.

The interview with ABC television and the French news agency Agence France-Presse provided the first evidence that the crew remained aboard the aircraft. There had been some reports that they had been removed along with the other passengers.

Testrake and his fellow crew members -- First Officer Philip Maresca and Flight Engineer Benjamin Christian Zimmerman -- looked worn after their six-day ordeal and clearly happy to see the journalists approach their plane, according to reporters who conducted the interview.

"The first thing I saw was that smiling face. He was really happy to see us," said ABC's Charles Glass, who conducted the interview with Testrake and his crew. The three men, especially Testrake, appeared calm and collected as each spoke with the armed gunman by his side. They were still wearing their uniforms.

Testrake told ABC he did not know what had happened to the passengers on the aircraft except, "We've been told they've been taken to a safe place, that they're comfortable and being well taken care of."

As the reporters and cameramen approached the aircraft, a bearded young gunman in a grey shirt stuck a large black automatic pistol out of the cockpit window and waved it at the journalists standing on the ground. Testrake then appeared beside the gunman. The engine of the plane was shut off as the interview began under the sunny, clear skies of a Mediterranean summer morning.

"Not very much is happening to us now, since Sunday night, because they removed the other passengers and took them away and the three of us have been on the aircraft since then . . . . It's just a case of wait and see what happens. So we've just been doing housekeeping here in the aircraft," he said.

When asked whether he was well treated, he simply replied: yes, nodding and smiling.

In response to a question on whether they ate what they wanted, Testrake said, laughing: "Well, they sometimes bring us airline food, and they sometimes bring us Lebanese food and it's different to us but it's very delicious. I'd say on the whole the food is okay."

The other TWA officers said their treatment was fair and tolerable.

The hijackers have been asking for newspapers, and copies of the local English language daily, The Daily Star, and the French L'Orient le Jour are sent to the plane along with Arabic publications, every morning.

TWA First Officer Philip Maresca said some of the militiamen on the plane were from the mainstream Shiite Amal movement, but not all. He told his interviewers that the original hijackers were no longer on board.

There are fears in Beirut that the hostage crisis could drag on for days if not weeks unless negotiations for the release of about 700 Shiite prisoners held by Israel make some headway. The gunmen aboard the plane reportedly are getting impatient and although several threats to blow up or crash the aircraft have not been carried out, it is difficult to tell what their moodiness will lead them to do.