Poland's independent union organizers decided today to form a national federation movement as one vast union, a decision that could put the new organization in a confrontation with the government.

The strength of the new independent trade union movement was demonstrated dramatically here today when representative of hundreds of new local unions thronged to Gdansk, the center of the strikes that brought down Poland's top leaders last month, to chart a future for the movement.

Delegates from throughout Poland reported that, in the 2 1/2 weeks since striking shipyard workers have won the right to form independent trade unions, hundreds of thousands of Polish workers have withdrawn from the old official unions and signed up with the new groups.

Despite the public authorization from the government and ruling Communist Party, however, many of the delegates said today that their efforts to establish independent unions have been hampered by official harassment and obstacles.

The widespread doubts expressed by delegates about the government's willingness to allow establishments of the new unions persuaded Gdansk Shipyard workers and their leader, Lech Walesa, to drop their opposition to a strong central federation.

The registration of the new national federation, which will be under the leadership of the Gdnask union, is planned for early next week in Warsaw and could provide a new confrontation between the workers and the government.

The government issued an order earlier this week requiring the new unions to register and apply for official legal status in Warsaw. But federal authorities reportedly expected the unions would sign up individually and it is uncertain how they will react to a single joint registration.

The future of many of the new unions is still far from assured.

In a rundown of the situation in their regions, spokesmen for 33 of the new area committees told a crowded union hall of instance after instance of harassment and lack of cooperation from authorities in establishing the independent groups.

Many said they have not been able to get office space and telephones. There were reports of workers being warned that if they join the new unions they will lose the benefits now provided by the official unions. Organizers complained that the new movement was being shut out of the government-controlled press.

Meeting for the first time as a national committee, the representatives issued a communique critical of the difficulties and discrimination they said have been put in their way and attacking the Polish news media for saying nothing about the new unions. It also charged the official unions, backed by the government, with issuing false propaganda about the free union movement.

Saying such obstacles conflicted with the agreement signed by the government with striking shipyard workers and miners, the union organizers demanded that authorities demonstrate full acceptance of the agreement.

Government and official trade union authorities have denied responsibility for any harassment. They have regularly affirmed their intention to honor the strike agreements.

But doubting these pledges, new union groups pressed for the creation of a national federation and a single registration.

The motion was at first opposed by the Gdansk group and its leader, Walesa, who had been the chief negotiator for the strikers and has since become a national hero and an iternational figure.

In open debate with other union representatives, Walesa objected to centralizing the new movement and argued instead for a loose federation with strong regional committees. Behind this appeared to be the fear that the development of a strong central structure for the new unions would lend itself to direct pressure or infiltration by undermining forces.

The Gdansk union, however, is perhaps the strongest and best organized of all the new groups as a result of the high degree of militant activity here during the summer. Other regional committees, feeling weaker and more threatened by continuing resistance, called for a national organization that might provide a greater show of strength and greater guarantee of survival.

Jan Olszewski, a lawyer speaking for the Warsaw Committee of Independent Unions, singled out the Polish government's registration decree as a source of continued uneasiness for the new union organizers.

Noting that the decree allows the Warsaw court to rule on the acceptance of any new union that registers, Olszewski said the court might find pretexts to disqualify some weaker unions.

For this reason, he proposed the new unions join together to register as one national union.

He was supported by Karol Modzelewski, a scientist and former dissident and now a union activist in Wroclaw.

"They are trying to disunite us," Modzelewski said. "The government is stressing separate registration, aiming at keeping us apart."

Faced with a potential split in their ranks, the union representatives held an hour-long closed door session of delegates from each of the regional committees.

In the meeting, the Gdansk group was persuaded of the need to form a central organization and it agreed to head a national federation.

"We didn't want to do it this way, but we were forced to as a sort of defensive alliance," said Lech Badkowski, a writer and member of the Gdansk organizing committee.

The meeting was a test of Walesa's ability to extend the charisma he showed in the Lenin Shipyard in Gdansk over union people from across Poland, and he seemed to do it.

He was clearly in control of the meeting, interjecting himself after speakers when he felt he had to answer a point.

When a worker from Ztleiec spoke of Polish workers being simple people who want their unions to be for everybody and pointed to the crucifix that Walesa had hung in the union hall as a sign of the movement's national development, Walesa stood up to say, "As long as I am here the cross will be."

During a question-and-answer session at the end, Walesa sought to counter gossip that has grown up about him largely as a result of his accepting a government apartment. He said the apartment was necessary because of his large family and asserted that it was the only thing he has accepted from the government.

"I'm even afraid of buying anything now," he said, "like furniture or curtains because people will say I take from the government."