How do you prevent coupon fraud?

Check eligibility on the server at the moment of redemption. A check that runs only in the browser can be bypassed. Make single-use codes single-use by recording the redemption in the same transaction as the order. Limit code attempts per session to stop guessing. Tie new-customer offers to device, payment method and address as well as email.

Server-side eligibility is the foundation. The page can show whether a code looks valid, but the decision that changes the price has to be made by your order system using: who the customer is, what they have redeemed before, what is in the cart and which other discounts are present. Anything decided in the page can be altered by someone who sends the request directly.

Single-use codes fail in a specific way. If the system checks that a code is unused and then, as a separate step, marks it used, two requests sent at the same instant can both pass the check. Record the redemption and create the order in one database transaction, or lock the code while it is being redeemed, so the second request fails.

Guessing is automated. A script submits thousands of candidate codes to the endpoint that validates them. Limit attempts per session, account and device. Return the same message for every failure, so the endpoint does not reveal which codes exist but have expired or which are restricted to other customers.

Define a new customer by more than an email address. Compare the device, the payment method fingerprint from your payment provider, and the normalised delivery address against previous orders. Decide in advance how many matches make a customer returning, and apply the decision at redemption.

Write stacking rules into the order engine. State which discounts combine and which exclude each other, and test the combinations, including loyalty credits and gift cards.

Recheck after the cart changes. A code that requires a minimum spend should be validated again when items are removed, and a discount earned by an item should be reversed if that item is refunded.

Monitor redemptions as a set. Look at redemptions per code over time, per device, per address and per payment method. A change in audience warrants investigation; legitimate publicity can also change who uses a code.

Finally, test your own promotions the way an abuser would before launch: register twice, redeem in two tabs at once, edit the cart after applying the code, and call the validation endpoint directly.

How Kairal helps

Session linking connects recorded visits to devices and supplied user IDs. Compare the linked accounts with your own redemption records to investigate repeated claims. Your application still enforces eligibility, single use, expiry and discount combinations.

Session linking