Clean energy supporters in Massachusetts announced legislation Monday, backed by more than a quarter of the state legislature, committing Massachusetts to get 100 percent of its energy needs from clean and renewable sources by mid-century.

The legislation, introduced in the House of Representatives by Rep. Sean Garballey and Marjorie Decker and in the Senate by Sen. Jamie Eldridge, establishes targets for Massachusetts to meet its electricity needs from renewable energy by 2035 and all of its energy needs, including heating and transportation, from renewable sources by 2050.

"The supporters of this bill have joined the growing number of stakeholders and leaders who recognize the need for rapid transition to clean, renewable energy to tackle our environmental challenges," Rob Sargent said. "With a can-do attitude, powering our state entirely with clean, renewable energy is as feasible as it is necessary."

A combination of environmental concerns and declining costs for renewable energy have made it the "go-to" option for many communities and businesses, in part because it is pollution-free, but also because it requires no fuel costs. As a result, dozens of major corporations from Google to General Motors to Walmart have already committed to a complete shift to renewable energy. Similarly, dozens of local governments including San Diego, California, St. Petersburg, Florida and Georgetown, Texas, have plans to go 100 percent renewable.

"The federal government is moving backwards on clean energy. So, the states must lead," said S. David Freeman, a long-time utility executive at Los Angeles Department of Water and Power, the New York Power Authority and the Tennessee Valley Authority. "Massachusetts can show the way by enacting the 100 percent renewable bills and by so doing save consumers millions of dollars in the future with a free fuel energy supply."

Given the considerable resistance renewables are likely to face in Congress and the Trump administration, clean energy proponents are looking to state and local governments, businesses and institutions to ensure continued progress. In addition to the campaign in Massachusetts, Environment America and its partners are planning campaigns to get other states to go 100 percent renewable. And, today they will launch an effort to persuade America's colleges and universities to make similar commitments.

"Despite tremendous progress on renewable energy in the past decade, we've got much more to do and leaders in Washington who want to take us backward," Sargent said. "That's why we're counting on our local and state governments, along with businesses, colleges and universities and other institutions to lead the way by setting their sights on 100 percent renewable energy."