Hailemariam Desalegn had been Ethiopia’s prime minister since 2012 (Photo: AFP/Getty Images)
In a televised address, he said his resignation was “vital in the bid to carry out reforms that would lead to sustainable peace and democracy”.
Mr Hailemariam, who has led the country since 2012, also stepped down as chairman of the ruling coalition.
Hundreds of people have died in three years of anti-government protests.
Demonstrations first spread across the country in 2015 amid calls for political and economic reform and an end to state corruption.
Most of the unrest has centred on Ethiopia’s two largest regions, Oromia and Amhara.
A 10-month national state of emergency ended last year. “Unrest and a political crisis have led to the loss of lives and displacement of many,” Mr Hailemariam said.
“I see my resignation as vital in the bid to carry out reforms that would lead to sustainable peace and democracy.”
The BBC’s Emmanuel Igunza, in the capital Addis Ababa, says protests have continued despite the government releasing thousands of opposition supporters from jail last month.
The disturbances have led to deep divisions in the governing coalition, says Mary Harper, Africa editor for the BBC World Service.
Some of Ethiopia’s powerful elites have come to see the prime minister as weak and lacking in direction, she says.
A weak and turbulent Ethiopia is risky for the entire Horn of Africa, our correspondent adds, as this normally stable state is seen as key to holding the region together.
Mr Hailemariam said he will stay on as a caretaker prime minister until Ethiopia’s parliament and ruling coalition accept his resignation and choose a replacement.