TheVanishingCart
E-commerce · checkout
The scenario
You are scrolling a shopping app late at night. You find exactly what you wanted, add it to your cart, and move on with your evening. The next morning, you open the app, go to checkout, enter your address, get to the payment screen, and the app tells you the item is no longer available. The thing you specifically chose is just gone, and you are back to searching from scratch.
This happens constantly, and it is not a bug. It is a structural gap in how most e-commerce systems handle inventory.
Why it happens
Most platforms check stock availability at the moment an item is added to cart. After that, the cart simply holds a reference to the product, it does not continuously verify that the product is still there. Meanwhile, other users are browsing the same catalog, and if the item is low in stock, multiple carts can be holding claims to the same one or two remaining units. Whoever completes checkout first gets it. Everyone else finds out only when they try to pay.
This is a classic race condition, a problem that shows up any time multiple people are competing for a shared, limited resource without a coordination mechanism in place.
What I would build instead
- Soft-reserve inventory at the start of checkout, not at add-to-cart. The moment a user begins the checkout flow (enters the payment step, not just opens the cart), the system holds that unit for a short window, roughly 10 minutes. This does not fully solve scarcity, but it means the person actively trying to buy something gets priority over someone who added it to cart three days ago and never came back.
- Never let a stock-out be a dead end. If the item genuinely runs out before checkout completes, the failure screen should not just say "unavailable." It should immediately show 2 to 3 visually and functionally similar in-stock alternatives, ideally in the same size, color family, or price range, right there in the same flow. The goal is to convert a moment of frustration into a recovered sale, not lose the customer entirely.
- Set honest expectations earlier. For items with very low stock (say, fewer than 5 units), show a visible "only 2 left" indicator at the product page and cart level. This does not prevent the problem, but it primes the user's expectations so the eventual stock-out, if it happens, feels less like a broken promise.
Why this matters, and how I would measure it
The real cost here is not just one lost sale. It is trust. A user who loses an item at checkout once will start double-checking availability before getting emotionally invested in a purchase, which slows down the entire funnel for that user going forward.
If I shipped this, I would track two things: the recovery rate (what percentage of stock-out events convert into a purchase of the suggested alternative), and the raw frequency of cart-to-payment stock-outs, which the soft-reserve window should reduce meaningfully on its own, independent of the alternatives feature.