There are a lot of really valid reasons for rethinking the way energy is produced and used—climate change, corporate citizenship, sustainability concerns. But one of the biggest reasons may be that current practices just don’t make sense. Companies pay to heat a building to create a comfortable environment for employees. They pay again for the power to run the servers and other equipment. Then they pay again to cool down the rooms where the servers are.

However, a growing number of companies are starting to do things differently and are using renewable energy, such as solar and wind power, to run the servers. Heat that is generated from the servers is used to warm the parts of the building where people work. And naturally cooled air or water is used to cool the server rooms.

Sure, this is better for the environment, but it is also saving a lot of money.

Companies with the largest data centers, such as Amazon, Apple, Facebook, Google, and Microsoft, are leading the way as they have the economies of scale to make such efforts more productive. In addition, they have the money to apply to such projects, and typically have corporate cultures where environmental issues are of high importance to their employees and stockholders.

Facebook, in fact, recently said it intends to use renewable energy for all its data centers, powering them with wind and cooling them with air. Microsoft earlier this year started operating one of its data centers completely off the grid, running on methane. Similarly, in 2013, Apple wrote in its blog that it powered all its data centers with 100 percent renewable energy and reached 94 percent renewable energy usage across its corporate campuses and data centers. This was particularly noteworthy because the company had been singled out by Greenpeace in 2011 for its reliance on fossil fuels.

“So how do you power something as energy intensive as a data center completely with renewables?” asks Steven Levy in Wired. “Depends on where the data center is. [Apple’s] Newark, California, data center largely draws its power from wind. Its Prineville, Oregon, data center is also powered by wind, but plans to switch to mainly hydroelectric power, using an innovative plan that draws power from water temporarily diverted from irrigation canals. Apple also is a customer of Bloom boxes, a biogas fuel cell technology. But Apple’s marquee renewable is solar.”

For its part, Google says it isn’t trying to create renewable energy projects at its data centers. “Unfortunately, the places with the best renewable power potential are generally not the same places where a data center can most efficiently and reliably serve its users,” the company posted in a blog. “While our data centers operate 24/7, most renewable energy sources don’t—yet.”

Instead, Google is focusing on increasing the amount of renewable energy available to everyone by investing in Power Purchase Agreements (PPAs)—“long-term contracts (typically 20 years) to buy clean energy from a particular producer,” the company writes on its renewable energy blog. “By providing developers with a solid commitment, we help them get the money they need to finance new clean energy facilities. In exchange, we get clean energy at competitive prices as well as the renewable energy certificates (RECs) to help reduce our carbon footprint. Together, we make the grid a little bit greener.”

Altogether, Google has invested more than $1.5 billion in renewable energy projects such as large-scale wind and rooftop solar with a total capacity of more than 2.5 GW, which is more than the company requires for its own use.

These corporate efforts have the additional effect of encouraging states and local power companies to increase their production of renewable energy. The thinking is that as states increase renewable energy projects, they will attract vendors who might invest in developing data centers and those vendors will create jobs in their regions.

Your company may not be in the same league as Apple or Google and your data centers might not chew up as much power. But renewable energy is still worth looking into. The answer to your energy costs may be blowing in the wind.