After powering Germany for more than 40 years, an antiquated coal mine is being reinvented for the modern world. As Bloomberg reports, the state of North-Rhine Westphalia is transforming the Prosper-Haniel hard coal mine into a giant battery for storing renewable power.

The battery will use a pumped-storage hydroelectric reservoir system, which transfers water to chambers above and below the mine, to produce power. Once completed, the 200-megawatt battery will be capable of providing energy to more than 400,000 homes.

The project ties into Germany’s plan to reach 100 percent renewable power by 2050. That may sound ambitious, but the country has already come close—Germany reached 87 percent renewable energy for a brief point in 2016.

As Germany approaches their goal, more coal mines, like the one in North-Rhine Westphalia, will be shut down. The renewable battery project ensures that new job opportunities will be there for locals when the Prosper-Haniel mine closes in 2018.

[h/t Bloomberg]