The polling stations were makeshift, the election officers all volunteers and the whole process suspended twice for being potentially illegal, but Catalonia's much-disputed unofficial referendum on independence from Spain finally went ahead.
More than two million votes were cast of the approximately five million on the electoral roll and abroad.
"We have voted and whatever happens we have won," Carme Forcadell, the president of ANC, one of the largest pro-nationalist organisations, said.
The fact all the 1317 polling stations, manned by 40,900 volunteers, had opened across Catalonia "already makes this a success", she said.
The ballot was held amid strong opposition from the Spanish Government. Prime Minister Mariano Rajoy had said "this is no referendum or consultation and will have no effect", adding "whilst I'm in charge, nothing will threaten Spain's unity".