Oresharski won support from 120 out of the 217 lawmakers present in the divided 240-seat parliament, with 97 opposed.
"The country is in a deep institutional crisis, continuing economic depression and worsening disintegration of society," the 53-year-old finance professor said before the vote confirming his 16-member cabinet.
He urged "maximum public consensus on the necessary urgent measures for stabilisation, economic recovery, strengthening of the institutions and more solidarity in a society shaken by despair and lack of prospects."
Massive and sometimes violent anti-poverty street rallies ousted the previous government of conservative premier Boyko Borisov in February.
More From This Section
His GERB party won tight snap elections on May 12 but failed to find partners to govern in an extremely polarised legislature, leaving the second-placed Socialists to name a new prime minister.
Oresharski's cabinet was approved with support from the Socialist BSP and the Turkish minority party MRF, while the ultra-nationalist Ataka boycotted the vote.
Stern non-partisan Oresharski, who served as finance minister in a Socialist-led coalition cabinet between 2005 and 2009, has pledged to ensure fiscal and macroeconomic stability and a low budget deficit and public debt ratio, as well as maintain the Bulgarian lev's currency peg to the euro.
Oresharski has named two leftwing fellow economists to help with his programme, university professor Petar Chobanov, 36, as finance minister and Socialist lawmaker Dragomir Stoynev, 37, as economy and energy minister.
Zinaida Zlatanova, who previously headed the European Commission representation in Bulgaria, will take the sensitive justice ministry, which has come under repeated criticism from Brussels over lagging reforms, and will also oversee the use of EU aid funds as vice premier.
Just one seat short of a majority in the legislature even with the MRF's support, the Socialists will need to rely on the support of the unpredictable far-right Ataka to pass legislation.
This might make its work extremely difficult, analysts said.
Most observers predict the cabinet will not fulfil its four-year term, with some saying it might not stay in place more than a year.
It might be extremely difficult to oust, however, as this will require an absolute majority of 121 lawmakers, he added.
Borisov's GERB has just 97 seats, while Ataka has 23.
"The risks for the cabinet lie outside parliament, in a society that is now waiting to see what will be accomplished but is ready to mobilise quickly if things take a wrong turn," Todorov said.
Addressing low incomes and high energy bills that sparked the winter rallies, and other problems such as slow judiciary reforms, growing crime and severely underfunded healthcare, was key to win the people's trust, he added.