The nation’s retailers are doing a better job of making their customers happy.

After two years of declining satisfaction, they reversed course during the 2016 holiday shopping season, according to the latest American Customer Satisfaction Index report. Retailers scored 78 out of 100 points, that’s up 4.7 percent and an all-time high for the sector.

All six categories covered in this report — department and discount stores, specialty retail stores, supermarkets, drug stores, gas stations, and online retail — improved year over year. But online retail was the clear winner with an ACSI score of 83, up 3.8 percent from 2015. (The report is based on 12,500 customer surveys collected in the fourth quarter of 2016.)

“Shopping online is so easy and convenient and as a result satisfaction is much higher than the brick-and-mortar experience and is playing a big role in putting that pressure on the brick-and-mortar side of retail in terms of sales performance and just getting people into the store,” said David VanAmburg, ACSI managing director.

Personal Treatment

Oddly enough, as more people shop online and national retailers close stores, customers who go to the ones that remain open may get better service. If the store isn’t crowded and there are no lines at the register, the experience will be more satisfying, VanAmburg told NBC News. Of course, this is not a sustainable business model.

“Long-term this is likely to flip on its head because more layoffs and store closings are coming,” VanAmburg said. “Down the road we’re going to have lots of consumers who are frustrated that their favorite store in their favorite location is closed and now they have to drive a lot further to get to that store.”

Of course, emptier stores are not the only reason for happier customers. The report points out that better service, lower gasoline prices, and food price deflation have also contributed to stronger satisfaction.

While foot traffic is down, customers who go to brick-and-mortar stores are intent to buy and are buying more than in the past, according to the National Retail Federation.

“Basket sizes continue to grow thanks to effective customer service and low competitive prices on everyday items,” Ana Serafin Smith, NRF’s senior director of media relations, told NBC News. “As consumers continue to evolve the way they shop, retailers will pay attention and modify their strategies to align with the needs and wants of their customer base.”

Marshal Cohen, chief industry analyst at the NPD Group, said retailers are focused on dealing with online competition and working harder at “creating a better and more satisfying in-store experience.” This includes a sales team that’s better trained and making sure popular merchandise is always in stock. The ability to buy-online and pick-up at the store is one example of using technology to improve the brick-and-mortar shopping experience, he told NBC News.

People walk past...