ROME (Reuters) - Italy’s anti-establishment parties revived coalition plans on Thursday, ending three months of political turmoil by announcing a government that promises to increase spending, challenge European Union fiscal rules and crack down on immigration.

The coalition deal, following inconclusive elections in March, removes the risk of a repeat vote, a prospect that had sparked a big selloff in Italian financial markets this week.

The leaders of the right-wing League and the 5-Star Movement patched up their alliance after agreeing to substitute a eurosceptic they had initially proposed as economy minister, a nomination that had been rejected by the head of state.

“All the conditions have been fulfilled for a political, 5-Star and League government,” 5-Star chief Luigi Di Maio and League leader Matteo Salvini said in a joint statement after several hours of talks in central Rome.

Just a few hours later their chosen prime minister Giuseppe Conte, a little-known law professor who belongs to neither party and has not been elected, presented his list of ministers after receiving his second mandate in eight days.

“We will work with determination to improve the quality of life of all Italians,” Conte, who is close to 5-Star, told reporters at the presidential palace after meeting the head of state Sergio Mattarella.

His ministers will be sworn in on Friday before the government faces votes of confidence in both houses next week.

The deal followed an extraordinary few days in which Di Maio called for Mattarella to be impeached, Conte and another prime minister-designate were tasked to form a government and failed, before Conte was reinstated on Thursday evening.

Rome resident Vincenza Cariano summed up the exasperated mood on the street: “I can’t stand it anymore. The country needs certainties, security and equilibrium.”

The breakthrough came after the League and 5-Star agreed to drop economist Paolo Savona as their choice for economy minister. Savona, an 81-year-old economist, had said previously that Italy should have a contingency plan to abandon the euro.

He will be substituted by economics professor Giovanni Tria, another little-known figure.

Savona will be in government as European affairs minister, a less powerful role but one which will still allow him to negotiate with Brussels and speak on EU issues.

No sooner had the coalition deal been announced than friction flared with Brussels over remarks by European Commission chief Jean-Claude Juncker about Italy’s impoverished south.

Slideshow ( 12 images )

MARKET RECOVERY

Global financial markets have been recovering over the past two days after tumbling on the spectre of repeat elections dominated by debate over Italy’s future in the euro zone.

Italy, with debts totalling more than 130 percent of its economic output, is the most heavily indebted euro zone nation after Greece and is often described as “too big to fail”.

Slideshow ( 12 images )

Though investors were relieved to avoid repeat elections, which they feared could have become a de facto referendum on the euro, they are now likely to refocus on the big spending plans of the League and 5-Star, which would add to its debts.

The coalition has also said, in a joint policy manifesto signed during their first attempt at a union, that they will push the European Union to review the bloc’s fiscal rules, which Salvini says have “enslaved” Italians.

The parties’ new economics minister-designate, Tria, has been critical of the EU’s economic governance, but unlike Savona he has not advocated a “plan B” for possibly exiting the euro.

In recent articles, Tria has called for a change in the EU’s fiscal rules to allow public investments to help growth and, like many mainstream economists, has criticised Germany’s persistently large current account surplus.

“Maybe finally we have made it, after so many obstacles, attacks, threats and lies,” Salvini said on Facebook shortly after the deal was announced.

Salvini will be the interior minister and Di Maio will take a powerful, newly-created joint ministry made up of the labour and industry portfolios.

Both leaders will also be deputy prime ministers and many commentators have forecast that Conte will have a tough time proving he can be more than a puppet in the hands of his powerful political sponsors.

Salvini has promised as minister to ramp up deportations of irregular immigrants and to revamp the country’s asylum system.

Enzo Moavero, a former EU affairs minister under the technocratic government of Mario Monti, will be foreign minister.

After the first coalition attempt failed, President Mattarella named former International Monetary Fund official Carlo Cottarelli to form a stop-gap government of experts to lead the country to elections no sooner than September.

But Cottarelli failed to present a cabinet and received no support from any of the major parties. On Thursday, he formally gave up his mandate.