Billed as the world's richest, the lottery dishes out some euro2.52 billion ($3.29 billion) to winners across the nation.
The top prize - dubbed "El Gordo" (The Fat One) - was split among the holders of tickets bearing the number 58268. The number appeared on 1,800 tickets, giving winners euro400,000 for their euro20 ticket.
The state lottery agency said all 1,800 tickets with that number were sold in the town of Granen, located in the arid and barren northeastern Los Monegros area.
The news brought the town's residents out onto the street to dance, sing, hug each other and spray sparkling wine all over.
"It's brilliant!" Pilar Azagra, who runs the town's lottery store, told Spanish National Television. She appeared a bit stunned.
"I haven't had time to react, the number came out and then people started flocking to the shop," she said, adding that many in her family had bought euro20 tickets.
Azagra said the windfall was more than welcome as several companies in Granen had closed because of the economic crisis forcing many residents to seek employment in neighboring towns and cities.
Spain is struggling to emerge from a near two-year recession that has left it with a eurozone-high 21.5 percent unemployment rate.
The Gordo lottery aims for a share-the-wealth system, rather than a single jackpot, and thousands of numbers yield at least some kind of return. Lots of people chip in together and buy shares of several or many tickets, meaning it is common for multiple prizes to go to the same town.
Other lotteries have larger individual top prizes but El Gordo is ranked as the world's richest for the total sum paid out.
The winning number was picked and announced by pupils of Madrid's Saint Ildefonso School in a nationally televised draw.
Since it began in 1812, the Dec. 22 lottery has become a favorite holiday tradition. This year, it sold an estimated euro2.7 billion in tickets and the state lottery agency estimated per-capita spending of about euro70.
Spain holds another big lottery Jan. 6 to mark the Feast of the Epiphany. It is known as "El Nino" (The Child), in reference to the baby Jesus.