Even as Wal-Mart makes cuts, the company has taken steps to retain employees -- like boosting its hourly wage and creating new roles focused on its online grocery business.Justin Sullivan/Getty Images files

Wal-Mart Stores Inc. is cutting 400 to 500 jobs at headquarters this week, the latest effort to streamline a retail empire under threat from Amazon.com Inc.

The layoffs will hit the company’s marketing, human resources, merchandising, real estate, logistics and finance divisions, the Bentonville, Arkansas-based chain said. The company is informing most of those affected on Thursday, and they will have 60 days to find a new role.

The cuts extend a busy month for the world’s largest retailer, which also shut 63 Sam’s Club warehouses and reorganized that unit’s purchasing division. But even as it makes cuts, the company has taken steps to retain employees — like boosting its hourly wage and creating new roles focused on its online grocery business. Chief Executive Officer Doug McMillon is betting that a leaner organization can better battle Amazon, and has said Wal-Mart “is not where we want to be” in terms of reducing corporate expenses.

“We’ve been looking at our structure for some time as we explore ways to operate more effectively,” the company said in an emailed statement on Thursday. “Those efforts continue. We’re committed to handling every transition smoothly and ensuring everyone is treated as fairly and respectfully as possible.”

While the threat from Amazon hasn’t abated, Wal-Mart is handling it better than most retailers. In the third quarter, same-store sales in its home market rose the most in more than eight years.

Overall, the holiday shopping season was the best for U.S. retailers since the Great Recession. Wal-Mart reports its fourth-quarter results on Feb. 20.