LONDON - Rishi Sunak, one of the final three candidates to become Britain's next prime minister, said he wanted to make the country energy independent by 2045 in response to the supply shock caused by Russia's invasion of Ukraine.

"It has never been more important that our country achieves Energy Sovereignty, so that we’re no longer reliant on the volatility of the global energy supply," Sunak said in a statement.

He said the target would be enshrined in law, and its implementation would be overseen by a new government department focused solely on energy. Sunak also said he would not relax a ban on onshore wind farms in England.

The former finance minister, whose resignation helped spark a mass revolt against Prime Minister Boris Johnson, is currently ahead in the leadership contest among lawmakers from the ruling Conservative Party.

A final vote later on Wednesday will whittle down the field to two candidates, and then the party's rank and file members around the country will choose their new leader by postal vote. The result is due Sept. 5.

(Reporting by William James; Editing by Kate Holton and James Davey)