Uber Technologies Inc. has made an offer to acquire Grubhub Inc., in a move that would build out its food-delivery platform even as it shutters parts of its own service abroad, according to people familiar with the matter.

The companies are in talks about a deal and could reach an agreement as soon as this month, said the people, who asked not to be identified because the matter isn’t public.

Deliberations are ongoing and talks could still fall through, the people said. A spokesman for Uber declined to comment, while a representative for Grubhub couldn’t immediately comment.

Grubhub shares climbed as much as 37% in New York trading after being temporarily halted. They were up 33% at 12:14 p.m., valuing the company at $5.7 billion. Uber, with a market value of about $59 billion, rose as much as 8.2%.

Uber is shuttering its own food-delivery unit, Uber Eats, in seven countries where the service has proven unpopular, it said last week. Those markets represented 1% of Uber Eats gross bookings and 4% of the business’s adjusted losses before interest, taxes and depreciation for the first quarter of 2020, the company said.

Uber’s ride-hailing business has been hammered by the global pandemic, but delivering meals has helped the San Francisco-based company drive sales as people shelter in place. Still, the food delivery industry remains widely unprofitable, even as people rely on delivery to stay in their homes.

Though the losses have led to much speculation on potential consolidation in the industry, lofty private valuations and antitrust concerns have made some food-delivery players resistant to striking a deal. Those issues may be easier to iron out for Grubhub and Uber, which both have publicly traded stocks. A year after Uber’s public offering, the company still trades below its peak valuation as a private company.

A deal “would help consolidate the U.S. online food delivery market and reduce cash burn,” Bloomberg Intelligence senior industry analyst Mandeep Singh wrote in a note Tuesday.

Meanwhile, startups DoorDash Inc. and Postmates Inc. have increased the competitive pressure on incumbent Grubhub, which was founded in 2004. Grubhub has expanded into doing delivery itself after years of serving as a marketing platform for restaurants to organize their own deliveries. The rivalries have squeezed Grubhub’s margins, with the coronavirus adding further pressure that forced the company to push off profit targets. Uber, similarly, delayed its target to reach adjusted profitability until sometime in 2021.