• So I was looking for a way to import products into WooCommerce that also had custom fields, and this plugin worked!

    Some caveats…

    – The CSV file needs to be UTF-8.
    – The header row of CSV file should NOT have double-quotes around each field.
    – Each row in the CSV file (except the header row) should have double-quotes around each field.
    – Each field in each row must use a comma as the seperator.
    – To import to a custom field called my_custom_field just use that exact name in the header field.
    – To import to a woocommerce custom field, you can use the following in the header row fields (these are just some of them):
    For PRICE use: _regular_price
    For SKU use: _sku
    For STOCK MANAGEMENT (yes or no) use: _manage_stock
    For STOCK QUANTITY use: _stock
    – I think post_id and post_name are required in the header row fields, but you can leave them blank and they will be automatically be generated.
    – post_category generates a category under POSTS instead of PRODUCTS, so not sure how to get around this yet.

    Here is sample CSV file (copy and paste into text editor):

    post_title,post_content,post_category,post_type,post_status,post_id,post_name,post_author,post_date,post_tags,_sku,_regular_price,_stock,_manage_stock,my_custom_field
    “my test widget”,”a test widget”,””,”product”,”draft”,””,””,””,””,””,”test-widget-sku”,”25″,”2″,”yes”,”some data”
    “my other test widget”,”another test widget”,””,”product”,”draft”,””,””,””,””,””,”another-test-widget-sku”,”35″,”3″,”no”,”some data”

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter Jeff Sherk

    (@jsherk)

    I figured out how to import the WooCommerce Product Categories … you need to use a field header with the name tax_product_cat
    You can specify multiple categories by just comma seperating them so like this “category1,category2”

    So here is another sample CSV file that includes the woocommerce category:

    post_title,post_content,post_type,post_status,tax_product_cat,_sku,_regular_price,_stock,_manage_stock,_custom_field_name,post_category,post_id,post_name,post_author,post_date,post_tags
    "my test widget","a test widget","product","draft","category1","test-widget-sku","25","2","yes","10","","","","","",""
    "my other test widget","another test widget","product","draft","anotherCategoy","another-test-widget-sku","35","3","no","10","","","","","",""

    that’s a great addition, thanks for sharing

    Moderator Jan Dembowski

    (@jdembowski)

    Forum Moderator and Brute Squad

    @jsherk I have archived your how-to blog post. This site is not your blog, please do not post like that again here.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Importing products for WooCommerce including custom fields’ is closed to new replies.