This story was originally published by Yale Environment 360 and is reproduced here as part of the Climate Desk collaboration.

Stefan Paris is a 55-year-old radiologist living in Berlin’s outer suburbs. He, his partner, and their three-year-old daughter share a snug, two-story house with a pool. The Parises, who are expecting a second child, are neither wealthy nor environmental firebrands. Yet the couple opted to spend $36,000 for a home solar system consisting of 26 solar panels, freshly installed on the roof this month, and a smart battery—about the size of a small refrigerator—parked in the cellar.

On sunny days, the photovoltaic panels supply all of the Paris household’s electricity needs and charge their hybrid car’s electric battery too. Once these basics are covered, the rooftop-generated power feeds into the stationary battery until it’s full—primed for nighttime energy demand and cloudy days. Then, when the battery is topped off, the unit’s digital control system automatically redirects any excess energy into Berlin’s power grid, for which the Parises will be compensated by the local grid operator.

“They convinced me it would pay off in 10 years,” explains Paris, referring to Enerix, a Bavaria-based retailer offering solar systems and installation services. “After that, most of our electricity won’t cost us anything.” The investment, he says, is a hedge against rising energy costs. Moreover, the unit’s smart software enables the Parises to monitor the production, consumption, and storage of electricity, as well as track in real time the feed-in of power to the grid.

The Parises are one of more than 120,000 German households and small-business owners—and an estimated 1 million people worldwide—who have dug deep into their pockets to invest in solar units with battery storage since lower-cost systems appeared on the market five years ago. “No one expected this kind of growth, so fast,” says Kai-Philipp Kairies, an expert on power generation and storage systems at the RWTH Aachen University in western Germany.

Today, one out of every two orders for rooftop solar panels in Germany is sold with a battery storage system. The home furnishing company Ikea even offers installed solar packages that include storage capacity. Battery prices have plummeted so dramatically that Germany’s development bank has now scratched the battery rebates—covering about 30 percent of the cost—that it offered from 2013 to 2018.

To be sure, 120,000 households and small businesses represent only a tiny fraction of Germany’s 81 million people. But analysts say this recent growth demonstrates the strong appeal of a green vision for the future: a solar array on every roof, an electric vehicle in every garage, and a battery in every basement. Analysts see the embrace of home batteries as an important step toward a future in which low-carbon economies rely on increasingly decentralized and fluctuating renewable energy supplies. To date, electricity storage has lagged far behind advances in solar power, but as batteries become cheaper and more powerful, they will increasingly store the uneven output of wind and solar power, contributing to the kind of flexibility that a weather-dependent source will require.

LEARN MORE The WIRED Guide to Climate Change

The budding popularity of solar panel and battery systems, driven by a drop in lithium-ion battery prices, has thrown a lifeline to Germany’s moribund solar sector, which has been reeling in recent years, in part because of low-cost production of solar panels in China. The progressive decline of feed-in tariffs—guaranteed remuneration for consumers supplying energy to the grid—also led to a sharp drop in solar energy deployment.

But against all odds, companies like Enerix, Sonnen, and Solarwatt have gotten back on their feet thanks to home energy storage systems. In 2012, Enerix had to shut down eight of its 15 affiliates in Germany and Austria. But since the battery boom, it has been reopening old shops and starting new ones, today boasting 54 outlets that sell panels, batteries, and energy optimization systems. Germany now has some 44 manufacturers of home energy storage systems. Germans have installed solar-panel arrays on more than 1 million buildings, but most of them lacked storage units. Now, a growing number of those homeowners are buying batteries. German electricity storage units also are being sold in France, Great Britain, Italy, the Netherlands, and Spain, as well as Australia and South Korea.