(Reuters) - Campbell Soup Co and Hershey Co on Monday unveiled deals totaling nearly $6 billion to buy healthy packaged snacks makers, the latest example of big U.S. food companies trying to cater to an increasing American preference for healthy foods.

Campbell CPB.N will buy Cape Cod chips-maker Snyder's-Lance Inc LNCE.O for $4.87 billion in cash to combat sagging soup sales. Snyder's-Lance, the No. 5 U.S. healthy savory snacks maker, also owns brands such as Eatsmart veggie snacks.

Hershey HSY.N, meanwhile, will spend about $921 million to acquire Amplify Snack Brands BETR.N, which makes SkinnyPop popcorn and Paqui tortilla chips.

Most of the products made by Snyder’s-Lance and Amplify Snack claim to have no artificial ingredients or transfats and come in dairy-free cheese and naturally sweet flavors that are popular among millennials.

Snyder’s-Lance shares, which have gained in the past few session on reports of a possible deal, rose 6.8 percent to a record high of $50 per share, matching Campbell’s offer.

Amplify’s shares rose 71 percent to their highest in just over a year. They closed 6.9 percent higher at $50.04 on Monday. Shares of Campbell and Hershey both ended up about 0.1.

U.S. packaged food makers, including General Mills Inc GIS.N and Kellogg Co K.N, are buying or investing in healthy-food companies to shore up margins that have taken a beating from falling prices and demand for their mass-market brands.

A Hershey's chocolate bar is shown in this photo illustration in Encinitas, California January 29, 2015. REUTERS/Mike Blake

Conagra Brands Inc CAG.N bought Boomchickapop popcorn maker Angie's Artisan Treats in September, while Kellogg bought RXBar protein bar maker Chicago Bar Co in October to create premium positioning for their wares.

The savory healthy snacks market is estimated to be $8.95 billion in the United States, having gained nearly 15 percent over the past five years, according to data from Euromonitor International. The healthy sweet-snacks market is worth $10.37 billion, rising more than 20 percent in the same period.

“CRYSTALLINE LOGIC”

Campbell completed its $700 million acquisition of organic soup and broth maker Pacific Foods last week, when media reports first surfaced about a possible deal with Snyder’s-Lance.

“We think the Snyder’s-Lance deal represents crystalline logic,” ConsumerEdge Research analyst Jonathan Feeney said in a note.

Melding Campbell and Snyder’s-Lance’s roughly $2 billion U.S. snack portfolios will radically cut costs and add complementary salty snacks to round out Campbell’s successful Pepperidge brand and Lance’s position as a big national distributor of salty snacks, Feeney said.

Meanwhile, the primary benefit to Hershey from Amplify will likely be faster growth, Feeney said. But he cautions that the deal sets Hershey up for competition with PepsiCo Inc's PEP.N Frito-Lay and Campbell's Pepperidge.

Hershey, which makes Reese’s Peanut Butter Cups and Hershey’s Kisses, has acquired brands such as Krave meat jerky and Ripple Brand Collective’s barkTHINS over the past two years.

The company, which rejected a $23 billion bid from Oreo cookie owner Mondelez International Inc MDLZ.O in June last year, said it expects to save $20 million over the next two years through the Amplify deal.

J.P. Morgan Securities LLC and Morgan Stanley & Co. LLC are financial advisers to Hershey, while Jefferies LLC advised Amplify.

Credit Suisse acted is Campbell’s lead financial adviser and Weil, Gotshal & Manges LLP its legal counsel. Goldman Sachs & Co LLC advised Snyder’s-Lance and Jenner & Block LLP gave legal counsel.