CNN  — 

Defending Olympic champion Brazil defeated Germany on Thursday in what was a rematch of the 2016 Rio men’s football final.

Striker Richarlison scored a stunning first-half hat-trick as Brazil beat Germany 4-2 in their opening game of the 2020 Summer Games in Japan.

Brazil also got the better of Germany in the fixture five years ago on home soil, winning in a dramatic penalty shootout to claim gold medal.

Thursdays game was played at the International Stadium in Yokohama – the same venue where Brazil beat Germany in the 2002 World Cup final.

Everton striker Richarlison’s hat-trick within the opening 30 minutes had Brazil well on its way to victory again, although second half goals from Nadiem Amiri and Ragnar Ache made it 3-2 and a nervy finish.

However a late goal from Bayer Leverkusen striker Paulinho capped off the victory and gave Brazil a vital opening three points.

Richarlison (#10) scores Brazil's third goal during the men's first round Group D match against Germany during the Tokyo 2020 Olympic Games at the International Stadium Yokohama on July 22, 2021 in Yokohama, Tokyo, Japan. .

READ: Mexico thrashes France and Spain held

Elsewhere on Thursday, hosts Japan go off to a winning start defeating South Africa 1-0.

South Africa had been depleted by Covid-19 infections after two players and a video analyst tested positive for Covid-19 in Tokyo on Sunday.

Subsequently 18 players were identified as close contacts and were forced to isolate in their respective rooms in the Tokyo Olympic Village.

A squad of 17 South Africa players did, though, pass pre-game Covid-19 protocols allowing for Thursday’s game to take place at the Tokyo Stadium.

Visit CNN.com/sport for more news, features, and videos

There were also several surprises in the men’s tournament with none of Spain, France or Argentina winning their games.

Mexico stunned France 4-1, Australia upset Argentina 2-0 and Spain, the last European men’s team to claim gold in 1992, were held to a goalless draw by Egypt.