Following the Russian invasion of Ukraine, the city council had agreed to use a break clause to end the deal with Gazprom Marketing and Trading, which at the time was wholly-owned by the Russian government.
However, the subsidiary's parent company, Gazprom Germania, has since been taken over the German energy regulator. It is now unable to buy Russian gas and has been sanctioned by the Russian government.
The £5.5m contract was signed at the end of last year and runs for three years. The council had planned to use a break clause to end it early and this was expected to cost £57,000.
However, council leader Gerald Vernon-Jackson said the cost would have been about £1m a year due rising gas prices.
'It's clear now that this is no longer a Russian company since it has now been nationalised by the German state,' he said.