At one polling place in Barcelona, an officer of the regional police walked in, asked who was in charge, and when many in the crowd responded, “We all are,” thanked them, smiled and walked out.
“This is like D-Day in Normandy, nobody knows what will happen, but everyone has prepared for it,” said Celia Vélez, 21, who spent the night in a high school in Barcelona.
Tractors had been used to block police access to some rural municipalities. In other places, residents simply removed the doors of polling stations to ensure the police couldn’t bolt them on Sunday.
Madrid has sent thousands of police officers from other parts of Spain, who have been garrisoned in ships off Barcelona and other major ports, but they did not interfere with the early efforts by civilians to go through with the vote.
Catalans are voting not only without backing from Madrid, but also without any sign of support from the European Union or other important players in the international community, and in makeshift conditions, using a disputed census as the voting list.
They are relying on privately printed ballots, after millions of them were seized earlier this month by the police. A few outsiders had traveled here from other countries to act as observers, saying they wanted to make sure that the police did not use force against voters.
“Every person in the world should have the right to decide their present and future, which of course means the right to vote,” said Andrea Favaro, a lawyer from Venice, who waited inside a polling station early on Sunday. He said he had closely followed a similar situation at home, where the Veneto region held a nonbinding ballot on independence from Italy.
The government of Catalonia, an autonomous region in northeastern Spain, passed laws last month to approve the referendum, and Spain’s prime minister, Mariano Rajoy, warned that Spain would use all possible means to stop it.
Recent opinion polls suggest that slightly less than half of Catalonia’s 7.5 million people support separation from Spain, but separatist parties won a majority in the region’s Parliament in 2015 and their influence has grown.
Many say Catalonia would face a perilous and uncertain future outside Spain, the market for most of the region’s goods, and would not be assured of being readmitted to the European Union.
Others complained that the thrust for independence had deepened divisions within the region, whose vibrant economy has attracted families from inside and outside Spain.
Olga Noheda, a doctor in Centelles, said one of her patients, an older man, began crying in her examination room, and explained that his granddaughter had begun expressing dislike for Spaniards.
“He was very sad, because he didn’t understand where it all came from,” she said. “He migrated to Catalonia many years ago, from Seville, and he was wondering if his granddaughter was aware that he was a Spaniard.”
In the days leading up to the vote, school principals had received letters threatening them with sedition charges, which carry a 15-year prison term, if they willingly allowed their buildings to be used as polling stations.
City officials were told they would face criminal charges for misusing public funds. In one city, the local newspaper editor discovered he faced a criminal complaint after he printed a list of schools that would be holding votes.
Ten days ago, Spanish police detained a dozen officials of Catalan’s regional government, including its secretary general of economic affairs.
In March, the region’s former leader was fined 36,500 euros, nearly $39,000, and banned from holding public office for organizing a similar referendum in defiance of a court order in 2014.
But Sunday’s vote has left the Spanish premier in a bind, forced to choose between detaining large crowds of civilians — images that would be immediately beamed worldwide via social media — or allowing the vote to proceed, an acknowledgment that he could not control the region.
One serious vulnerability, for the Spanish government, is that the primary police force in Catalonia is an autonomous Catalan body known as the Mossos d’Esquadra, and its leaders have signaled that they would not use force on voters.
On Sunday morning, at a site in Barcelona, a Mossos officer said his orders were to intervene only if there was a risk of violence.
“If the police leadership really want to get 500 people out of this place, let them come and do it themselves,” said the officer, who spoke on condition of anonymity according to protocol. “Good luck to them.”
Throughout the weekend, the polling sites had a festival atmosphere, preparing vast pans of paella and offering instruction in yoga and drumming.
“Today I am totally amazed, floating, very happy, you cannot believe,” said Carme Calderer Torres-Casana, 66, who had traveled from Minneapolis, where she lives, to her hometown Berga, near the border with France. “Everyone has unforgettable days that mark your life, and today, for me, is one of those days.”