Strong consumer demand during last week's big shopping weekend could be a huge relief for Amazon (AMZN -0.24%) investors.

The online retail giant saw its inventory levels explode last year after it expanded its fulfillment network and stocked its warehouses full of KitchenAid mixers, iPads, and all the trinkets people love to buy on Amazon.com. But as online sales growth slowed in 2022, more and more items were being left in Amazon's warehouses for longer. That's led to a drop in operating efficiency, dragging down profits.

But this year's Cyber Five -- the period from Thanksgiving through the following Monday -- saw strong demand, and could help right-size Amazon's inventories for 2023.

Already headed in the right direction

Amazon was already showing signs of an improving inventory picture this summer.

Inventory fell from $38.2 billion to $36.6 billion in the third quarter. A big part of that is likely due to Prime Day, which requires Amazon to build inventory at the end of the second quarter for the early July sales event. But Amazon held a second Prime Day at the start of the fourth quarter, and typically builds inventory heading into the biggest shopping months.

What's more, the same cannot be said of Amazon's biggest competitors, Walmart (WMT 0.58%) and Target (TGT -1.08%). Walmart inventories increased from $59.9 billion to $64.7 billion last quarter. Target, which has faced a significant inventory challenges, saw inventory climb to $17.1 billion at the end of the third quarter versus $15.3 billion at the end of July.

It's worth noting both Walmart and Target are showing signs of improvement. The year-over-year increase in inventories at both retailers slowed in the third quarter. But Amazon is showing the best progress in right-sizing inventory ahead of Q4.

Strong fourth-quarter sales so far

Early Q4 retail data and Cyber Five data shows stronger-than-expected sales. That could mean better-than-expected sales for Amazon. What's more, the e-commerce giant said the period from Thanksgiving through Cyber Monday was its biggest shopping weekend ever.

Amazon provided fourth-quarter guidance of single-digit revenue growth, including its fast-growing advertising and cloud computing businesses, alongside its Q3 earnings report. That suggested paltry sales growth for the core online retail business.

Stronger sales should give Amazon the ability to dramatically reduce inventory levels. That might not show up on the balance sheet until the end of the first quarter, though. The company works to keep in-stock levels high through the holiday shopping season for last-minute purchases. Amazon historically sees a big drop in inventory from the end of the fourth quarter to the end of Q1, but that didn't happen in 2021 or 2022.

Getting back to cash flow

While better top-line sales should translate into better cash flow, high inventory rates have held Amazon back this year. That could be about to change.

CFO Brian Olsavsky pointed out how the relationship between accounts payable and inventory has impacted free cash flow over the last couple of years during Amazon's third-quarter earnings call. "We generally have a favorable working capital impact from accounts payable that is more days than our inventory," he told analysts. "That's been flipping the last year, and we expect that to normalize as we move into 2023."

Holding more days of inventory than the average terms of payment for that inventory means Amazon is burning cash building up inventory. As the course reverses, the company should turn into the cash-generating machine investors expect to see.

Inventory is certainly moving in the right direction and early fourth-quarter data suggests Amazon should be able to get a handle on it quickly. That's a positive sign for investors after more than a year of negative free cash flow.