The whole of Spain erupted with joy as the national side reached the FIFA World Cup™ final for the first time ever with a 1-0 win over Germany – and the fiesta looked set to last well into the night.

"It's over! We are in the final of the World Cup! It's historic, what joy!" shouted a commentator from the television channel La Cuatro as the final whistle went. A cacophony of firecrackers, vuvuzelas, car horns and cheers rang out across Madrid, where Spanish red and gold flags adorn balconies, roofs and bars.

Thousands of ecstatic fans sang and waved flags outside Real Madrid's Santiago Bernabeu stadium where the match was broadcast on giant screens. The crowd shouted "Yes, yes, yes, this year, yes!" and "I am Spanish, Spanish, Spanish!" to celebrate the win, which takes Spain into the final against the Netherlands on Sunday.

"We're euphoric, we deserved to win," said Julia, 17. Spain "dominated the match and in the second half the German team was already tired, and with the changes we made we were fresher," said Tomas Vasquez, a 41-year-old father who was watching the game with his son.

Carles Puyol's 73rd-minute winning goal was greeted with red smoke from firecrackers. The city was earlier gripped with excitement and anticipation ahead of what sports newspaper AS said was "the match of our lives". The streets were empty ahead of the game as residents rushed home or into bars to watch the game.

Police also set up barriers around the fountain in the Spanish capital's Plaza Cibeles, where Real Madrid fans traditionally celebrate their victories. Almost all towns and cities throughout the country installed giant screens for people to watch the match.

One notable exception was in Barcelona, the capital of the nationalist-minded region of Catalonia, even though seven players in Spain's starting line-up for Wednesday's game are from the Barcelona team. But while most people in Spain were ecstatic, one corner of the country was in despair, as tens of thousands of German tourists in a Majorcan beach resort were left with broken hearts.

Cries of "Nein!" (No!) erupted throughout Playa de Palma, a traditionally German resort in the Balearic island, as Puyol scored. But, after the final whistle, glum faces and a few moments of stunned silence were quickly followed by music, including a German version of "Viva Espana!", fireworks and more glasses of beer.

"We lost to Spain in Euro 2008, now we've lost to them in the World Cup. Twice in important matches is too much," complained Judith, an 18-year-old German tourist in the Deutsche Eck (German Corner) bar and restaurant. "Now we have to at least beat Uruguay for third place," she said, a garland in Germany's red, yellow and black colours round her neck. "If we'd had (suspended player Thomas) Muller, we wouldn't have lost," said her boyfriend Pierre, also 18, wrapped in a German flag.

In sweltering heat, Germans crammed into overflowing bars and restaurants along the Playa de Palma beach to watch the match. Majorca is nicknamed 'Germany's 17th Land' because of the millions of tourists from that country who visit every year.