Pakistan's prime minister has said sacked Supreme Court chief justice Iftikhar Chaudhry will be reinstated, meeting a key opposition demand.
"I announce the restoration of all deposed judges including Mr Iftikhar Chaudhry," PM Yousaf Raza Gilani said.
Mr Gilani said Mr Chaudry would resume his post on 21 March. There has been a series of violent protests demanding the judges' reinstatement.
Opposition leader Nawaz Sharif called off a planned march on Islamabad.
Mr Chaudhry and 60 other judges were dismissed by Gen Musharraf in 2007.
Most have since been reinstated but Mr Chaudhry and a handful have not been allowed to return to their old posts.
Mr Gilani said Mr Chaudhry could take up his old post after current Chief Justice Abdul Hameed Dogar retires on 21 March.
His announcement, broadcast on television, triggered scenes of jubilation from Mr Chaudhry's supporters outside his home in Islamabad.
Mr Gilani also said opposition activists and leaders detained over the last week of mounting political disturbances would be freed and a ban on public demonstrations in the capital and several provinces lifted.
"I want to congratulate the nation. Let us celebrate this with dignity," he said.
On Sunday, Mr Sharif - a former prime minister - defied an apparent effort to place him under house arrest in the city of Lahore.
Supporters of Mr Sharif clashed with police, but managed to overcome barriers blocking access to the main highway to Islamabad and Mr Sharif left in a convoy.
He then joined anti-government protesters planning a march on the capital to demand the re-instatement. But early on Monday he called off the protest.
The campaign over the judges has become the arena of a power struggle between Mr Sharif and President Zardari, says the BBC's Barbara Plett in Islamabad.
The unrest has alarmed the West, which wants Pakistan to focus on the battle against the Taleban on the Afghan border, says our correspondent.
A militant insurgency based in the north-west of Pakistan has shown signs of spreading throughout the country.
Earlier in March, the visiting Sri Lanka cricket team was attacked by gunmen in Lahore. Eight tour members were injured and six policemen were killed.
The tensions between Mr Zardari and Mr Sharif date back to the 1990s, but the two formed a brief partnership in government after parliamentary elections in February 2008.
President Zardari had promised to bring back the judges when he took office last year following his wife's assassination.
But Mr Sharif's party later left the alliance, complaining of reluctance by Mr Zardari's Pakistan People's Party to reinstate them.
The latest crisis was sparked by a Supreme Court decision to ban Mr Sharif and his brother Shahbaz from elected office, and President Zardari's decision to put their stronghold in Punjab province under direct rule from Islamabad.