UNITED NATIONS, AUG. 26 -- After years of being dismissed as a failure and a forum for Third World demagoguery, the United Nations suddenly has been transformed into the mechanism through which the world community hopes to prevent the Persian Gulf crisis from becoming an arena of bloody warfare.

It is perhaps the most dramatic illustration to date of how the long Cold War rivalry between the United States and the Soviet Union and their allies has been replaced by a determination to work together against threats to peace.

Since Aug. 2, when Iraqi forces stormed into tiny Kuwait, the U.N. Security Council, in the most sustained show of unanimity in the United Nations' 45-year history, quickly passed a succession of resolutions demanding Iraq's withdrawal from Kuwait, imposing far-reaching economic sanctions against President Saddam Hussein's government, declaring the annexation of Kuwait "null and void" and challenging Iraq's efforts to make hostages of third-country nationals and to close foreign embassies in Kuwait. On Saturday, the United Nations reinforced its earlier steps by authorizing the world's navies to use force against attempts to evade the sanctions.

Those actions comprise the noose of diplomatic isolation and economic pressure that the world body has been seeking to draw around Iraq. As Henry A. Kissinger and Zbigniew Brzezinski, both former national security advisers, have noted, tightening the noose offers the only hope of forcing Iraq to bow to the will of the world community.

Kissinger and Brzezinski warned that the United States has a particularly big stake in the success of U.N. actions because their failure could mean a choice between expelling Iraq from Kuwait by military force or keeping a massive U.S. military presence bogged down interminably in Saudi Arabia.

The recent round of activity is what U.N. officials call a textbook example of what the World War II allies had in mind during the final days of the war when they began drafting the charter of an organization that would be able, in the new atomic age, to prevent regional conflicts from growing to global proportions.

Even before 1945, the year the United Nations was founded, the idea was that the world body would use such methods as diplomatic boycotts and economic embargoes -- the same weapons now being employed against Iraq -- to make an aggressor have second thoughts. For 45 years, though, it didn't work that way.

The United Nations' founders saw the 15-member Security Council as the focus of power in the new organization. By giving the five principal wartime victors -- the United States, the Soviet Union, Britain, France and China -- permanent seats with the right to veto any Council decisions, they set up a supposedly clubby arrangement under which the Big Five would decide among themselves what course the United Nations would follow and impose their will on the rest of the membership.

But the idea of consensus among the five was thwarted from the outset by the bitter Cold War between the United States and the Soviet Union. In those early years, the images of the United Nations that became engraved on the world's consciousness were of grim-faced Soviet ambassadors casting vetoes or storming out of Council meetings.

During the years of Security Council paralysis, the center of gravity within the United Nations passed to the General Assembly, a sort of international town meeting with little real power. As the end of colonialism swelled the United Nations' ranks with Third World countries, the new members turned the Assembly into a forum for frequently shrill, anti-Western rhetoric, such as its 1975 declaration equating Zionism with racism, that made the U.S. public and Congress increasingly reluctant to support or rely on the world body.

Then, about two years ago, a change began to set in as the result of the detente-oriented changes in Soviet foreign policy. As Moscow and Washington increasingly found areas of concurrence, Secretary General Javier Perez de Cuellar and his aides were able to play an expanded role in helping to resolve several regional conflicts.

They mediated a cease-fire in the eight-year war between Iran and Iraq (ironically setting the stage for Iraq's current actions against Kuwait), oversaw the independence of Namibia, helped to arrange Soviet withdrawal from Afghanistan and are involved in efforts to resolve conflicts in Cambodia, Central America and the Western Sahara.

However, despite such advances, no one here was prepared for the unprecedented U.S.-Soviet cooperation that has been evident in the current crisis. The two nations' only disagreement involved the timing of Saturday's resolution on naval force.

If there has been a discordant note in the United Nations' approach to the gulf crisis, it involves the feeling of some Third World countries that the new harmony among the Security Council's members could erode the power of the General Assembly's larger numbers. That feeling led some to argue that any naval forces enforcing the embargo should be controlled by the United Nations.

As Colombia's ambassador, Enrique Penalosa, said before casting his vote for the resolution, his government would have preferred more explicit U.N. control over what is, in effect, a naval blockade. But, he added, "the most important thing is that a clear message must be sent to Iraq that the international community will not tolerate violations of world peace."