How to Import Custom Data From a CSV File Using WooCommerce Default Importer

If you’re looking to import your custom field data via a CSV file, this guide will show you how. By using Custom Fields for Variations and the default import feature in WooCommerce, importing your custom fields is fairly simple.

This is particularly useful if you are setting up your custom fields on a testing site and want to import everything over to a live site.

First, we need to put the CSV file (containing your custom field data) together.

Preparing the CSV file

We need to create a CSV file with a minimum of 2 columns. The first column (A – pictured below) should be variation_id. The second column (B – pictured below) should be the Meta ID for the custom field. The Meta ID is a unique name given to your field label or name.

Note: You can add more than one custom field into this file.

To find the Meta ID for your custom field, take the following steps:

  1. From your WordPress dashboard, go to Products > Variation Field Groups.
  2. Then click to edit one of your existing field groups.
  3. You should then see a page called Edit Variation Field Group, hover over one of your Field Labels and click Edit.
  1. This should open a popup which contains all your field information. Scroll down until you see Field ID or Meta ID. The information in this section is your Meta ID. Add this line to your CSV file.

Importing the data

Once your CSV file has been created, next you’ll want to import the data into your site.

To do this, take the following steps:

  1. From your WordPress dashboard, go to Products > All Products and click the Import button at the top of the page.
  1. Then, click the Choose file button to upload your CSV file. Once uploaded, click the Continue button.
  1. Next you’ll need to select the ID for the variation_id column and Import as meta data for the custom fields. Then click the Run the importer button.
  1. That’s it, your custom fields will now be imported into your site.

WooCommerce Custom Fields for Variations

Easily add custom fields to your product variations; the perfect way to display organised additional product data to your customers.

Was this helpful?

Please let us know if this article was useful. It is the best way to ensure our documentation is as helpful as possible.