A federal judge here yesterday refused to block the Carter administration from returning the 1,000-year-old crown of St. Stephen to Hungary.

U.S. District Court Judge June 1, Green's ruling came after a two-hour hearing in which opponents of the move said the sacred relic would be treated as a "vulgar bauble" and put on display in Hungary, and that the Communist country could not be trusted on its promised to keep the crown there.

The importance of the issue of both sides was illustrated by the fact that U.S. Attorney Earl J. Silbert personally argued the case for the Carter administration, and by the large gathering in the courtroom of people apparently opposed to the move.

One spectator who attempted to speak to the judge during the hearing was forcibly removed from the courtroom by a deputy U.S. marshal against whom he directed a racial insult.

The suit attempting to block the transfer of the crown to Hungary was brought on behalf of several members of Congress, who said the United States had acquired a property right in the crown since it had been in U.S. custody for the last 30 years.

Therefore, the suit said, President Carter could not dispose of the property without congressional approval.

"We say that is beyond the power of the executive branch," said Thomas Lumbard, the attorney for the plaintiffs. "With 200,000 Russian troops in Hungary, how do we know it won't be taken to Moscow? That's the type of question the Congress wants to ask the President."

Lumbard added "the question of whether the word of the Hungarian government [to display the crown publicly] is worth the paper it's printed on is for the Congress, not the President, to decide."

Silbert argued, however, that the courts had no right to intervene in the dispute because the decision to return the crown was made by the President under his authority to conduct the country's foreign affairs.

He said the crown had never been considered the property of the United States, but has merely been here for safekeeping after it was taken out of Hungary secretly and turned over to U.S. soldiers at the end of World War II.

"The crown belongs to the Hungarian nation." Silbert said, and its return has "great diplomatic significance" because it represents an improved relationship between the United States and Hungary.

Silbert said the plaintiffs in the suit "don't have a legal claim - they have a policy disagreement with the President of the United States. They are trying to accomplish by means of this suit something they can't accomplish through their colleagues in Congress."

Green issued a brief ruling after the hearing saying that she had doubts about the right of the plaintiffs to file the suit and that the "return of the regalia" to Hungary is probably a foreign policy decision that can't be challenged legally. She also said she doubted that a ruling blocking its return would be "in the public interest."

Lumbard said the ruling would be appealed.

The crown is a major symbol of Hungarian independence, and was reputedly given to Hungary's first king. Stephen, in the year 1000 for his coronation by Pope Sylvester II. It and the country's orb, scepter, sword and coronation robe are scheduled to be returned to Budapest on Jan. 6 and 7.