MADRID (AFP) - Spaniards voted Sunday in what is expected to be one of the most closely fought contests in the country's modern history as two dynamic new parties take on long-established political giants.

The general election caps off a year of electoral change in southern Europe after far-left party Syriza was swept to power in Greece in January and a coalition of leftist parties in Portugal pooled their votes in parliament to unseat the conservative government after an inconclusive election in October.

Spain has been dominated for more than three decades by the conservative Popular Party and the main opposition Socialists, who have alternated running the government.

But this time around many voters are expected to cast their ballots for two upstart parties vying for change -- the centrist Ciudadanos and the anti-austerity Podemos, a close Syriza ally.

Ciudadanos leader Albert Rivera said Spain "was on the threshold (of) a new era" after he cast his ballot in L'Hospitalet de Llobregat in the northeast.

Polls predict Prime Minister Mariano Rajoy's Popular Party (PP) will win the largest share of the vote but not enough to retain its absolute majority in parliament.

Such a result would force it to form an uneasy alliance with another political grouping or attempt to rule as a minority government.

And all bets are off regarding who will come second in the legislative elections, as the Socialists could end up neck-and-neck with Ciudadanos and Podemos, which would give these new parties unprecedented influence on the political scene.

- 'Forgotten about us' -

Rajoy appealed for a high turnout as he cast his ballot in Madrid.

"What we all want is that the greatest number of people take part in the vote. It is an important decision," he said.

The government said that at 6:00 pm (1700 GMT) turnout stood at 58.36 percent percent, 0.71 percentage points higher than at the same time in the last such elections in 2011.

Sky-high unemployment, inequality, corruption and an ever-rising separatist drive in the northeastern region of Catalonia are just some of the issues at stake in a country deeply scarred by a financial crisis.

Story continues

"The PP and the Socialists became complacent and they have forgotten about us. We have to give the new parties a chance," said grey-haired truck driver Francisco Perez, 53, after voting for Podemos in L'Hospitalet de Llobregat.

Ana Salazar, head of research and strategy at consultants Red Lines, says the shakeup in Spanish politics started when Podemos emerged in 2014 on the back of an "Indignados" movement fed up with austerity-triggered inequality and corruption.

Then came Ciudadanos, which was formed in 2006 in Catalonia but only truly emerged nationwide last year.

"Now we have... the old versus the new," said Salazar.

Rajoy, the austere, grey-bearded 60-year-old premier, has positioned himself as a safe pair of hands who dragged the country away from economic collapse when he took power in 2011 and put it on the path of recovery.

After years of recession, the government predicts the economy will grow 3.3 percent this year -- to the envy of many of its European neighbours.

But unemployment remains stubbornly high at more than 21 percent, and Rajoy's rivals point to glaring inequalities brought on by his drastic spending cuts, tax rises and health reforms.

- 'Reasonable change' -

Socialist chief Pedro Sanchez, the 43-year-old economist who only last year took over a party still reeling from its 2011 defeat, has promised to reinstate the rights of workers and immigrants he says have been trampled on.

Ciudadanos chief Rivera, who at 36 is the youngest of the four main party leaders, wants "reasonable change" and pledges to do away with precarity in the workplace.

But the question mark of the elections remains Podemos, whose pony-tailed, 37-year-old leader Pablo Iglesias is now a household name.

Seen as running out of steam just months ago, the party appears to be gaining ground again thanks to Iglesias's down-to-earth appeal and his move away from the more radical, far-left ideals Podemos once espoused.

The revival has been so pronounced that polls suggest Podemos may even replace the longstanding Socialists as the country's main left-wing party.

"The new parties were needed -- it's the end of bipartisanship," said Silverio Ares, an unemployed 62-year-old, after voting in the northwestern city of A Coruna.