The New York-based company said it had a loss of $1.39 per share. Losses, adjusted for one-time gains and costs, were 81 cents per share.
The results surpassed Wall Street expectations. The average estimate of six analysts surveyed by Zacks Investment Research was for a loss of $1.78 per share.
The department store operator posted revenue of $3.56 billion in the period, also topping Street forecasts. Four analysts surveyed by Zacks expected $3.51 billion.
The company said sales were strong across its three brands: its namesake as well as Bloomingdale's and Bluemercury.
Digital sales rose 53% over the second quarter of 2019. Overall comparable sales — or sales in stores open at least a year — were down 34.7% on an owned basis and down 35.1% on an owned plus licensed basis.
"Restarting our stores’ business was our top priority, and we successfully accomplished that while also ensuring that our digital business remained strong," said Jeff Gennette, chairman and CEO of Macy’s Inc.
Macy’s shares added nearly 6% in premarket trading.