# Discount codes with GWPs

Check whether a discount code can be used alongside a Gift with Purchase and why the gift may disappear.

A discount code can often be used with a GWP because the GWP adds a gift item instead of acting only as a visible discount line.

### Why a code can still break the GWP

The code may change the cart enough that the GWP no longer qualifies.

Most often, one of these happens:

- the code drops the cart below the GWP threshold
- the shopper no longer matches **Customer Eligibility**
- another promotion takes precedence

### Test it in the right order

1. **Test the GWP without a code**
   Build a cart that clearly qualifies and confirm the gift appears.

2. **Apply the code**
   Enter the code and check whether the cart still qualifies.

3. **Recheck the threshold**
   If the GWP uses **Minimum Spend**, confirm the discounted cart is still above the required amount.

4. **Recheck the customer**
   If the GWP uses member tiers, tags, or logged-in rules, confirm the customer still matches those settings.

5. **Pause other promotions if needed**
   Retest with only the GWP active if results are inconsistent.

### Common reasons the gift disappears

#### The code changes the subtotal

This is the most common cause with spend-based GWPs.

#### The GWP is restricted

If the GWP is limited to **Members**, **Logged in only customers**, or tagged customers, not every shopper will qualify.

#### Multiple offers are overlapping

If another promotion targets the same cart, checkout may choose a different outcome.

### Best setup for predictable results

Use a simple GWP rule.

A clear spend threshold is easier to test than several overlapping product rules.

Use **Customer Eligibility** to separate audiences rather than relying on overlapping discounts.

### If the GWP is members-only

Check that at least one membership tier is selected.

If no tier is selected, the GWP will not trigger for anyone.

### Related guides

- [Gift with Purchase](https://www.roadmap.so/docs/discounts-and-gwp/using-gwp-and-discounts/gift-with-purchase)
- [GWP not showing at checkout](https://www.roadmap.so/docs/discounts-and-gwp/troubleshooting/gwp-not-showing-at-checkout)
- [Discounts not applying correctly](https://www.roadmap.so/docs/discounts-and-gwp/troubleshooting/discounts-not-applying-correctly)
