Macy’s said on Tuesday that it would vastly reshape its strategy and retail footprint, closing about 150 Macy’s stores over the next three years while expanding its upscale Bloomingdale’s and Bluemercury chains.

The moves put the stamp of the company’s new chief executive, Tony Spring, on an effort to keep the largest department store operator in the United States profitable and stave off a pending takeover bid.

It is the second major downsizing of the Macy’s chain since 2020 and will leave the company with 350 stores, slightly more than half the number it had before the pandemic.

The overhaul is intended to “accelerate our path to market share gains, sustainable, profitable growth and value creation for our shareholders,” Mr. Spring, who took over this month, said in a statement.

Macy’s said it planned to close “underproductive locations,” noting that they accounted for 25 percent of the company’s overall square footage but just 10 percent of sales. The company said it expected to take in $600 million to $750 million by selling these stores and streamlining some of its warehouses.

The company said it would start notifying workers on Tuesday at stores it planned to close. It plans to shutter roughly 50 stores this fiscal year and the rest by the end of 2026.

While the Macy’s stores close, the company plans to add 15 Bloomingdale’s locations. Bluemercury, its beauty chain, will add 30 stores, while others will be remodeled. As of November, there were 58 Bloomingdale’s and 158 Bluemercury locations.

“There’s less competition there, but the problem is that it’s not clear that the luxury department store really has a great future,” said David Swartz, a retail analyst at the financial services firm Morningstar. “A lot of luxury labels are doing their own direct selling.” He noted that the luxury chain Nordstrom had been closing stores in recent years.

The company will open its smaller-format Bloomingdale’s stores — known as Bloomie’s — and outlet stores in 15 markets over the next three years, Mr. Spring said on a call with analysts.

In recent years, the company has been opening smaller stores within outdoor strip malls, rather than enclosed malls, which have been losing shoppers.

“That’s where the whole market is going,” Mr. Swartz said. “It makes sense for Macy’s to open up stores in those smaller locations, but is it too late? There’s already other companies doing the same thing, and will Macy’s actually stand out and will it make up for the lost sales they will have from closing 150 stores?”

The decision to pare the midmarket Macy’s chain while increasing the luxury chains’ presence is a sign that Mr. Spring wants to reposition the company’s overall image so consumers see it as a higher-end destination.

Customer research showed that people wanted a better shopping experience at Macy’s, the company said, whether with improved visual merchandising or more help from store workers. The savings that the company expects from this strategy, including the sale of some of its assets, could help underwrite such improvements.

Mr. Spring, who spent four decades at Bloomingdale’s, took the corporate reins at a challenging time. In December, an investor group submitted a bid that would take Macy’s private at a value of $5.8 billion. The investors, Arkhouse Management and Brigade Capital Management, said that unless the retailer began sharing nonpublic information with them, they might take their offer to shareholders.

Sales have fallen as Macy’s has struggled to win over the next generation of shoppers and compete in a world increasingly oriented toward e-commerce.

Mr. Spring had already started making his mark. In January, a memo to employees from him and the departing chief executive, Jeff Gennette, said the company would cut about 2,300 jobs, or 13 percent of its corporate work force, as it looked to better align its resources with customer behavior and to make decisions faster. The company also said it planned to close a handful of stores.

The last major restructuring at Macy’s was in February 2020, when the company said it would close 125 stores and cut 2,000 jobs. Then the pandemic turned many stores dark for weeks, forcing the retailer to scramble to improve its website and e-commerce offerings and figure out how to bring people back to stores once they reopened.

After an initial sales boost from consumer spending on all manner of items early in the pandemic, Macy’s has faced a sales slump.

On Tuesday, the company also reported earnings for fourth quarter, which included the holiday shopping season. Net sales of $8.1 billion were in line with analysts’ estimates. Sales at both Macy’s and Bloomingdale’s were down from a year earlier, while those at Bluemercury rose 2.3 percent — a sign that shoppers are gravitating toward the beauty and skin-care categories.