The move ends a protracted political crisis that had cast grave doubt over the country's future in Europe's joint currency and threatened to plunge the continent deeper into a financial crisis with global repercussions.
But the new government still has massive challenges ahead: It must deliver on pledges by its predecessors to generate huge new savings, privatize publicly-owned companies and real estate, cut about 150,000 civil service jobs in coming years and open restricted professions to competition.
Samaras, a U.S.-educated 61-year-old economist, was sworn in three days after his New Democracy party won the second national elections in six weeks but without enough votes to form a government on its own. He is Greece's fourth prime minister in eight months.
The conservatives will join forces with the socialist PASOK party, which came in third place, and the smaller Democratic Left led by Fotis Kouvelis. Discussions on the lineup of ministers were expected to be completed by Wednesday night.
"I will ask the new government that will be formed tomorrow to work hard so that we can offer tangible hope to our people," Samaras told reporters as he left the presidential mansion.
Greek stocks rose marginally in response to the news, with Athens shares closing up 0.5 per cent, limiting earlier gains.
Analyst Theodore Krintas said he expected markets to welcome the breakthrough.
"The formation of a government ... will take part of the uncertainty away and at the same time hopefully will take Greece out of the (headlines) of the mass media all over the world," said Krintas, who is managing director of Attica Wealth Management.
The new prime minister was to meet with outgoing Finance Minister Giorgos Zanias, PASOK head Evangelos Venizelos and Kouvelis on Wednesday evening.
All three parties broadly back Greece's pledges to bailout creditors for further austerity and reforms, although they have pledged to renegotiate some of the terms for the rescue loans. Samaras campaigned on promises to lower taxes, restart the economy and provide income boosts to low earners, large families, police and fighter pilots.
New Democracy and PASOK are also looking for an extension of at least two years in the deadlines for implementing fresh cutbacks worth a total €14.5 billion ($18.42 billion).
Democratic Left leader Fotis Kouvelis went a bit further Wednesday, saying that Greece should eventually "disengage" from the austerity commitments and "lift those measures that have literally bled society."
Greece has been dependent on the loans from other Eurozone countries and the International Monetary Fund since May 2010. In return, it has imposed deep spending cuts, slashed salaries and pensions, and repeatedly hiked taxes.
The measures have left the country struggling through a fifth year of recession, with unemployment spiraling to above 22 per cent and tens of thousands of businesses shutting down.
Earlier Wednesday, hundreds of poverty-stricken Greeks queued in a central Athens park for free vegetables. Cretan farmers handed out some 2,700 10-kilo packages of produce, in co-operation with the capital's municipal authorities.
Among the people lining up was Panayiota Sidera, 31, from Athens. She said she has been unemployed for two-and-a-half years and her husband is also out of a job. The couple is living on a €250 monthly disability pension and rent from an apartment they own, and has a €540-a-month loan installment to pay.
"That's my predicament," she said, adding that the food handout "is helping people, and I'm grateful."
"The government should have been doing this years ago," she said.
Zanias is to represent Greece at an upcoming meeting of Eurozone finance ministers.
The eurogroup talks "will be the first big battle on the revision of the bailout agreement, the creation of a framework that will allow us to move to positive growth and to combat unemployment which is the big problem of Greek society," Venizelos said earlier in the day.
In Sunday's vote — and the previous, inconclusive May 6 election — angry voters strongly favoured parties promising to end the hardship by tearing up Greece's pledges for continued austerity and reforms.
However, the anti-austerity standard bearer — the radical left Syriza party — finished a narrow second in Sunday's election that gave New Democracy 129 of Parliament's 300 seats.
A Syriza spokesman said the new government was based on the two parties — New Democracy and PASOK — responsible for Greece's austerity program, as they worked together in a previous coalition that secured the country's second bailout and a massive debt writedown earlier this year.
"I am not convinced that the government is able and prepared to fight for an effective renegotiation of the loan agreement," Panos Skourletis said.
Menelaos Hadjicostis and APTN producer Dalton Bennett in Athens contributedSuggest a correction