When the Royal Navy's new aircraft carriers arrived in Portsmouth, the base faced a critical issue – how to find enough electricity.
HMS Queen Elizabeth and HMS Prince of Wales doubled the base's energy use. In fact, the load was so great there was a danger it would impact power supplies to the city itself.
To meet the need, they built a new 13 megawatt combined heat and power plant, capable of producing enough electricity to fully power the base, and with the added bonus of supplying heat as well.
As well as reducing emissions, the plant has saved £4,000,000 a year – cash that is being re-invested in other green technology there.
The financial gains from the plant have also provided opportunities to run feasibility studies to look at what happens next.
"We've just completed a feasibility study... taking seawater and breaking it into oxygen, which becomes a sellable product, and hydrogen, which we can then use to mix with our mains gas... and these [generators] become not only very efficient but productive in terms of our carbon journey," said the engineer in charge of the project, Iain Greenlees, Portsmouth's Infrastructure Superintendent.
The power plant is one of a raft of initiatives here aimed at cutting the base's carbon footprint and bringing it close to net-zero by 2040.
Portsmouth emits 31,000 tonnes of CO2 per year, about 3% of the entire defence estate emissions.
That figure has already been drastically reduced – cut by two-thirds since 2003. At the same time, the base's energy use has been cut in half.
But they want to go further. They are also trialling wind power here and constructing a new logistics building for the carriers that will be completely net-zero.
The base also has 46 electric vehicles, and new solar canopies are being fitted over some of the car parks here to power charging points.
"We've had a really good history over the last 10 years of cost-led reduction in our energy consumption in the base," explained Commodore Jeremy 'JJ' Bailey, the base commander.
"When I arrived a couple of years ago, I began to change that so we thought about carbon as part of that dynamic.
"That's allowed us to think forwards about the sorts of things we might adopt and the technologies we could bring into play," he added.
Across the water from the dockyard is Whale Island, a former naval gunnery school and now home to the Royal Navy's headquarters.
Here they are also going green, encouraging wildlife and fauna to grow, and building a colony of bees. They even produce their own honey.
"Sustainability has always been at the heart of what we do," said Rear Admiral Paul Beattie, Director of Naval Staff.
"The difference now is that it's at the fundamental core of all our business and we need to drive that forward and turn it into operational advantage."