With ballots counted following a crucial regional election, Catalan separatist parties are on course to win an absolute parliamentary majority, with dismissed leader Carles Puigdemont declaring that the "Catalan Republic" had won the vote.
The three pro-independence parties are on course to win 70 of the 135 seats in parliament - two less than their previous tally of 72 seats in 2015.
The three parties which are clearly in favour of Catalonia remaining a part of Spain would capture 57 seats - far short of the 68 seats needed for an absolute majority.
Pro-unity party Ciudadanos, which was formed in 2006 to fight Catalan nationalists, is set to win 36 seats, up from 25.
Voter turnout hit a record high, soaring above 80%, as politicians from both camps portrayed the election as crucial for Catalonia's future.
The campaign has been marred by the surreal image of leading separatist candidates campaigning from jail or exile.
The election is likely to be followed by weeks of haggling to form a government.
Catalonia's separatist leader Carles Puigdemont is on track to regain the leadership of Spain's northeastern region following the vote.
Mr Puigdemont went on self-imposed exile in Brussels in October after conservative Prime Minister Mariano Rajoy sacked his regional government when they organised an illegal independence referendum and later proclaimed a Catalan republic.
Mr Puigdemont's 'Together for Catalonia' were seen winning 34 of those seats, ahead of two other separatist parties.
Voters who arrived just before polls closed were still allowed to cast their ballot, with long queues formed outside voting stations shortly after they opened this morning.
The election was held just two months after a failed independence bid, which triggered the country's worst crisis in decades.
The vote pitted leaders of the region's separatist movement against parties that want to remain in Spain.
Should the vote projection be confirmed, it would open a new, uncertain chapter and cast serious doubts over Spanish Prime Minister Mariano Rajoy's capacity to draw a line under the crisis.
Polls showed the separatist parties getting between 67-71 seats in the 135-seat assembly.
The unionist bloc would garner 55 to 62 seats while the local offshoot of anti-austerity party Podemos would get 7 to 8 seats, according to polls.
Mr Rajoy sacked Catalonia's previous government for holding the referendum and declaring independence.
He then called today's vote in the hopes of returning Catalonia to "normality" under a unionist government, or failing that, a separatist government acting within the Spanish and regional laws and not seeking a unilateral split.
A new separatist majority might further dampen investors' confidence in Catalonia, which by itself has an economy larger than that of Portugal and is a key driver of Spain's economic growth.
However, separatist leaders, who have campaigned while Spanish courts investigate them on allegations of rebellion for their roles in the 1 October referendum, have recently backed away from demands for unilateral secession.
Deposed Catalan President Carles Puigdemont has campaigned from self-imposed exile in Brussels and his former deputy and now rival candidate, Oriol Junqueras, has done so from behind bars at a prison outside Madrid.