News of the military agreement to end the NATO bombing of Yugoslavia spurred an outpouring of celebratory fireworks in blacked-out Belgrade tonight, menacing gunfire in Kosovo's shattered capital and expressions of concern from Serbs over what will follow 78 days of devastating warfare.

State-run television, which broke into its evening programs to report the conclusion of talks between NATO and Yugoslav generals in Macedonia, hailed the agreement as a victory for "the policies of President Slobodan Milosevic."

"Dear viewers and listeners," the broadcast began, "the aggression against Yugoslavia is over."

Government spokesmen also struck an upbeat note, with a senior member of the Yugoslav delegation at the Macedonia talks, Assistant Foreign Minister Nebojsa Vujovic, declaring that "the language of war has been replaced by the language of peace."

As word of the agreement spread, the sky over Belgrade erupted with fireworks and the orange streaks of antiaircraft tracer bullets, while the sound of gunfire echoed through the capital. Residents, whose giddy anti-NATO defiance of the early days of the war had in recent weeks turned to sour resignation amid the hardships of war, took to the streets in parades of horn-honking cars.

The mood was far less joyous in Pristina, the Kosovo capital, where troops who had been fighting to keep the province under Serbian control fired antiaircraft guns and automatic rifles into the air to mark the end of an unequal war. Disgruntled Serbs met to discuss whether they should remain in the province or flee in advance of the return of hundreds of thousands of their ethnic Albanian neighbors -- neighbors who were expelled from their homes and lands by government security forces.

In both Belgrade and Pristina, relief that the conflict with NATO appeared to be over was mingled with apprehension over the fate awaiting the 200,000-member Serbian minority in Kosovo; questions about how the country will recover from the destruction wrought by NATO bombs; and bitterness over seemingly pointless sacrifices by civilians and security forces alike. There were also signs that people here are beginning to challenge the judgment of Milosevic in leading the country into a war with the world's most powerful military alliance.

Belgrade government officials sought to deflect such concerns by praising the agreement on the withdrawal of Serb-led Yugoslav security forces from Kosovo as a triumph for common sense. They put special emphasis on the pledge that Serbia -- Yugoslavia's dominant republic -- will retain at least nominal sovereignty over Kosovo province, and the fact that the international peacekeeping force is being formed under U.N. auspices, even if it is to be made up largely of NATO troops.

Beyond hard-core Milosevic supporters, few people here bother to describe what happened over the past week as anything other than a major defeat. Feelings of disillusionment are particularly strong among Serbs in Kosovo, many of whom enthusiastically supported Milosevic's policies and now fear retaliation from ethnic Albanians who were expelled from their homes by government security forces and now will be returning under NATO protection.

State television tonight broadcast appeals by officials of the ruling Socialist Party, urging Kosovo's Serbs not to panic and to remain in the province despite the departure of Yugoslav troops and Serbian police. In Pristina this evening, several hundred disgruntled Serbs attended an outdoor protest meeting after they were refused permission to meet in a sports arena. The crowd applauded a local Serbian Orthodox archbishop when he urged them to show their respect for "sacred Serbian land" by remaining in Kosovo after the withdrawal of government forces and the arrival of international peacekeepers.

"If Serbs leave Kosovo, that will be a historic step that cannot be reversed," Archbishop Artemye told the crowd.

A mass exodus of Serbs from Kosovo could threaten political stability in Serbia proper and pose a significant threat to Milosevic, who rose to power in 1987 by promising to defend the interests of Serbs in Kosovo -- which at the time had a large measure of autonomy that benefited its 1.6 million ethnic Albanians. As it is, the Milosevic government will face huge challenges over the coming months in providing for the needs of thousands of soldiers and policemen returning from Kosovo.

Such mounting social and economic problems have led some political analysts here to conclude that Milosevic's days in office are numbered, even if there is no obvious replacement for him at present. "I think he is finished," said a leading Belgrade journalist.

The agreement with NATO has already caused strains within the ruling coalition, which is made up of Milosevic's Socialist Party; the Yugoslav United Left Party, led by his wife, Mirjana Markovic; and the extreme nationalist Radical Party, led by Vojislav Seselj. Seselj has denounced the agreement as a sellout to NATO and threatened to withdraw from the government as soon as the first NATO troops enter Kosovo.

Seselj can create serious political problems for Milosevic if he decides to campaign against the agreement. If he went into opposition, Milosevic would have to make political concessions to the moderate Serbian Renewal Movement, led by former deputy prime minister Vuk Draskovic, to retain his parliamentary majority.

According to Yugoslav sources, however, Seselj has given Milosevic private assurances that he will make no attempt to bring down the government.

Correspondent Daniel Williams in Pristina contributed to this report.

CAPTION: Exultant young people cheer and wave atop a car in Belgrade as word spread that a final agreement on Kosovo troop withdrawal had been reached.