Soldiers arrested most of the members of Sudan's cabinet on Monday and the military chief dissolved the transitional government, while opponents of the takeover took to the streets where gunfire and injuries were reported.
Abdel Fattah al-Burhan, a general who headed the Sovereign Council, a ruling body that had shared power between the military and civilians, announced a state of emergency. The military needed to protect the country's safety and security, he said, and the council had been dissolved.
"We guarantee the armed forces' commitment to completing the democratic transition until we hand over to a civilian elected government," he added, setting elections for July 2023.
"What the country is going through now is a real threat and danger to the dreams of the youth, and the hopes of the nation to build a nation whose features are starting to emerge."
Prime Minister Abdalla Hamdok was detained and moved to an undisclosed location after refusing to issue a statement in support of the takeover, said the information ministry, still apparently under the control of Hamdok's supporters.
The ministry called Burhan's announcement a "military coup" and called for resistance. It said tens of thousands of people opposed to the takeover had taken to the streets and had faced gunfire near the military's headquarters in Khartoum.
At least 12 people were injured in clashes, a doctors' committee said on its Facebook page, without providing further details.
In Khartoum's twin city Omdurman, young protesters barricaded streets and chanted in support of civilian rule, though blockages of phone and internet networks appeared to limit their ability to coordinate large gatherings.
"We will defend democracy until the end," said one protester, 21-year-old Iman Ahmed.
"Burhan cannot deceive us. This is a military coup," said another young man who gave his name as Saleh.
Sudan had been on edge since a failed coup plot last month unleashed recriminations between military and civilian groups sharing power uneasily following the toppling of long-serving ruler Omar al-Bashir two years ago.
Since Bashir was brought down by street protests, the political transition had seen Sudan emerge from international isolation under his nearly three-decade rule.
The director of Hamdok's office, Adam Hereika, told Reuters that the military had mounted the takeover despite "positive movements" towards an agreement with Hamdok following meetings with a visiting US special envoy, Jeffrey Feltman.
Joint forces from the military and from the powerful, paramilitary Rapid Support Forces were stationed in the streets of Khartoum.
'RAISE OUR VOICES'
The information ministry said military forces had arrested civilian members of the Sovereign Council and members of the government. In a statement sent to Reuters, it called on Sudanese "to block the military's movements to block the democratic transition".
"We raise our voices loudly to reject this coup attempt," it said.
The military was meant to pass leadership of the joint Sovereign Council to a civilian figure in the coming months. But transitional authorities had struggled to move forward on issues including whether to hand Bashir over to the International Criminal Court, where he is wanted for war crimes.
In recent weeks, civilian officials had claimed credit for some tentative signs of economic stabilisation after a sharp devaluation of the currency and the lifting of fuel subsidies.
Burhan said it was incumbent on the armed forces to sense the danger and act after infighting between some political forces and "the striving for power" and "incitement to chaos and violence".
Feltman, the US special envoy who had been visiting Sudan on Saturday and Sunday, tweeted that a military takeover would put US aid at risk. The US embassy urged people disrupting the transition to democracy to stand down and let the civilian-led government continue its work.
The United Nations, Arab League and African Union all expressed concern. Sudan's political leaders should be released and human rights respected, the AU Commission Chair Moussa Faki Mahamat said in a statement.
Sudan is in the midst of a deep economic crisis, marked by record high inflation and shortages of basic goods, though that was beginning to show signs of easing amid flows of international aid. Western states have warned that any military takeover would put aid at risk.
Military forces stormed Sudanese Radio and Television headquarters in Omdurman and arrested employees, the information ministry said on its Facebook page. Two major political parties, the Umma and the Sudanese Congress, condemned what they called a coup and the campaign of arrests.
Hamdok is an economist and former senior UN official appointed as a technocratic prime minister in 2019. He had struggled to sustain the transition amid splits between the military and civilians and the pressures of the economic crisis.
Family sources told Reuters military forces had stormed the house of Hamdok's media adviser and arrested him.
Many of the ministers and officials who had been arrested had been intensifying their rhetoric towards the military in the past few weeks.
The Sudanese Professionals Association, a main activist coalition in the uprising against Bashir, called on supporters to mobilise after what it called the arrest of cabinet members.
"We urge the masses to go out on the streets and occupy them, close all roads with barricades, stage a general labour strike, and not to cooperate with the putschists and use civil disobedience to confront them," the group said on Facebook.
As tensions built this month, a coalition of rebel groups and political parties aligned themselves with the military and called on it to dissolve the civilian government, staging a sit-in outside the presidential palace.
Last week, several cabinet ministers took part in big protests in several parts of Khartoum and other cities against the prospect of military rule.