Both teams could not be separated after 120 minutes of pulsating football that made a mockery of the claims that football should not be at the Olympics.
So after a 1-1 draw that had a heaving crowd at the Maracana go through a gamut of raw emotions it came down to the dreaded penalties - football's version of Russian roulette - against none other than the Germans who lose a shootout once every half a century or so.
Brazil were chasing their first Olympic gold, which is the only honour the 'auriverde' had not won.
The first eight penalties were successful and at 4-4 the tension among the 80,000 at the spiritual home of Brazilian football and scores of millions watching on television would have been unrelenting, unbearable, at breaking point.
The rising pressure must have got to Germany too because striker Nils Petersen saw his team's fifth penalty saved by Waverton so the stage was set for a fairytale finish.
Cometh the hour, cometh the man.
Up stepped Barcelona superstar Neymar for the fifth kick that would give Brazil their first gold medal.
Would he be a hero or a villain?
It is anyone's guess what must have gone through Neymar's mind as he walked up to the spot to take the kick that could give him legendary status in a country that has given us Ademir, Garrincha, Pele, Rivelinho, Jairzinho, Romario, Rivaldo, Ronaldinho, Carlos Alberto and Ronaldo.
If Neymar had any jangling nerves he certainly did not show it because he took his kick with an assurance of a seasoned pro and it landed in the back of Germany's net.
The explosion of joy and relief that greeted Neymar's history-making penalty would have reverberated around the whole country which is still reeling from one of its darkest moments that took place two years ago.
In the 2014 FIFA World Cup the Brazilians suffered one of their most humiliating defeats when they crashed 7-1 to Germany in an extraordinary semi-final that sent shock waves around the globe and threw the national game into complete disarray.
Brazil's collective state of mind as a proud football nation was at its lowest ebb and in deep disbelief and the after-shocks were still being felt two months go when Carlos Dunga's team were unceremoniously bundled out of the Copa America at the group stage.
But Brazil's elusive gold could well give their game a much-needed fillip after that unexpected 'Mineirazo' disaster in Belo Horizonte that was the culmination of years of gradual decline.
Olympic gold should give the Brazilian national team the confidence, the belief and the swagger to once again become a highly respected and feared football country with a style of football to match.
"This is one of the best things that have happened in my life. That's it," Neymar said.
"I can't begin to describe what I feel. I have fulfilled my dream and to have done it in my home country makes me very proud."
Brazilian football has its weaknesses and plenty of critics but it remains the essence of the beautiful game and it needs to be a genuine force in world football as much as the sport needs Brazil to be strong.
And Neymar's heroics - which included a peach of a free-kick in the first half that went in off the bar - that helped Brazil win gold medal not only served as a redemption and a form of liberation but also gained revenge on the Germans, who had the temerity to cause the home side such angst and despair two years ago.
It will surprise no one if Brazilian football gets a spring in its step as it seeks to take its rightful place among the game's elite in Russia in 2018 and provide the kind of football it is famous for.
Brazilian-born former Adelaide United fullback Cassio said the Olympic gold was the best possible medicine for the country's ailing game.
"It was a wonderful result, not just for the players but also for the whole population," Cassio said.
"And what made it even more significant and satisfying was the fact that the gold medal came after beating the Germans."
Brazil coach Rogerio Micale said after the final that "Brazilian football is not dead".
Never a truer word has been spoken.
Maracana 2016 may well be the point where Brazilian football rediscovered itself.
And football would be so much better for it.