1. Home
  2. Docs
  3. Country Based Restrictions for WooCommerce
  4. CSV Upload Restrictions

CSV Upload Restrictions

With the bulk upload feature you can use the native WooCommerce Product CSV Importer and Exporter to add restrictions data to multiple products at once using CSV file rather than having to go into each product individually.

Preparing the CSV file

The CSV file contains 4 columns, you must use the same column headers names and include all columns:

  • Simple Product :
    • ID – WooCommerce product id or SKU
    • Meta: _fz_country_restriction_type – add Restriction type (included = 1, excluded  = 2, – keep blank OR 0 to remove the rule).
    • Meta: _restricted_countries – add countries code.(i.e. IN,IL,GB)
  • Variable Product :
    • ID – WooCommerce variable id.(i.e. #9479 from Variations)
    • SKU – WooCommerce main product sku.
    • Meta: _fz_country_restriction_type – add Restriction type (included = 1, excluded  = 2, – keep blank OR 0 to remove the rule).
    • Meta: _restricted_countries – add countries code.(i.e. IN,IL,GB)
  • Example(for variable Product) – You want to upload variable product, so you can see in below image. In image Second row is parent id of variable product. and no. of 3,4,5 rows is child id(i.e. #9479 from Variations) of parent id.

We recommend using the following CSV editors:

  • Google Docs
  • OpenOffice

If possible, avoid Microsoft Excel due to formatting and character encoding issues that will fail your upload.

Uploading the CSV file

Import CSV file from WordPress admin(in Woocommerce > products > Import).

Then, Go to import to select CSV file and check the Update existing products option to update only existing product and click on continue.

blank

Then, the below image is show mapping column from CSV file.

And, Click on Run the importer to import CSV data.

blank
Was this article helpful to you? Yes No

How can we help?