French Prime Minister Edouard Philippe has tendered his resignation after heading President Emmanuel Macron’s government for three years.
The president quickly named centre-right mayor Jean Castex to lead a new team of ministers after a reshuffle.
Although Mr Philippe was considered more popular than the president, the ruling party had poor local election results at the weekend.
President Macron promised a new path in an interview published on Friday.
Mr Philippe met the president early on Friday and they agreed the government would resign.
A reshuffle has been expected for some time, and it is common practice for a French president to replace a prime minister during the five-year term in office known as the “quinquennat”.
The Elysée palace said in a statement that Edouard Philippe had “today handed in the government’s resignation to the president of the republic, who accepted it”, adding that he would stay in place until a new government was appointed.
Mr Castex, 55, is little known in France, but he has played a key role in the government’s response to the Covid-19 pandemic. Mr Philippe picked the Republicans party mayor from Prades in the Pyrenees to co-ordinate France’s strategy of lifting the lockdown.
The elections revealed surging support for the Green party and underlined Macron’s troubles with left-leaning voters.
Political analysts in the country are of the opinion that it will be a political gamble for Macron to replace Philippe, who is more popular with the public than the president.
The prime minister could emerge as a presidential rival in 2022.