ROME - Italian Prime Minister Silvio Berlusconi said on Tuesday he would resign after suffering a humiliating setback in parliament that showed a party revolt had stripped him of a majority.Berlusconi confirmed a statement from President Giorgio Napolitano that he would step down as soon as parliament passed urgent budget reforms demanded by European leaders after Italy was sucked into the epicenter of the euro zone debt crisis.RELATED:Greek PM won't lead new cabinet, unity deal not reachedThe votes in both houses of parliament are likely this month and they would spell the end of a 17-year dominance of Italy by the flamboyant billionaire media magnate.His failure to implement reforms fueled a party revolt and Berlusconi told his own Canale 5 television station that the only option was an early election. However, this could prolong the uncertainty that has sapped market confidence.Napolitano said he would now hold consultations on the formation of a new government. Markets and Napolitano himself are thought to favor a technocrat or national unity government.Berlusconi's government won a key budget vote after the opposition abstained on Tuesday but failed to secure a majority, obtaining only 308 votes in the 630-seat lower house, eight short of the 316 needed to be sure of passing legislation.Pier Luigi Bersani, the leader of the main opposition Democratic Party, said Italy ran a real risk of losing access to financial markets after political uncertainty pushed yields on government bonds towards a red line of 7 percent. "I ask you, Mr Prime Minister, with all my strength, to finally take account of the situation ... and resign," Bersani said immediately after the vote.Italy, considered too big to bail out, has replaced Greece as the main cause for concern in the euro zone's sovereign debt crisis.Italian leader had steadfastly refused to step downBerlusconi has been on the ropes for weeks, beset by a string of sex and legal scandals, political defeats and, most crucially, a loss of confidence on international markets.But the 75-year-old, who has dominated Italian politics for most of the past two decades, had steadfastly refused to step down until Tuesday's vote and battled until the last to win over rebels in his PDL party.The vote showed he had failed to stem the revolt and Berlusconi's bitterness was revealed by a photographer who caught the words "8 traitors" jotted down on his notepad in parliament after the result was read out by the speaker.The news that Berlusconi had finally agreed to resign came after European markets closed but the euro jumped against the dollar and US stocks edged up. Earlier, Berlusconi's key coalition ally Umberto Bossi, head of the devolutionist Northern League, said Berlusconi should be replaced by Angelino Alfano, secretary of the premier's PDL party.The League, and many members of the PDL, were believed to have wanted Berlusconi to make way for a new center-right government to restore the confidence of markets without handing power to a transitional administration.The center-left opposition said they had abstained to lay bare the weakness of Berlusconi's support, while allowing formal ratification of the 2010 budget.Interest rates on Italy's debt have soared to levels that are causing deep concern about whether the euro zone can survive if its third largest economy cannot service its debts.