Ballot box in Spain
An electoral observer (left) of the Socialist party holds a ballot box while electoral members try to reach a ballot as they count them after Spain's general election at a polling station in Ronda, June 26, 2016. REUTERS/Jon Nazca

Support for Spain's conservative People's Party (PP) surged in Sunday's general election, preliminary results showed, as voters opted for the status quo just days after Britons' shock decision to leave the European Union.

The jump in support for the party of caretaker Prime Minister Mariano Rajoy reversed a trend to back startup parties that have channeled resentment toward the establishment after an economic crisis and a series of corruption scandals.

Support stagnated or fell for the two newcomers, anti-austerity Podemos and liberal Ciudadanos, which have lifted their share of the vote in recent years to challenge the two-party system that has dominated politics for four decades.

"These are not good results, they are not what we expected," said Inigo Errejon, No. 2 at Podemos, the anti-austerity party that had been tipped to play a central role in the formation of a government after the vote.

"They are not good for Unidos Podemos and we don't think they're good for Spain because they reverse the move for political change."

The PP looked set to win 137 seats, up from 123 in a previous election in December, with 95 percent of the votes counted, still short of the 176 needed for an outright majority, perhaps heralding weeks of talks to form a coalition.

After six months of bickering, parties have pledged to reach a deal quickly this time, although the results may also produce a new stalemate as the only clear majority possible would be an alliance between the PP and the Socialists. The Socialists have said they were not ready to consider such an option.

The Socialist party was set to win 85 seats, down from the 90 it won in the December election.

Unidos Podemos ("Together We Can"), a grouping of several leftist parties led by Podemos, was set to get 71 seats, the same as in December, and Ciudadanos 32, down from 40.

Spain's biggest-selling newspaper, El Pais, on Sunday urged politicians to put aside their differences and form a government quickly given increased global uncertainty in the wake of Britain's vote to leave the European Union.

"Now is not the time for messing about or egotism," the paper wrote in an editorial. "The only priority should be the urgent need to form a government with the ability to govern."