AL MUKALLA, Yemen — The exiled Yemeni government said Friday that Saudi-backed fighters had “completely liberated” the southern city of Aden from the Houthi rebels who had tried for months to bring it under their control.

Witnesses in the city said that at least one neighborhood was still contested and that Houthi snipers remained active in several others. But rapid gains by the anti-Houthi fighters over the past few days appeared hard to reverse and potentially gave Saudi Arabia, which has been bombing the Houthis since late March and backing their opponents, its first battlefield victory.

The Yemeni prime minister, Khaled Bahah, called the gains a “historic moment” and said his government would quickly turn to repairing the devastation in Aden. The steady destruction of the city, Yemen’s second largest, has come to symbolize the hardships and horrors visited on civilians, including shelling, airstrikes and chronic shortages of water and electricity.

Of the more than 3,000 people who have been killed across Yemen since March, mostly civilians, hundreds died in Aden alone, caught in close-quarters fighting between the Houthis and their allies on one side and an assortment of armed forces, mostly local fighters, on the other.