Skip to content

Shopify

Add GoPayLocal PPP discounts to your Shopify store.

Add GoPayLocal to your Shopify store by adding the banner script to your theme.

  1. Get your API key from the GoPayLocal dashboard

  2. Add the script to your theme

    Go to Online Store > Themes > Edit Code and open theme.liquid (or layout/theme.liquid).

    Add the script before the closing </body> tag:

    <script
    src="https://api.gopaylocal.com/v1/banner/script.js?key=gpl_pk_live_abc123"
    async
    ></script>
  3. Configure discounts in the GoPayLocal dashboard

GoPayLocal works with Shopify’s native discount code system. Create discount codes in Shopify that match the codes GoPayLocal generates:

  1. In GoPayLocal, set your coupon prefix (e.g., “PPP”)
  2. GoPayLocal generates codes like PPP-INDIA-30, PPP-BRAZIL-25
  3. Create matching automatic discounts in Shopify, or use Shopify Functions for dynamic discounts

Shopify supports applying discount codes via URL:

https://yourstore.myshopify.com/discount/PPP-INDIA-30

This redirects the customer and automatically applies the discount to their cart.

To only show the banner on your pricing/product pages:

{% if template == 'product' or template == 'collection' %}
<script
src="https://api.gopaylocal.com/v1/banner/script.js?key=gpl_pk_live_abc123"
async
></script>
{% endif %}