Former Pakistani chief justice Nasir-ul Mulk has been chosen to act as the interim prime minister until parliamentary elections are held in two months.
The ruling party, Pakistan Muslim League-Nawaz, and the opposition announced on May 28 that Mulk will serve until elections are held on July 25.
Mulk, 67, is due to be sworn in as prime minister on June 1, one day after parliament is dissolved and Prime Minister Shahid Khaqan Abbasi's mandate expires.
It's only the third time in Pakistan's 70-year history that a parliament completed its five-year term without being dismissed by the military or due to a political uprising.
Abbasi, Syed Khursheed Shah, opposition leader in the lower house of the bicameral parliament, and Ayaz Sadiq, speaker of the National Assembly, made the announcement in a joint press conference in Islamabad.
Shah said the decision was made jointly with the ruling party and others, and that Mulk had played "a historic role" in Pakistan. "I hope that God will give him courage and passion and he will succeed in conducting elections to be held on July 25."
Pakistan's prime minister is elected by the National Assembly, the country's lower house of parliament, and at the end of the government's five-year term a caretaker prime minister is selected whose main duty is to oversee the Election Commission in holding free and fair elections.
Mulk served as chief justice in 2014-15 and before that was a senior judge on the Supreme Court. He was previously chief justice of the Peshawar High Court in Khyber Pakhtunkhwa Province.