Skip to content
Install free on Shopify

Discount codes on rentals

Rentshelf prices rentals on its server, so a Shopify discount code entered at the final checkout may not match the rental line. Rentshelf checks the code itself before checkout and applies the discount to the eligible rental lines. You keep creating codes in Shopify Discounts as usual.

Rentshelf needs Shopify’s read_discounts permission to read your codes. If it is missing, the Rentshelf dashboard and Settings show Enable discount codes on rentals – grant discount access. Select Grant discount access and approve the request in Shopify.

Without this permission, codes are passed to Shopify checkout unchanged.

  • The Rentshelf discount field. On the cart page, Rentshelf adds a Discount code field above the checkout button (the input has the data-rp-discount-code attribute).
  • Your theme’s cart discount field. If the customer already applied a code with the theme’s own cart discount field, Rentshelf remembers it and uses it at checkout, even if Shopify removed it from the cart because the rental line had no price yet.

A code typed in the Rentshelf field takes priority over a code from the cart.

Rentshelf applies Shopify amount-off codes (percentage or fixed amount) that target all products, specific products or variants, or collections. It checks the code’s status and dates, usage limit, once-per-customer rule, minimum purchase amount or quantity, and currency. A fixed amount can apply once per order (split across eligible rental lines) or to each item.

  • Collection codes. Rentshelf checks whether each rental product is in the code’s collections. If Shopify does not return the collection list to the app, the code is passed through to Shopify checkout, which evaluates it there.
  • Customer-limited codes. Codes limited to certain customers or segments, and once-per-customer codes, need a known customer. A logged-out customer sees Log in to use this discount code.
  • Other codes that Rentshelf cannot evaluate (for example other discount types) are pre-filled at Shopify checkout, exactly as if the customer typed them there.

Orders that used a Rentshelf-applied code get a rentshelf-code:CODE tag, and those orders count toward the code’s usage limit and once-per-customer rule.

A code typed into the Rentshelf field gets direct feedback before payment. For example:

SituationMessage
The code doesn’t existThis discount code doesn’t exist. Please check the spelling.
Customer must log inLog in to use this discount code.
ExpiredThis discount code has expired.
Not active yetThis discount code is not active yet.
Usage limit reachedThis discount code has reached its usage limit.
Already used by this customerYou have already used this discount code.
No eligible rental in the cartThis discount code doesn’t apply to the rentals in your cart.
Minimum not metYour cart doesn’t meet this discount code’s minimum requirement.

A code carried over from the theme’s cart field never blocks checkout. If it does not apply, the customer continues without it.

The discount applies only to the rental amount. A security deposit is its own line and is never reduced by a code. With a booking deposit (part payment today), the discount taken at checkout is limited to the rental amount charged today, and the full discount is recorded on the booking.

  1. In Shopify Discounts, create a test code limited to one rental product or collection.
  2. Add the rental to the cart, enter the code in the Discount code field and go to checkout. The rental line should show the discount; the deposit line should not.
  3. Try a misspelled code and confirm the error.
  4. Try a once-per-customer code while logged out and confirm the login message.