Alerted by scientists, the European Commission, which oversees the management of fish stocks in European waters, warned of "a rapid decline" in cod stock "if no action is taken".
"We must act urgently to rebuild the stock, both in the interests of fish stocks and fishermen," said European Fisheries Commissioner Karmenu Vella in a statement.
The ban will last until December 31, the EU said.
The commission acknowledged overfishing was not the only factor threatening Baltic cod, and warned of environmental factors "including a lack of salinity, too high water temperatures and too little oxygen, as well as parasite infestation."
However, the commission said this "should not be taken as an excuse for not acting upon the factor we fully control and which over the decades has contributed to the current situation -- fisheries."
Europeche, which represents the interests of the EU fishing industry, severely criticized the ban, arguing for a "significant" reduction in quotas, "which would have taken into account both the survival of the species and the fishing fleet".
The total allowable catch for Eastern Baltic cod, or fishing quota, has been reduced each year since 2014 to just over 24,000 tons in 2019.
Still, the Commission warned that "fishermen have only used between 40 and 60 percent of these quotas in recent years ... probably because of the insufficient quantity of fish of commercial size."
According to Commission figures, "more than 7,000 fishing vessels from eight member states catch Eastern Baltic cod, including 182 vessels from Lithuania and Poland that depend on this stock for more than 50 percent of their catches".
Inārijs Voits, the head of an association representing fishers in Latvia, earlier estimated that five out of 24 fishing companies could be closed in response to the ban; however, fishers can apply for compensation in response to the ban.