Block Payment Gateway for specific product in Specific Country

Tfitzpatrick
Visitor
1 0 0

Hello,

Our team is currently trying to block the payment gateway for a specific product in specific countries and regions.

There are two separate scripts on Shopify that allow these to happen separately but not at the same time.

Any help would be greatly appreciated!

Links to current scripts:

https://help.shopify.com/en/manual/checkout-settings/script-editor/examples/payment-gateway-scripts#...

&

https://help.shopify.com/en/manual/checkout-settings/script-editor/examples/payment-gateway-scripts#...

Thank you in advanced

Replies 2 (2)

Ivy
Shopify Staff
1033 82 130

Hi @Tfitzpatrick! Thanks for reaching out here.

I would love to know the context behind why you are trying to achieve this? What is the end goal?

Carrying this out would require advanced coding, and so requires hiring a Shopify expert to carry this out. Would removing the specific countries from the approved shipping zones be an option? Then customers from these countries will not be able to complete checkout, they will see an error stating that their region is not supported. This guide outlines how to do this.  Another option which may work for is using a third party app that can block access from specific countries, here's an example of an app that carries this out. 

I hope this helps!

Ivy | Social Care @ Shopify


Out Of Office

-Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit the Shopify Help Center or the Shopify Blog



ohengroup
Visitor
3 0 0

I would like to use this script because there is no way to only limit specific payment gateways to specific countries. This is a core feature that is missing.