San Francisco passed a similar ban in 2014 on the sale of plastic water bottles 21 ounces or smaller in public spaces, including municipal buildings, streets and parks. David Chiu, a Democratic state legislator who championed the ban as president of the city’s board of supervisors, said it has helped change the culture. People now carry around their favorite refillable water bottle. Concerts and festivals set up refillable water stations instead of selling plastic bottles by the caseload. “While it was controversial when it was proposed, in hindsight today, it has been a no-brainer,” he said. “I think everyone has adjusted to it.”

The residents of Concord had gone even further in 2012, when they voted to ban the sale of one-liter or smaller plastic water bottles anywhere within town limits. As an alternative, public drinking fountains and water filling stations have been expanded and upgraded. Though plastic bottles still show up in recycling bins, “It’s definitely a lot less than you would see in other towns,” said Erin Stevens, Concord’s public information officer.

Bottled water sales were also eliminated in some national parks, including the Grand Canyon and Zion, under a 2011 National Park Service policy. But in August, the Trump administration ended that ban following years of opposition by the bottled water industry, which argued that it removed water from the shelves while leaving unhealthy sweetened drinks.

Councilman Kallos said the Trump decision spurred him to action. He said he has wanted to ban disposable plastic water bottles since trying to buy one himself while visiting San Francisco several years ago and being told he could not. So he bought a reusable bottle to tote around — something he now does in New York.

“You see plastic bottles everywhere,” he said. “It makes New York look like a dump and we can do better.”

This is not the first time that New York has taken a stand against plastic bottles. In 2008, the office of the City Council speaker, Christine C. Quinn, stopped buying bottled water for Council offices. A 2009 state executive order barred state agencies from buying bottled water, to save taxpayer dollars and improve the environment.