Limiting Product Availability by Country

Use product attributes to customize which countries can see and purchase your product. This may be due to contractual distribution rights, export restrictions, or risk concerns. 

Customers from restricted countries will not see the selected products when visiting your website. If a customer adds the product to their cart and then changes the order country to a restricted country, FastSpring automatically removes the product from their order. 

Follow the steps below to configure country exclusions for your product:

  1. Navigate to the details page of the product you wish to limit.
  2. At the top, right corner, click Options > Custom Attributes. The Custom Attributes (Advanced) dialog appears.
  3. In the Key field, type “conditions” (without quotes)
  4. In the corresponding Value field, enter a JSON object that specifies the countries to include or exclude followed by “country” and the ISO code.
    • If the format is incorrect, your store will ignore the exclusions.
    • {exclude:{countries:[“AT”,”GB”]}}
  5. Save your changes.


To only sell a product to specific countries, and limit all other customers from purchasing it, replace “exclude” with “include” in your JSON object. 

Example: Exclude 2 specific countries

{
    "products": [
	    {
		    "product": "falcon",
			"attributes": {
			    "conditions":"{exclude:{countries:["AT","GB"]}}"
			}
    	}
	]
}

Example: Exclude all countries except one

{
    "products": [
	    {
		    "product": "falcon",
			"attributes": {
			    "conditions":"{include:{countries:['US']}}"
			}
    	}
	]
}