The Muslim Brotherhood member had been in office for just a year when army chief, General Abdel Fattah el-Sisi, announced his overthrow on state television, along with the suspension of the constitution and the installment of an interim government.
The military said it was responding to the people, who had poured into the streets by the millions on June 30, 2013, over fears that Morsi was becoming increasingly authoritarian.
In just over two years, Morsi became the second Egyptian leader to be overthrown. During a wave of popular uprisings that swept across the Arab world in 2011, the Egyptian people also overthrew the 30-year dictatorship of military leader Hosni Mubarak.
The social and political upheaval during those years plunged Egypt into an economic crisis and deeply divided the nation.
But Sisi's rise in June 2014 was supposed to herald a new era of stability. He introduced rapid economic reforms, such as slashing fuel subsidies and raising taxes in an effort to ease unemployment and generate long-term revenues. He also initiated several new infrastructure projects, including the expansion of the Suez Canal and the country's farmland area, which he said would make Egypt more self-sufficient and generate jobs. As violence dwindled, tourism revenues increased.
Yet experts say the temporary stability, which has begun to erode, came at the cost of public freedoms.
"Some Egyptians have accepted the return of some of the 'old guard' because they believe that, for all its faults, the Mubarak regime brought them more stability than the Morsi regime," Sarah Yerkes, a fellow at the Washington-based Carnegie Endowment for International Peace, told Al Jazeera. "In the long run, this type of thinking is irrational - Mubarak was only able to control Egypt for so long - but in the short run, some people are willing to put up with more repression [and] less freedom in exchange for what they perceive to be greater stability."
Shortly after Morsi's removal, the military-backed interim government embarked on a crackdown on Muslim Brotherhood supporters, many of whom who continued to stage counterprotests and express their support for Morsi.
In August 2013, the army and security forces attacked a demonstration in Rabaa al-Adawiya Square, killing some 1,000 Morsi supporters. Human Rights Watch described it as "one of the largest killings of demonstrators in a single day in recent history".
And in a widely criticised mass trial, Egypt sentenced hundreds of alleged supporters of the Muslim Brotherhood to death - "the biggest mass sentence given in modern Egyptian history", according to Amnesty International. The movement, which is Egypt's oldest, most influential Islamist group, was also banned and had its assets seized before being declared a "terrorist organisation" by the government.
"The violent repression of Morsi's supporters sent a stark message to all Egyptians that under the resurgent authoritarian rule of the Sisi regime: Dissent will not be tolerated. Along with the mass imprisonment of over 50,000 people, this has ensured that opposition to the regime has remained limited in the years since," Abdullah al-Arian, a professor of history at Georgetown University's School of Foreign Service in Qatar, told Al Jazeera.
A few months into office, Sisi passed a law banning demonstrations without prior police approval, leading the protest movement to practically dry up. Such oppressive measures, analysts say, were bound to tighten the noose on the country and bring in a facade of stability.
"Many Egyptians just wanted economic and political stability; hence, the support for the Sisi coup. Immediately after Sisi took power, Saudi and Gulf money began to flow into Egypt, temporarily stabilising the Egyptian economy and winning for Sisi the support Morsi had squandered," James Gelvin, a professor of Middle East history at the University of California, Los Angeles, told Al Jazeera.
"Egypt is much more authoritarian today than it was under any leader since Gamal Abdel Nasser … Under Sisi, all oppositional activity has been outlawed, the Muslim Brotherhood banned, and political opponents - whether Islamist or secular - killed, imprisoned and tortured."
Under Mubarak, there was not much room for dissent, but there were clear red lines. People could mostly go about their business, as long as they did not criticise Mubarak, Islam or the security forces. Today, no one is safe.
Human rights defenders, civil society groups and NGOs have also been targeted, systematically summoned for questioning, banned from travel and having their assets frozen. A new law, signed in May, criminalises the work of many NGOs and places them under the direct surveillance of the country's security bodies.
"Under Mubarak, there was not much room for dissent, but there were clear red lines," Yerkes said. "People could mostly go about their business, as long as they did not criticise Mubarak, Islam or the security forces. Today, no one is safe. The government is fractured, so there is no clear line of control, and anyone can become a target of the regime at any time."
Despite electing him to power, millions came out against Morsi's moves to grant himself broad legislative and executive authority. Many people, mainly secularists and members of the old guard, feared that the uprising could end badly. The chaos that gripped Syria and Libya after the Arab Spring served as a stark warning to the public.
"With 30-40 percent of the country living on $2 a day or less, there is very little room for manoeuver for them," Mark Levine, a professor of Middle East history at University of California, told Al Jazeera. "If the country grinds to a halt with new protests, literally millions of people face financial ruin and even hunger very quickly."
While Sisi's public standing went largely unchallenged during his first two years in power, a series of recent decisions have tested his popularity and grip on the country.
Last year, the government announced a maritime agreement with Saudi Arabia to transfer control over two Red Sea islands, leading thousands to take to the streets in peaceful protests. In response, the government sentenced 71 people to two years in prison.
Cracks in the economy have also resurfaced. In May, Egypt's inflation rose to 30 percent, the highest in three decades. Under a $12bn IMF bailout loan to support Egypt's economic reform plan, the government floated the currency and raised the price of fuel by 55 percent for the second time in months.
The other large domestic threat Egypt is facing is the violence in the Sinai, where armed groups, affiliates of the Islamic State of Iraq and the Levant (ISIL, also known as ISIS), have launched an open war against the government, security forces and civilians.
"While Egypt did experience bouts of terrorist violence under Mubarak, the insurgency in Sinai is now more protracted and attacks are continuing against civilians and security forces regularly on the mainland," Allison McManus, research director of the Tahrir Institute for Middle East Policy, told Al Jazeera.
"In response, the government has carried out a widening range of security, legal and political actions in the name of a war on terror that have targeted and ensnared not only violent actors, but also opposition figures and others, to a degree unseen in the Mubarak years."
And while the government claims it has the issue under control, its efforts to contain the violence in the Sinai, which dates back to before 2011, have been largely unsuccessful.
Among what have now become almost systematic attacks, the group downed a Russian passenger jet, killing 224 people in 2015, and this year, targeted churches and buses carrying Christians in Sinai province, killing close to 100 people in recent months.
"The government has faced a serious terrorist threat and received some criticism for its handling of it. The country is clearly less secure, but this is also a result of regional trends, especially the rise of ISIS," Issandr el-Amrani, head of the North Africa section at the International Crisis Group, told Al Jazeera.
Though Egypt's position on the international front seems to be strengthening as it forges closer ties with the United States, Saudi Arabia and Israel, analysts say that domestically, Egypt is on the decline.
"On virtually every indicator, Egypt is worse off today than it was under Mubarak," Yerkes said. "The security situation is far worse, the economy is worse, the levels of repression are far higher and the ability of the government to deliver basic goods and services has declined."
Source: Al Jazeera