Spanish Prime Minister Pedro Sanchez's Socialists have won snap elections without the necessary majority to govern solo in a fragmented political landscape marked by the far-right's entry into parliament.
The results raise the spectre of another period of instability for Spain, with Mr Sanchez depending on alliances with hostile rivals in an environment that has soured since Catalonia's failed secession bid in 2017.
A significant development was the rise of the ultra-nationalist Vox party, which garnered just over 10% of the vote in a country that has had no far-right party to speak of since the death of dictator Francisco Franco in 1975.
Mr Sanchez's Socialist Party (PSOE) got 123 seats out of 350, or close to 29% of votes, which was short of an absolute majority, but much better than the 85 seats it got in 2016.
We need your consent to load this rte-player contentWe use rte-player to manage extra content that can set cookies on your device and collect data about your activity. Please review their details and accept them to load the content.Manage Preferences
"The Socialists have won the general election and with it the future has won and the past has lost," he told cheering supporters from the balcony of the party's headquarters in Madrid, claiming victory late yesterday.
The big loser was the conservative Popular Party (PP), which bagged 66 seats compared to 137 in the previous election that saw it govern Spain with a minority government.

Possible alliances
Mr Sanchez, who came to power in June after ousting conservative prime minister Mariano Rajoy in a no-confidence vote, could seek to forge alliances with far-left Podemos and smaller groupings like Catalan separatist parties, as he had done over the past ten months.
He could also try to cosy up to centre-right Ciudadanos, which won 57 seats. Together, they would form an absolute majority but voters from both parties would likely frown on such a move.
Read more
- Leftist bloc holds advantage in Spanish election
- Sanchez calls snap April election in Spain
- The return of the hard-right in Spain
Ciudadanos leader Albert Rivera built his campaign on disparaging Mr Sanchez, criticising his attempts to negotiate with Catalan separatist parties in a bid to ease a secession crisis in the northeastern region.
In an editorial today, Madrid daily El Mundo called on Mr Sanchez to "reach out to Rivera and consider forming a moderate government - which would undoubtedly go down well in Europe - to ensure the stability" of the country.
Far-right emergence
The crisis in Catalonia was precisely what fuelled Vox's meteoric rise from the outer margins of politics to the national scene, after gaining nearly 11% of votes in December regional polls in southern Andalusia.
Founded by Santiago Abascal, a disgruntled former PP member, it will now take 24 seats in the national parliament.

This is less than what opinion polls had predicted.
"I thought Vox would get way more votes, with this result Vox won't have any weight in parliament as no one supports them. We needed more seats," said Maria Bonilla Ortega, a 22-year-old philosophy student in central Madrid, a Spanish flag draped around her shoulders.
Mr Abascal was more optimistic: "We can tell Spain with complete calm that Vox has come to stay," he told cheering supporters.
After a tense campaign, voter turnout was high at 75.76%, up from 66.48% in 2016, election authorities said.
Catalonia shadow
With a strong stance against feminism and illegal immigration, Vox stood out with ultra-nationalist rhetoric advocating the "defence of the Spanish nation to the end" and a hard line against separatists in Catalonia.
The region in northeastern Spain was the scene of a secession attempt in 2017 that sparked the country's biggest political crisis in decades and caused major concern in Europe.
The issue has continued to cast a pall over Spanish politics.
Mr Sanchez was forced to call yesterday's elections after Catalan pro-independence members in the national parliament, angered at the trial of their leaders in Madrid, refused to give him the support he needed for his 2019 budget.
Right-wing parties for their part lambasted Mr Sanchez, at the head of a minority government, for talking to separatists who still govern the region, accusing him of cosying up to those who tried to break up Spain.
That controversy is likely to continue as two Catalan separatist parties gained even more seats in the national parliament than they did in 2016 - up to 22 from 17.
The five separatists elected are in jail and currently being tried at Spain's Supreme Court.
In a sign of the impact the crisis had on voters, Dolores Palomo, a 48-year-old domestic worker, said she had always voted for the socialists but cast her ballot for Ciudadanos this time at a polling station in Hospitalet de Llobregat, near Barcelona.
The reason? Sanchez "is a puppet of the separatists," she said.