Sudan's military has ousted President Omar al-Bashir, according to a Defence minister announcement issued Thursday.
The ouster ends a 30-year authoritarian rule in the face of mass street protests that have swept the country.
Mr Awad Mohamed Ahmed Ibn Auf, the Defence minister, said that Mr Al Bashir had been taken into custody, and that the government had been dissolved and the Constitution suspended.
He announced a 10pm curfew and said there will be a two-year transition period, with the military in charge.
Mr Al Bashir, 75, long regarded as a pariah in the West and wanted by the International Criminal Court (ICC) on genocide charges in connection with atrocities in Darfur, had ruled Sudan longer than any leader since the country gained independence in 1956.
Before the announcement, protesters demanding his ouster had gathered outside the military headquarters in Khartoum, the capital.
They shouted a chant addressed to the President: "You've been dancing for 30 years. Today it's our turn to dance."
"It's a huge day for Sudan's people, it's a revolution day," a man in the crowd, Elsamawal Alshafee, 32, said by phone.
The jubilation was tempered by a wary uncertainty about what will come next.
A senior official said that leaders of the military and security services were debating privately about the membership and structure of the transitional government.
A State news agency reported that political detainees were being released.
Some leaders of the demonstrations called for caution as they awaited the statement from the military.
Those calling for Mr Al Bashir's ouster would not be satisfied if he were simply replaced by another general, said Ms Sara Abdelgalil, a spokeswoman for the Sudanese Professionals Association, which is organising the protests.
"We have asked for people to continue the sit-in," she said. "The uprising continues."
The protests will continue "until there is a complete step-down of the whole regime," she said. "We insist on a civil government, and we don't support any coup."
Mr Al Bashir came to power as a little-known general in 1989 during an Islamist and military-backed coup. In the following years, he purged Islamists and insiders from his party, and demonstrated a knack for political survival.
He tightened his control by building up an array of competing security forces and militias, as well as the regular army.
Sudan analysts have warned that those forces will begin to tussle for dominance once the long-time ruler is out of the picture.
Protests began in December over rising food costs, but quickly expanded to a broad challenge to Mr Al Bashir's hold on power.
In recent days, rival factions within the security services have battled each other, raising fears of a complete breakdown in order as armed military groups fight for control.
A striking photo of one protester standing on a car and wearing a white thoub, a long robe, and gold earrings as she urged on a crowd this week was called an iconic image of the demonstrations and was shared widely online.
Mr Al Bashir's three decades of rule have been marked by famine and war, with the country dividing and a new nation, South Sudan, gaining independence in 2011.
South Sudan and Libya, Sudan's neighbour to the northwest, are each now gripped by armed conflict, raising the threat of widespread regional instability should Sudan also fall into civil war.
For months the security services have detained and attacked protesters in an effort to prevent the demonstrations from swelling, but in recent days, crowds opposed to Mr Al Bashir have grown outside the compound in Khartoum that houses his residence and the military's headquarters.
The sit-in marked a new stage of the protests, with numbers swelling far beyond those of previous demonstrations, organisers said.
Their mood ranged from delight at the display of people power to fear that the authorities would soon crack down.
In recent days, soldiers protected demonstrators from other security services that were attempting to disperse them.
Some protesters called on the regular army to oust Mr Al Bashir, but analysts have warned that the military, which has waged war with rebel groups for decades and is accused of widespread abuses, is not seen as a unifying force across the country.
Mr Al Bashir is the only active leader of a nation who faces charges before ICC.
As word of his possible ouster emerged, human rights groups called for him to stand trial over his role in crimes against humanity and genocide in the Darfur region.
"If the Sudan military's important announcement is that Pres Bashir will finally step down, it should demonstrate its commitment to the rule of law and an end to mass atrocities by delivering him to the International Criminal Court to face charges," Kenneth Roth, the executive director of Human Rights Watch, said on Twitter.