Keurig, the single-cup coffee machine maker, said Monday it has agreed to be sold to private equity firm JAB Holding Co. for almost $14 billion.

Keurig has been dealing with slowing sales of its machines and K-cups, the coffee-filled pods that are used in the coffee makers. Sales of K-cups, which accounted for more than 80 percent of Keurig revenue, rose 1 percent to $3.6 billion in the year ended Sept. 26. Sales of its machines fell 23 percent to $632.6 million in the same period.

advertisement | advertise on newsday

Its stock has suffered too, falling nearly 61 percent since the beginning of the year. In fact, the stock was the seventh-worst performing stock on the Standard & Poor’s 500 index for the year.

JAB Holding said it offered $92 for each share of Keurig, a 78 percent premium from the stock’s closing price of $51.70 on Friday.

The deal jolted shares of Keurig Green Mountain Inc. up nearly 72 percent to close at $88.89 Monday.

Luxembourg-based JAB Holding already has a robust coffee empire. It has a controlling stake of Jacobs Douwe Egberts, the company behind Gevalia, Tassimo and other brands. It also has stakes in Peet’s Coffee & Tea and Caribou Coffee. Outside coffee and tea, JAB Holding has a controlling stake of beauty company Coty and high-end shoe seller Jimmy Choo.

advertisement | advertise on newsday

After the deal closes, which is expected to happen in the first quarter of next year, Keurig Green Mountain Inc. said it will remain headquartered in Waterbury, Vermont.