For 50 years, the state of California has led the United States when it comes to renewable energy and electric cars.
The state features many programs to incentivize electric-car ownership, and 29 percent of the state's 2016 energy production came from solar, wind, and other renewable power sources.
California is now preparing for a future in which energy production relies solely on renewable energy sources—one where coal, natural gas, and other fossil fuels have no role.
DON'T MISS: CA should use VW mitigation funds for cleaner diesel trucks to cut NOx: diesel lobbying group
A recent piece of legislation, California Senate Bill 100, calls for the state to obtain 60 percent of its energy production from renewable sources by 2030.
When that level was reached, regulators would then have to plan for the phaseout of fossil-fuel power plants by the year 2045, according to The Los Angeles Times.
By 2045, in other words, California's entire power grid would be kept online solely on renewable energy, and likely some significant energy storage as well.
Tesla and SolarCity Ta'u renewable energy project screenshot
It's an ambitious piece of legislation, especially since California still relies heavily on natural gas to balance its renewable energy sources.
When the wind is at rest and the sun falls beneath the horizon line, natural gas provides a much-needed backup source of energy for Californians.
There are other challenges that must be met, too.
READ THIS: California local governments share how to prepare for electric cars
Numerous new solar and wind plants would have to come online, and battery farms to store energy for high-demand periods with little renewable production would have to increase tremendously.
Mike O’Boyle, who studies the power sector at Energy Innovation, a San Francisco think tank, said the goal is certainly doable—but implementing it would be an ongoing experiment.
Nowhere on Earth is there an area the size of California now powered exclusively by renewable energy, and since there's no blueprint, California would largely be learning as it goes.
Wind farm, by Flickr user Patrick Finnegan (Used under CC License)
There are objections to the proposed legislation, especially from utility companies.
Companies fear the cost of such ambitious legislation will be passed along to ratepayers, who could see their utility bills rise significantly.
They also fear that should energy supply fall short of demand, their companies would inevitably take the blame and the public anger if the power went out.
CHECK OUT: Electric cars now 5 percent of California new-car sales: report
However, state officials noted the rapid expansion of renewable energy thus far, and believe that by the time its ready to retire fossil fuels, costs of large-scale renewable energy will have reached parity with fossil-fuel generation.
Electric cars are also viewed as a way to balance the power grid.
If a smart, connected, and renewable energy grid could charge cars only when the sun is shining its brightest or winds blowing with the most gusto, it could take stress off of the grid at large.