RIO DE JANEIRO — After 31 days, 63 games and 170 goals, this World Cup finally will be decided Sunday in the tournament’s most compelling matchup.

Over the last month, players have had their shoulders bitten and their backs broken. Unsung players such as Colombia’s James Rodriguez and Costa Rican goalkeeper Keylor Navas have stepped up, and hugely overrated teams — you know who you are, Portugal and Brazil — collapsed.

It has been a World Cup of farce and tragedy, drama and intrigue. How fitting, then, that the final should feature the World Cup’s best team versus the world’s best player. And both will be chasing more than just a title. They will also be playing for their place in history.

For Germany, the tournament’s best team, the final is an opportunity to erase two decades of frustration. The Germans, the only team to reach the semifinals in four consecutive World Cups, haven’t won a championship since 1990, the country’s longest title drought since World War II.

Save 75% on a Digital Subscription Today

For Argentina’s Lionel Messi, the world’s best player, the final is a chance to fill in the only missing gap on an otherwise unparalleled résumé.

It’s the ultimate team versus the ultimate individual for soccer’s ultimate prize. And for both, a victory would also erase some painful history.

Germany has won a record 20 World Cup games since 2002, but none in a final. Sunday’s result, then, will go a long way toward deciding if this era in German soccer will be remembered as a dynasty or a disappointment.

The game is also a referendum on the decade-long remake of German soccer. Under former coach Jurgen Klinsmann and Klinsmann’s hand-picked successor, Joachim Loew, the German approach has changed from a plodding, physical one to a fast-paced attacking style.

And though that has made the German game more exciting to watch, it hasn’t paid off with any major trophies. Yet midfielder Bastian Schweinsteiger, one of Klinsmann’s first recruits, said the pressure of Germany’s failures doesn’t weigh heavily on this team.

“I don’t think that we have any pressure,” he said. “We have a lot of players who have played finals at the top level. We know how to deal with the situation.”

Then there’s the fact a victory would make Germany the first European team to win a World Cup in the Americas, which Loew said is not an insignificant milestone.

But Messi and Argentina have a chance to make history too. Less than a month past his 27th birthday, Messi has won six Spanish league titles, three Champions League titles and two club world championships. In 2012, he scored a record 91 goals in a calendar year. And he’s the best-paid player on the planet and the only man in history to win four consecutive world player-of-the-year awards.

But without a World Cup he’ll never be able to claim the one title he most desires: greatest player of all time.