(CNN) -- A 30-year ironclad rule undone by an 18-day revolution saw its epilogue Wednesday -- with former Egyptian President Hosni Mubarak in a stretcher, inside a cage, in court.
At one time, the 83-year-old Mubarak dominated Egypt's political landscape by intimidating opponents and infiltrating political movements.
Now, he is on trial, charged with corruption and ordering the killing of anti-government protesters. He faces a possible death penalty if convicted.
Mubarak came to power in 1981, after then-President Anwar Sadar died in a hail of gunfire at a military parade -- killed by Islamic militants from within the army's own ranks after he took the dramatic step of making peace with Israel.
Mubarak was a Soviet-trained pilot who was chief of staff of Egypt's air force during the 1973 Mideast war. The early success of Egyptian pilots against Israel made him a national hero, and Sadat made him vice president in 1975.
Upon assuming office following Sadat's assassination, one of Mubarak's first acts was to declare a state of emergency that barred unauthorized assembly, restricted freedom of speech and allowed police to jail people indefinitely.
He made extensive use of those powers in the ensuing decades. The Egyptian army put down riots by disgruntled police officers in 1986, and Mubarak threw an estimated 30,000 people in jail when jihadists carried out a string of attacks on tourists.
"He pretty much wiped them out," said Juan Cole, a Middle East historian at the University of Michigan. "It's not an accident that they were in Afghanistan instead of Egypt." And the government has also penetrated opposition movements so thoroughly that "If five people sit down to plot something, the fifth person writes a report to Hosni Mubarak about it," he said.
He won four terms as president in elections that were considered formalities. His fifth, in 2005, was Egypt's first multi-party presidential vote, but it was considered a "sham" by many.
The country's economy stagnated for the first 20 years of his rule. Development picked up in the past decade, fueled by a move away from state control and by billions in tourist dollars, but its gains have been unevenly distributed, analysts say. About 40 percent of Egyptians currently live in poverty.
Under Mubarak, Egypt was a major player in Israeli-Palestinian peace talks, and it contributed troops to the U.S.-led coalition that drove Iraq out of Kuwait in 1991.
It gets about $1.3 billion in military aid from Washington every year, second only to Israel, and has received nearly $30 billion in economic aid since 1975, according to State Department figures.
But it opposed the U.S. invasion of Iraq in 2003.
President Barack Obama said in January that Mubarak had been "very helpful on a range of tough issues." And last week, Israeli Prime Minister Benjamin Netanyahu told the Arab language news network Al-Arabiya that he respected Mubarak.
"He held peace between Israel and Egypt for over 30 years, and that's a great achievement, and I think it should not be forgotten," Netanyahyu said.
In 2005, when Egyptians mounted large-scale protests to demand fundamental and widespread reform, Mubarak intimidated the leaders of the officially banned but tolerated Muslim Brotherhood, harassed middle-class demonstrators and managed to pick off the leadership of those protests.
But Mubarak was finally forced to step down February 11 after an 18-day uprising during which pro-democracy protesters demanded reform and a new government. Egypt is now ruled by a military council and a caretaker cabinet, which has promised reform and new elections.
The human rights group Amnesty International has estimated at least 840 people were killed and more than 6,000 wounded during the revolution.
The aging autocrat escaped at least two assassination attempts, including a close call in 1995 when Islamic militants opened fire on his motorcade at a pan-African conference in Ethiopia.
In 2003, Mubarak collapsed while delivering a televised speech to the Egyptian parliament -- returning later to blame his illness on the flu. He had back surgery in Germany in 2004, returning in 2010 to have his gall bladder removed.
Despite his bouts of illness, Mubarak never picked a vice president. He had anointed his son Gamal as his successor.
But on Wednesday, there he was -- Gamal Mubarak, alongside his father and his brother Alaa, in the Cairo courtroom on trial.
CNN's Ed Payne and Matt Smith contributed to this report.