When asked about his favorite energy-efficiency innovation, Binghamton, N.Y., Mayor Richard David answered, “LED lighting.” The mayor, who was speaking on a panel last month at the annual Energy Efficiency Forum in Washington, D.C., had recently wrapped up a $4 million project that replaced the city's roughly 7,000 streetlights with energy-efficient LED fixtures.

David is far from alone in admiring LEDs. Their remarkable efficiency has made them extremely popular among eco-advocates as well as cash-strapped municipalities looking to save on long-term costs. It’s estimated that about 10 percent of the country’s streetlights are now outfitted with light-emitting diodes. In the case of Binghamton, the new streetlights will reduce carbon dioxide emissions by 3 million pounds a year -- the equivalent of getting 301 cars off the road -- and will save the city $5.2 million in electricity and $1 million in maintenance costs over 15 years.

But by working to prevent one kind of pollution, cities have inadvertently exacerbated another: light pollution.

Binghamton’s new LED fixtures shine six to seven times brighter than traditional streetlights. According to the American Medical Association (AMA), the bright, white light cast off is bad for a person’s health and for the environment. In June, the AMA declared LED streetlights a public health risk. According to the group, the strong bluish tint, which appears white to the naked eye, interferes with the production of the hormone melatonin, causing sleep disorders in humans. Studies further suggest that excessive exposure to LED light at night increases the risk for obesity, diabetes, cardiovascular disease and cancer. LEDs also confuse nocturnal species, disrupt migratory birds and, according to scientists in the United Kingdom, could cause spring to come earlier -- or, at least, trick plants into thinking that spring is coming earlier.

But all LEDs aren’t a problem. Rather, it’s the type that’s the issue. Because they're less expensive, cities have generally opted to install “white” LEDs. That's the kind, says the AMA, that impacts sleeping patterns and makes it harder to see clearly because of glare. Instead, the AMA recommends adopting LEDs with a yellow tint.

The AMA’s statement last month already has one city reconsidering LEDs. Officials in Eugene, Ore., which just finished converting nearly 5,000 streetlights to LEDs, said they’ll review their program. Public Works spokesman Brian Richard told the local newspaper that while it’s “still too new for us to be able to make any decisions, we will evaluate the guidance statement and determine the best direction to proceed.”

Even before the AMA released its warning, cities were already running into protests from residents who felt LEDs were too bright. In 2014, only a month after installing white LED streetlights, Davis, Calif., spent hundreds of thousands of dollars switching to a warmer LED fixture after a loud outcry from residents.

Similarly, Phoenix is in the middle of outfitting all 90,000 of its streetlights with LEDs. But complaints from residents about the harsh, white lights led the city to conduct a survey that wrapped up last month. Phoenix now says it’ll consider installing yellow LEDs instead.

The AMA also recommends ensuring streetlights are directed downward and shielded. Right now, “a lot of [lighting] is unshielded, which means that it’s allowed to go in all directions, including up into the sky where it doesn’t do anybody any good,” said Paul Bogard, author of The End of Night: Searching for Natural Darkness in an Age of Artificial Light.

Several cities and states have laws that mandate how brightly a place should be lit and how it should be lit. Measures like those, as well as best practices and other resources on combating light pollution, are catalogued by the International Dark-Sky Association, which Bogard recommends as a valuable clearinghouse for any government interested in more information. “Light isn’t the problem," says Bogard. "It’s how we’re using it."