Bulgaria's Prime Minister Boyko Borisov has said he will resign after his party's candidate was defeated in presidential elections.
Mr Borisov had backed the centre-right speaker of parliament, Tsetska Tsacheva, who got only 35% in Sunday's run-off vote, according to exit polls.
A political outsider, the former commander of the country's Air Force Rumen Radev, won with more than 58%.
He was backed by the opposition Socialist Party.
Earlier on Sunday, Mr Borisov had said: "We will not participate in any way in the government if we lose today."
After the exit polls gave the opposition's candidate an overwhelming lead, he said he would fulfil his promise in the coming days.
"The results clearly show that the ruling coalition no longer holds the majority," he said.
"We accept the will of the people and we congratulate those who have the support of the majority of the voters."
The coalition that Mr Borisov formed upon re-election in 2014 is dependent on the support of centre-left and nationalist parties.
President-elect Radev has said he will keep Bulgaria in Nato but has affirmed that "being pro-European does not mean being anti-Russian".
His opponent, Mrs Tsacheva, was seen as more pro-Europe than him, and had referred to Bulgaria's past as a Soviet satellite as the country's "dark past".
About 6% of voters ticked a "none of the above" option on their ballot paper.