Barcelona city hall estimated 1.8 million people demonstrated there Thursday for Catalonia to vote on independence from Spain, but government officials put the figure at around half a million.
An official for the city hall, which is led by the region's nationalist CiU party, quoted the estimate to reporters after demonstrators formed a giant "V" to voice support for an independence vote planned for November 9.
The Spanish government delegation in Catalonia separately calculated the turnout at between 470,000 and 520,000, it said in a statement.
Fired up by Scotland's independence referendum, a sea of flag-waving Catalans thronged the streets of Barcelona, many clad in red and yellow shirts to mark Catalonia's national day, the Diada.
The commemoration, which marks the Spanish conquest of Catalonia in 1714, was more sensitive than ever this year.
"November 9 we will vote. November 9 we will win," read a banner at the head of Thursday's rally, which filled two converging central avenues in Barcelona.
"Nothing would thrill me more than for my first vote to be for the independence of Catalonia," said one demonstrator, 16-year-old Laura Sanchez Lora.
"Now more than ever, Catalonia needs a state that will defend its language, its culture and its economy," she said, waving a Catalan independence flag: red and white stripes plus a white star.
As the V-for-vote formed to the singing of a choir and cheers from the crowd, a girl at the head of the rally placed a paper in a symbolic ballot box.
Spain's national government has branded the November vote illegal and vowed to block it, but Catalonia's regional president Artur Mas has vowed to push on with the plan.
"If a nation such as Scotland can vote, why not Catalonia?" he said in an interview with AFP.
"If the Catalan population wants to vote on its future, it's practically impossible to stop that forever."
He has vowed to pass a regional law that he says will allow him to hold a "consultation" vote, but his efforts risk being thwarted by Spain's Constitutional Court.
The Diada marks what many in Catalonia see as the day they lost their autonomy: September 11, 1714, when Barcelona fell to Spanish and French forces in the War of the Spanish Succession.
Proud of their distinct Catalan language and culture, many of Catalonia's 7.5 million inhabitants feel short-changed by the national government in Madrid, which redistributes their taxes.
"Our culture, our language and our traditions must be respected and we have seen that in this state that is impossible," said Bernat Pi, a 24-year-old doctoral student, waving a Catalan flag and a blue and white Scottish Saltire one.
Catalonia formally declared itself a "nation" in 2006 but Spain's Constitutional Court later overruled that claim.
At the height of Spain's economic crisis in 2012, the country's Prime Minister Mariano Rajoy rejected Mas's demand to give Catalonia more power to raise and spend its own taxes.
Opponents of secession think cutting themselves off from Spain would be an economic disaster.
South of Barcelona in the town of Tarragona on Thursday, the Catalan Civil Society held a smaller rival gathering to denounce independence as a "dead end".
Catalonia accounts for a fifth of Spain's economy but it was hit hard by the financial crisis that began in 2008, fuelling a surge in calls for independence.
"It will not be easy because they will put lots of obstacles in our way, but I think we will manage it," said Lourdes Castellseguer, an 86-year-old woman leaning on a walker at Thursday's demo in Barcelona. "I hope I get to see it."