Trustpower plans to sell its retail business to rival power company Mercury for $441 million.
The deal is pending approval from the Commerce Commission and shareholders.
Trustpower is the country's fifth largest electricity generator and the fourth largest retailer by market share.
It has about 231,000 customers nationwide, supplying them electricity, gas, and wireless broadband.
The sale would increase the number of Mercury's customers for both energy and telecommunication services to about 780,000.
Mercury chief executive Vince Hawksworth said the acquisition would help them provide bundled services that customers would appreciate.
"We see this adding material value to our customers and Mercury," he said.
If the sale is approved, Mercury will take over the Trustpower name and brand, leaving Trustpower to select a new name in the future.
Mercury plans to fund the acquisition through a new debt facility secured from its bankers.
Hawksworth said customers of both Trustpower and Mercury would continue to receive their current services.
Trustpower chairperson Paul Ridley-Smith said several parties had expressed interest in buying the business.
"We are pleased that our business will stay in local hands, with a future owner committed to retaining Trustpower's Tauranga and Oamaru offices for the foreseeable future," Ridley-Smith said.
Trustpower announced it was exploring the possible sale of its retail operation in January, citing significant changes in the increasingly competitive energy and utility retail market.
Trustpower chief executive David Prentice said the company had an important part to play in creating sustainable energy in the future.
"New Zealand needs to greatly increase renewable energy generation to aid the de-carbonisation and electrification of the economy and we are in a unique position to play a role in helping the country achieve its climate change targets," Prentice said.
As part of the transaction, Trustpower would retain all its generation assets and its 14,000 corporate and industrial clients it supplies power to.
It said the majority of staff who work in the retail business would be transferred to Mercury but it was unable to rule out job losses.
Trustpower will enter into a new energy hedge contract with Mercury to provide generation at stable prices through to 2024.
The sale is expected to be finalised later this year or in early 2022, if the Commerce Commission approves the sale, Trustpower's shareholders agree, and Tauranga Energy Consumer Trust (TECT) can be restructured.
Trustpower's cornerstone investor, Infratil, which owns 51 percent of the company, said it would vote in favour the sale.