If you’re wondering whether electric buses are truly “green,” consider that electric buses are only as clean as the grid that charges them. Still, when it comes to greenhouse gas emissions, electric buses are already miles ahead of their competition.

Buses charged by electricity are responsible for fewer carbon emissions than conventional diesel buses in the U.S., according to a study by the Union of Concerned Scientists.

As municipalities and transit agencies pursue cleaner buses, they have a few options other than diesel: natural-gas-powered, diesel-electric hybrid or full electric.

Bus customers have to weigh several factors: upfront cost, total cost of ownership, tailpipe emissions, ability to get up hills and carbon emissions.

Critics of EV adoption efforts (or advocates for gas-powered buses) say that EVs aren’t so beneficial once the emissions from power production get factored in.

The researchers analyzed emissions from diesel- and natural-gas-powered buses — including the extraction, refining and delivery of the fuels, plus tailpipe emissions. For electricity emissions, they used Environmental Protection Agency power plant data from 2016, incorporating transmission losses and life cycle emissions from the fuels used in the plants.

Here’s what the group found: Across the vast majority of the nation, diesel buses would have to become at least twice as fuel-efficient to match the total greenhouse gas emissions of electric buses.

The Northeast, Northwest and Mid-Atlantic perform the best. In upstate New York, for instance, the grid’s even split of hydropower, nuclear and natural gas yields an electric bus so clean that it equates to a diesel bus running at 37.3 miles per gallon. An actual diesel bus gets 4.8 miles per gallon, according to Federal Transit Agency testing.

California does well with its high penetration of renewable power penetration, as does the hydro-powered Pacific Northwest. The Carolinas, with their ample adoption of solar power, rank highly as well.

The dirtiest region in which to charge an electric bus lies in the middle of the continent: Colorado, Kansas and Missouri, plus most of Michigan. The electricity in those states still beats the diesel reference case.

UCS has some skin in the game of vehicle fuel choice: The group developed a plan to cut U.S. oil consumption in half by 2035. That said, the bus study is really about crunching numbers from official sources and translating them into comparable terms.

It’s also important to note that cities and transit agencies can further clean up the electric transportation mix by procuring higher rates of clean energy than their utility currently offers.

The carbon emissions data may soon make its way into electric-bus sales pitches. The story could get even better: As long as the grid continues to decarbonize, through coal plant retirements and renewables additions, the cleanliness of electric buses will grow.

That directionality is not guaranteed everywhere. Retiring nuclear plants replaced by gas generation could affect regional emissions trends. But the bet on cleaner energy looks a lot better than the odds for doubling or tripling diesel bus efficiency.