The deal is the latest in a flurry of pipeline mergers spurred by development of shale oil and gas fields and master limited partnership (MLP) structures that have provided the pipeline industry with rich tax breaks.

Energy Transfer Partners is paying a 22.5 percent premium over Friday's closing share price, giving it confidence about completing the deal without a bidding war as occurred with the takeover of Southern Union, which closed last month.

"I feel that we're paying full value for this company," Energy Transfer Partners Chief Executive Kelcy Warren said when asked on a conference call about the possibility of a higher bidder for Sunoco emerging.

The acquisition will give Energy Transfer Partners control of Sunoco's general partner stake of its MLP, Sunoco Logistics Partners and 32.4 percent of the partnerships units.

Sunoco Logistics owns about 5,400 miles of crude oil pipelines, 2,500 miles of refined products pipelines and 42 million barrels of refined product and crude oil storage capacity at its terminals.

Development of shale oil fields in North Dakota and elsewhere has triggered an upheaval in the U.S. pipeline business, which traditionally focused on moving crude north from the Gulf Coast. As a result, nimble pipeline companies have been able to secure lucrative shipping commitments from producers anxious to escape inland gluts and access premium coastal markets.

Mike Breard, senior energy analyst at Hodges Capital Management in Dallas, said the inevitable regulatory complications of building new pipelines made existing assets particularly valuable, and the nature of the pipeline business meant pipeline owners could benefit from increased scale.

"You might as well manage 10,000 miles of pipeline as 1,000," he said. "A 12-inch pipeline's a 12-inch pipeline."

Plunging natural gas prices and new sources of production near big markets in the U.S. northeast threaten to undermine the profitability of some long-haul natural gas pipelines, so Energy Transfer aims to earn more from moving heavier hydrocarbons like crude oil, natural-gas liquids (NGLs) and refined products.

CEO Warren said the combined company's pipeline business would now get about 30 percent of its cash flow from heavier hydrocarbons. Energy Transfer is also looking at ways to convert current pipelines to transport NGLs or crude instead.

"There definitely needs to be a lot more crude oil infrastructure," said John Musgrave, a vice president at Swank Capital, whose Cushing MLP Asset Management LP owns a 0.27 percent stake in Energy Transfer Partners.

"There are still a lot of crude bottlenecks in the U.S.," Musgrave said, noting that a number of new NGL and crude heavy shale regions need more pipelines.

For each share they own, Sunoco shareholders will receive $50 in cash, or 1.0490 Energy Transfer Partner units, or $25 in cash and 0.5245 Energy Transfer Partner units. The third option is worth about $50.13 based on Friday's close, compared with Friday's closing price of $40.91 on the New York Stock Exchange.

Shares of Sunoco rose nearly 20 percent on Monday to $48.98, while Energy Transfer Partners shares rose 3 percent to $49.39.

MLP STRUCTURE FUELS DEALS

The planned acquisition comes on the heels of one by Energy Transfer Equity LP, owner of the general partner of Energy Transfer Partners, to buy rival Southern Union Co for $5.5 billion, after a bidding war with Williams Cos Inc.

It also follows Kinder Morgan Inc's more than $20 billion deal for pipeline company El Paso. Deals have become common in the industry due to increasing demand stemming from new shale production as well as the need to fuel growth at master limited partnerships.

MLPs, which pay virtually no corporate tax, distribute most of their profits directly to shareholders and need to grow organically or via acquisition to keep increasing those payouts.

"Any assets that are legally able to be put into an MLP structure will be put into that structure," said Bernard Colson of Global Hunter Securities. "It makes more sense economically and there is a strong trend toward doing that."

After the deal, Sunoco Logistics will continue to trade separately on the New York Stock Exchange.

The companies said the deal would create about $70 million in annual cost savings, about half of which Energy Transfer Partners believes can be realized in 2013.

Sunoco, once a major independent refiner in the Northeastern United States, plans to end nearly 120 years in the refining business as high oil prices and slumping demand squeeze profits.

Sunoco said it would continue talks with private equity firm Carlyle Group LP for a joint venture to run its 335,000-barrel-per-day Philadelphia refinery.

A deal with Carlyle would save the refinery, the biggest on the U.S. East Coast, from a planned closure and ease concerns about potential fuel shortage on the East Coast this summer.

Energy Transfer is also picking up Sunoco's retail business, which operates around 4,900 gas stations in the United States.

Wells Fargo Securities acted as financial adviser to Energy Transfer, while Credit Suisse Securities LLC advised Sunoco.

(Reporting by Mike Erman in New York, Swetha Gopinath in Bangalore and Braden Reddall in San Francisco; Editing by Alden Bentley)

By Swetha Gopinath and Michael Erman