Skip to product information
1 of 1
Published:2022.10.08

How to set parameters in a URL to automatically apply a coupon code in Shopify

How to set parameters in a URL to automatically apply a coupon code in Shopify

Applications

  • DiscountEdit
View full details

You may want to set a URL with a coupon (discount) applied to a QR code, but if the linked page has parameters, you need to be a little careful about how you write it. You need to change the first parameter in the redirect URL from "?" to "&".


How to set up a link to a specific page

URL format to display the page with the coupon code applied:
Code example (redirect to product detail page):


How to set up if the linked page contains parameters

Change the first parameter in the redirect destination to "&" instead of "?"

If the linked page is a free word search result, the URL is:
Example of code (redirecting to a page with parameters (free word search result page)):
Related Post