WooCommerce checkout failed or abandoned

What happens to a gift card balance when a shopper applies a Wrapped gift card in WooCommerce and the order then fails, is cancelled or is never placed because the shopper closed their browser.

Updated November 4, 2026

When a shopper applies a Wrapped gift card at WooCommerce checkout, the balance is reserved against the card right away so it can't be spent elsewhere. If the order then fails, is cancelled, or is never placed because the shopper closed their browser, the balance is released back onto the card automatically and the card is detached from the order. The shopper has to re-enter the gift card code if they want to use it on a new attempt.

This article covers the free Wrapped Gift Card Redemption plugin. The WooCommerce Gift Cards extension and Smart Coupons handle redemptions in their own way (see Use Wrapped with the WooCommerce Gift Cards plugin and Use Wrapped with Smart Coupons for WooCommerce).

What triggers the release

What happened at checkoutWhen the balance is releasedWhat the shopper sees
The payment failed (card declined, 3-D Secure cancelled, gateway timeout)Immediately, when the order moves to FailedThe gift card field is empty on the next page load; they can enter the code again
The shopper selected Cancel in the gateway or you cancelled the order in WordPressImmediately, when the order moves to CancelledSame as above
The order was fully refunded in WordPressImmediately, when the order moves to RefundedThey see a refund as normal; the card used is back at its previous balance
The order sat unpaid long enough for WooCommerce's stock hold to expire (default 60 minutes)When WooCommerce auto-cancels the orderSame as above
The shopper closed their browser before placing the orderAfter 60 minutes, by a background check that runs every 10 minutesThey can retry at any time; if they try within an hour, the card still shows as redeemed

The release restores the full amount that was reserved. If the shopper used two cards, both are released.

How the detach step works

Along with releasing the balance, Wrapped removes the Gift Card line from the order and clears the applied-cards record. This matters because WooCommerce's Pay for order link lets a shopper retry a Failed order without restarting checkout. Without the detach, the order would still show the discount while the balance was already back on the card, so the shopper would pay less than owed. Detaching puts the full amount back on the order, so a retry is clean.

Wrapped writes a note on the order each time it releases a card:

  • "Wrapped gift cards reversed (failed): ABCD1234"
  • "Wrapped gift cards detached from order. The shopper must re-apply the card if they retry payment."

The note is visible to anyone who opens the order in WordPress.

What if the shopper comes back to a stale cart

If the shopper's browser still has the gift card applied when the hold has already been released (for example, they left a tab open past the 60-minute window), the plugin notices on the next cart or checkout page load:

  • The card is removed from the cart automatically.
  • A notice appears: "The gift card XXXXXX was released and is no longer applied to this order. Please re-apply it if you still want to use it."
  • The order total goes back up to the full amount.
  • At Place Order the plugin re-checks every applied card against Wrapped one more time. If any have been released in the meantime, the order is blocked with the same message and the shopper has to re-apply.

Belt and braces: if a stale card somehow still reaches order creation (unusual theme, cached cart, a non-standard client), Wrapped re-debits the card at order time so the ledger still matches what the shopper paid. If the card no longer has enough balance to cover the amount (because someone else spent it in the meantime), the order gets a note on it explaining what happened and the gift card is left as-is. Open the order in Sales channels › Check orders to see the note and decide how to handle it.

When the release does not happen

  • While the payment is still being attempted. A gateway that is slow but still running is not treated as a failure.
  • On the first decline if the gateway lets the shopper retry on the same checkout page. Several gateways do this (for example, re-entering card details after a decline without moving the order status). The balance stays reserved because nothing in WooCommerce has signalled that the checkout is over.
  • For orders that are still Pending payment past 60 minutes but have not been auto-cancelled. The release uses WooCommerce's status transitions, so a custom setup that keeps orders in Pending payment longer than the default stock-hold window will hold the balance for that longer window.

Common questions

A customer says their gift card isn't working. What do I check?

Open the card in Gift cards › All gift cards (open) and look at the timeline. If you see a redemption followed by a reversal within an hour, the balance was released and the shopper can use the card again. If you see a redemption with no reversal, the shopper is probably still inside the 60-minute window for an abandoned checkout, or the order is sitting in a status Wrapped hasn't picked up on yet. You can always reverse the redemption yourself from the card's timeline.

Can I release the balance sooner than 60 minutes?

Cancel or Fail the order in WordPress. Wrapped releases the balance as soon as the status changes, so you don't have to wait for the automatic sweep. Opening the order and selecting Change status to Cancelled does the job.

What if I want to keep the discount on a retry?

You can't carry it across. The detach step is what makes Pay for order safe, so a retry always sees the full amount. The shopper enters the gift card code again and the balance is reserved against the new attempt.

Does this change anything about successful orders?

No. A gift card applied to an order that goes to Processing or Completed behaves exactly as before. The release only affects orders that don't complete.

What if the automatic release fails?

The order gets a note saying which card the reversal failed on and the reason. The balance stays debited. Reverse the redemption from the card's timeline in Wrapped (open the card, find the redemption, select More actions › Reverse), or ask us to look at it (see Getting help).

Did this answer your question?