Egypt's new caretaker president Adly Mansour, sworn in on Thursday, had been head of the Supreme Constitutional Court for just two days when the army named him leader of the Arab world's most populous state.
Despite his previously low profile, the judge came across as statesmanlike in a nationally televised oath-taking ceremony, during which he hailed Wednesday's army overthrow of Mohamed Morsi.
"I swear to preserve the system of the republic, and respect the constitution and law, and guard the people's interests," he declared.
He saluted the Egyptian people "for correcting on June 30 the path of this glorious revolution," in reference to protests that saw millions take to the streets to demand the resignation of the Islamist president.
He also praised the armed forces for having "always been the conscience of the nation" and "not hesitating for a moment to meet the call of the nation and people".
Mansour takes the helm of a nation riven by deep divisions after days of massive protests and deadly clashes between supporters and opponents of Morsi.
Ironically he was named by the ousted leader himself to Egypt's top judicial post in May and took up his functions on July 1.
The 67-year-old father of three, who won a scholarship to France's most prestigious institute of higher education, the Ecole Nationale de l'Administration, was a long-serving judge under the regime of veteran strongman Hosni Mubarak.
Mansour helped draft the supervision law for the presidential elections that brought Morsi to power in 2012, which included setting a legal timeframe for electoral campaigning.
He was deputy head of the Supreme Constitutional Court from 1992.
Unlike the principal leaders of the opposition -- among them Nobel peace laureate Mohamed ElBaradei and former Arab League chief Amr Mussa -- Mansour was never a household name.
But that probably served the military's purposes in their search for a neutral figurehead for a potentially rollercoaster transition.
The white-haired, bespectacled judge could probably have walked through one of the huge opposition protests that swept the country on Sunday prompting the military's dramatic intervention without being recognised.
With the constitution suspended, Mansour was granted powers to issue constitutional declarations until a new charter is written.
But it is unclear how much room to manoeuvre he will have in the face of the powerful army and particularly its chief Abdel Fattah al-Sisi who has emerged as Egypt's new strongman.
Mansour will remain head of state until a new presidential election, the date for which has not been set.