Checkpost

How to block checkout for specific countries on Shopify

Short answer: Prevent orders from being placed with a shipping address in countries you cannot or do not want to serve. In Checkpost, choose “Block shipping to specific countries” from Templates, adjust the values, test it, then save and enable the rule.

The problem

Some destinations bring high fraud rates, sanctions risk or carriers you can't use. Even when you don't offer shipping there, orders can still slip through with digital products, local pickup or misconfigured shipping zones.

How to set it up

  1. Install Checkpost from the Shopify App Store.
  2. Open Templates and choose Block shipping to specific countries.
  3. Replace the country codes with the ISO codes you want to block.
  4. Use Try this rule to test a sample cart, then click Save rule.

The rule

Checkout is blocked when all of these conditions is true:

Shoppers see: “Sorry, we don't ship to this country.” at the country field, once they reach checkout.

Rule definition (JSON)
{
  "name": "Blocked countries",
  "match": "all",
  "conditions": [
    {
      "kind": "text",
      "field": "ship_country",
      "op": "equals_any",
      "values": [
        "RU",
        "BY"
      ]
    }
  ],
  "message": "Sorry, we don't ship to this country.",
  "target": "countryCode",
  "runOn": "checkout"
}

Where this rule works

These are cart and checkout validations, including supported accelerated checkouts. They are current-cart policies; they do not track previous purchases of a SKU. Shopify excludes POS, recurring subscription orders and native pre-order/Try Before You Buy flows from this API. See Shopify's validation compatibility.

Tips

Can you do this without an app?

Shopify only offers shipping rates for countries in your shipping zones, so physical products usually can't be shipped elsewhere. A checkout rule adds an explicit, explained block and also covers pickup, digital and zero-rate edge cases.

FAQ

Does this use the shopper's IP location?

No. It checks the country of the shipping address entered at checkout. To restrict by the storefront market a shopper is browsing, use the Market country condition instead.

Can I show a different message per country?

Yes. Create one rule per country (or group of countries), each with its own message.

Related rules

Add block shipping to specific countries to your store