The Copa América can start on Sunday.
The Supreme Court in Brazil decided on Friday not to cancel the championship of South American countries despite the risks related to the corona virus.
The Supreme Court considered the issue in response to protests by activist groups, who believe that organizing the Copa América is not responsible because of the corona pandemic.
Brazil is one of the countries in the world hardest hit by the virus, with hundreds of thousands of deaths.
Despite the protests, a majority of the eleven judges decided that the Copa América can continue.
"The authorities must draw up health protocols and ensure that they are followed to prevent a 'Copavirus' with new infections and new virus variants," the ruling reads.
It had been uncertain for weeks whether the Copa América could continue.
The tournament was originally going to be hosted by Colombia and Argentina, but Colombia was dropped as the host country due to political unrest.
More than a week later, Argentina also withdrew due to the worrying corona figures in the country.
Brazil defends title in its own country
So now the Copa América is played in Brazil for the second consecutive edition.
The host country took the title two years ago by beating the surprising finalist Peru.
Defending champion Brazil starts the tournament on Sunday evening with a game against Venezuela.
There are a total of two groups with five countries each.
Argentina, Bolivia, Uruguay, Chile and Paraguay form a group, as do Brazil, Venezuela, Colombia, Ecuador and Peru.
The top four teams qualify for the quarter-finals.
Initially, Australia and Qatar were also supposed to participate in the Copa América, but those countries withdrew at the beginning of this year due to the busy schedule.
In recent years, it has been customary for countries from other parts of the world to receive an invitation to the tournament in South America.