The Park, which housed the aquatic complex, the tennis courts, the velodrome, and three arenas used for sports that included fencing, handball and basketball, has been used only sporadically for concerts and other events since the games ended in August 2016.
The federal judge ruled that “any events in the Olympic installations” be prohibited until fire authorities provide authorizations that “attest to the safety of the areas.”
“The panorama, made up of areas progressively damaged from a lack of care and the presence of thousands of people, are ready for tragedies,” the ruling said.
The area teemed with visitors during the 2016 games but have since been abandoned by local authorities, the judge added.
Local media published pictures of missing manhole covers and paths with crooked paving stones overtaken by weeds.
In a statement sent to Reuters, the federal government said it already had safety certificates good until March 2020 and would appeal the decision.
The 2016 summer games were the first to be held in South America.
Officials considered the games a success, but many Rio residents complain authorities overspent on facilities and have not kept them in good condition or let the local population take advantage of them.
(Reporting by Andrew Downie; Editing by Bill Berkrot)