New York City announced Thursday that as of this summer, those plastic foam containers (along with those plastic foam cups, plates and the like) are going to be banned. Vanquished.

This is not going to happen overnight, of course, because there are a lot of these containers, made of a plastic resin known as expanded polystyrene, floating around New York. How many? Well, the city collected about 28,500 tons — repeat: 28,500 tons — of expanded polystyrene last year. About 90 percent of that was from food cups, containers and the like. In other words, that’s roughly one ton of these cups and containers for every 327 residents.

The New York City Council passed a law in December 2013, during the final weeks of Mayor Michael R. Bloomberg’s time in office, banning these containers unless they were deemed to be recyclable. The city’s sanitation department had until Jan. 1, 2015, to figure out if they could be recycled. On Dec. 31, 2014, Sanitation Commissioner Kathryn Garcia sent a letter to New York Mayor Bill de Blasio concluding that there is no way to properly recycle these polystyrene materials.

“These products cause real environmental harm and have no place in New York City,” de Blasio said in a statement Thursday. “We have better options, better alternatives, and if more cities across the country follow our lead and institute similar bans, those alternatives will soon become more plentiful and will cost less.”

As a result, these kinds of containers cannot be used or sold by restaurants, food carts, cafes, delis or any other place as of July 1. (There will be some exceptions for nonprofits and small businesses.) Also, businesses in New York aren’t supposed to sell those packaging peanuts that show up in your packages. There won’t be any fines until the beginning of 2016, so until then businesses will get warnings if they violate the law.

The New York ban was opposed by outfits like Dart Container Corporation and the American Chemistry Council, a trade group that funded a study estimating that it would cost businesses in the city more than $90 million to replace the existing foam.

But this move brings New York, the country’s biggest city, in line with dozens of other cities that have enacted similar bans for being environmentally unsound. Vendors in San Francisco are banned from preparing or serving food using such containers. Minneapolis banned the containers last year (again). Seattle banned these foam containers in 2009, and if a restaurant in the city uses one of these containers they could be finned up to $250. They will also be banned next year in the District of Columbia under a law signed by then-D.C. Mayor Vincent C. Gray.

A change like this matters, because New York is New York, and because if the change can be made there despite the sheer number of containers involved (again: 28,500 tons), it could affect how quickly other cities may follow suit.

Here is one thing these containers are not: Styrofoam. Sorry, STYROFOAM™, which is made by Dow Chemical, a company that would really like everyone to stop calling these containers Styrofoam, because the material is not actually used for food or beverage containers.