Iberdrola SA, Spain’s largest electricity company, agreed to buy UIL Holdings Corp. in a deal valued at about $3 billion in cash and shares to create a U.S. utility with about 3.1 million customers.

UIL shareholders will get $52.75 a share comprising $10.50 cash and the rest in stock in the new company, Bilbao-based Iberdrola said in a statement. At that value, the deal represents a 25 percent premium to UIL’s last closing price.

Power companies are hunting for acquisitions as they seek to cut costs and expand regulated businesses after $200 billion of deals were proposed or completed last year, the highest since 2007, according to data compiled by Bloomberg. Iberdrola will combine its American assets with UIL to create a U.S.-traded stock and also gains access to the country’s shale-gas business.

UIL’s gas operations “allows us to become part of the nice cake which is the shale gas development in the U.S., so that’s attractive,” Iberdrola Chief Financial Officer Jose Sainz said on a conference call after the deal was announced. “I think we are going to cut a piece of that cake.”

Iberdrola shares were unchanged at 6.05 euros at 10:14 a.m. in Madrid trading.

The new company, with customers across New York, Connecticut, Maine and Massachusetts, plans to invest $6.9 billion in regulated electric and gas infrastructure and other capital expenditure over the next five years, Iberdrola and New Haven, Connecticut-based UIL said Thursday in a statement. It will also control the second-largest operating wind portfolio in the U.S.

“We will be a more diversified and stronger utility as a group with greater scale and financial resources to support continued investment in system reliability and infrastructure projects,” UIL Chief Executive Officer James P. Torgerson, who will be CEO of the new company, said in the statement.

It will pursue investment opportunities across the U.S., “such as its highly attractive renewable energy development portfolio,” Torgerson said in the statement. Iberdrola is the world’s largest renewable producer.

The deal has been approved by the boards of both companies and a transaction is expected to close by the end of this year, subject to approvals, according to the statement.

Iberdrola will have nine directors on the board of the new company, alongside Torgerson and two UIL directors.

Morgan Stanley, Sullivan & Cromwell LLP and Wiggin and Dana LLP served as advisers to UIL, according to the statement. Lazard Ltd. advised Iberdrola, Lazard spokeswoman Judi Mackey said in an e-mail.