CAMDEN, N.J. — Campbell Soup Co. said Thursday it has agreed to sell its upscale Godiva Chocolatier brand to a Turkish food company for $850 million.

Camden-based Campbell said the buyer, Yildiz Holding AS, would add the brand to its Ulker Group.

Campbell, the world's largest soup maker, announced in August that it was looking for a buyer for the brand, which does not fit squarely into its main business of selling healthy meals and beverages.

Annual sales for Godiva are around $500 million. Margins are strong for the company, but analysts said it just didn't fit with what Campbell is trying to do. Godiva distribution, for instance, is different from the food store channels where the company sells its soups, breads and pasta sauce.

Campbell owns about 450 Godiva retailers, which account for roughly two-thirds of Godiva's sales. Most of the other sales are in department stores — places where you can't buy its Pepperidge Farm Goldfish crackers. The chocolates are hand-packed in Pennsylvania and Belgium.

When Campbell announced it was seeking a sale of Godiva in August, analysts were upbeat. They thought it would generate money the company could put back into its other initiatives, including its push into soup sales in the huge markets of China and Russia.

The sale price was about what some analysts figured it ought to be, and Campbell said it was the right price.

"We are very pleased with the value we obtained for Godiva," Campbell president and chief executive officer Douglas R. Conant said in a statement. "The sale price reflects the strength of the Godiva business," he said, adding the chocolatier was an excellent strategic fit within Ulker.

Ulker sells food — including cookies and candies — in Asia, Europe, the Middle East and the Americas. Its brands available in the United States include Goodbar candy bars.

Campbell said it expects the sale to close within several months.

Campbell shares rose 9 cents to $36.19 in electronic after-hours trading Thursday. During regular hours, the shares fell 30 cents to close at $36.10.