While it was not very merry holidays for some big retailers such as Macy’s and Kohl’s, the season as a whole ended up being more bountiful than expected.

The National Retail Federation (NRF), which bases its numbers on Commerce Department figures, said Friday that retail sales in November and December rose 4 percent to $658.3 billion. Non-store sales, which includes online and catalog sales, jumped 12.6 percent and made up a little more than a fifth of ­overall sales.

The final tally came in higher than the group’s initial holiday forecast, which was for sales to grow 3.6 percent, a bigger increase than the last couple years, and for non-store sales to go up between 7 to 10 percent.

“These numbers show that the nation’s slow-but-steady economic recovery is picking up speed and that consumers feel good about the future,” NRF President and CEO Matthew Shay said in a statement. “Retail mirrors the economy. And while there might have been some bumps in the road for individual companies, the retail industry overall had a solid holiday season and retailers will work to sustain this in the year ahead.”

Higher incomes, lower unemployment, rising home values last year all helped contribute to the uptick in consumer spending.

But the robust numbers highlight the growing disparity between retailers that are winning and losing. In the first two weeks of 2017, a number of large companies have announced disappointing holiday sales along with plans to close stores and downsize their staffs.

The industry will have a better sense next month of who the winners were over the holidays when many big chains will report their full quarterly results. Minneapolis-based Target Corp. is scheduled to release its holiday results on Feb. 28, followed a day later by Richfield-based Best Buy.

However, some retailers have started releasing specific numbers.

Last week, Macy’s reported a 2.7 percent decline in comparable holiday sales. The department store chain also said it will cut 10,000 jobs and announced 68 store closures including its prominent and historic location on Nicollet Mall in Minneapolis. Kohl’s said its same-store holiday sales dropped 2.1 percent, and Sears Holdings said it would shutter 150 Sears and Kmart stores this year after reporting a 12 to 13 percent drop in comparable sales in November and December.

Meanwhile, many mall-based chains have been suffering, too. The Limited, a longtime fixture in malls, has shuttered its 250 stores nationwide and the nation’s biggest mall operators have rushed in to try to resuscitate Aéropostale, which filed for bankruptcy last year. Sales at other stores such as Ann Taylor and Victoria’s Secret also dropped during the holidays.

The news hasn’t been all bad, though. Lululemon reported a better holiday period as has the parent company of the Gap and Old Navy.

Some longtime retailers, particularly department stores, have been struggling as consumers have shifted their spending to online sites such as Amazon.com, off-price retailers such as T.J. Maxx, fast-fashion purveyors such as Zara and smaller boutique retailers.