BLACK FRIDAY

&

CYBER MONDAY

Up to

25% OFF Sale

On WordPress & CRM Products

Limited time Offer

Knowledge Base

How to Import Variable Products in WooCommerce using Single CSV File

Efficiently import your WooCommerce products and variations using just one CSV file with the WP Ultimate CSV Importer.

To import WooCommerce Variable Products, navigate to the WP Ultimate CSV importer Pro -> Import/Update/. Upload the desired CSV file with your WooCommerce Products and Variations. Map the incooming CSV data elements with its corresponding WP fields. Then manage the media handling, configure the import settings and run the import.

Step 1: Prepare the Import file for your WooCommerce products. #

First, prepare your import file with your desired WooCommerce Products and Variation fields. Ensure your CSV file should have the Parent SKU field for seamless product import. Here, in the single CSV file import of WooCommerce Variable products, you can define the Product attribute in a separate Column as Product Attribute 1, Product value 1, Product Attribute 2, Product value 2, etc.

  • Example:
    • Attribute Name 1: Color
    • Attribute Value: Red, Blue, Green
    • Visibility: 1 (Enabled), 2 (Disabled)
  • Product Type: Specify the product type as 8 for variations.
WooCommerce-Variation-Single-CSV-import-Sample-CSV-file

Step 2: Upload your CSV file #

  1. Install and activate the WP Ultimate CSV Importer Pro plugin on your WordPress site.
  2. Then, navigate to WP Ultimate CSV Importer Pro -> Import/Update 
  3. You can upload your import file in any of the four file upload methods from the left-side menu.
  4. As we need to upload the CSV file, select the file from the desktop. Click on  Browse and select the CSV file you have prepared for WooCommerce Product and Variation.
WooCommerce-Variations-import-Single-CSV-Upload-CSV-file
  1. Then, choose whether you’re importing new products or updating existing records:
    1. Select the Fresh Import option if you are creating new product records.
    2. Select the Update Content option if you are updating existing product records.

      6.  Choose the data type as “WooCommerce Product” from the drop-down

WooCommerce-Variations-Single-CSV-import-Select-data-type

Step 3: Map Your Fields #

If your CSV field header exactly matches the WP field name, then the plugin will auto-map those CSV fields with the WooCommerce product fields. Otherwise, you need to map manually with any of two Mapping methods. 

 Advanced Mode: Select fields from the dropdown menu to match CSV columns with WooCommerce product fields.

Drag-and-Drop Mode: Drag fields from the CSV column list and drop them into the appropriate product attribute section.

Both modes allow you to easily configure your mappings, so choose the one that best suits your business needs.

You can also add custom field mapping for product attributes and variations.

Note: Ensure that the headers in your CSV file match exactly with the headers in our plugin. This will enable automatic mapping. If the headers do not match, you’ll need to map them manually using the dropdown menu.

WooCommerce-Variation-import-Single-CSV-Mapping-Method

Mapping  Product Attributes #

  1. In the  Product Attributes section, you’ll see a set of templates based on the maximum number of attributes across all products in your CSV.
    • For example, if you have a product with 3 attributes and another product with 2, the plugin will display 3 templates on the attributes sections.
  2. Here, on the three templates, each template corresponds to a product attribute name ( Product Attribute 1, Product Attribute 2, Product Attribute 3), product attribute value etc. Here Map your attributes accordingly.
WooCommerce-Variation-Single-CSV-Map-Product-attribute
  1. If your CSV file contains fewer attributes than the maximum number of templates shown, you can leave the extra templates unmapped. For example, if you have only 2 attributes in the CSV, you can ignore the 3rd template. Or you can delete the extra template by clicking on the delete icon corresponding to the Attribute template. 
WooCommerce-Variation-Import-Single-CSV-Delete

Example Mapping:

  • Product Attribute 1: Attribute Name (“Color”), Attribute Value ( “Red, Blue, Green”), Visibility (“1” for enabled)
  • Product Attribute 2: Attribute Name (e.g., “Size”), Attribute Value (“S, M, L”), Visibility (“1” for enabled)

Add More Templates (if necessary) #

If your CSV file includes variable products with more attributes than your templates currently allow, you can add additional templates by clicking the Add button.

Step 4: Save Mapping Template #

Once you’ve mapped all necessary fields, click Save Template and give it a unique name for future use. Click on Continue.

WooCommerce-Variation-Single-CSV-Save-Mapping-template

Step 5: Configure Media Handling and Import Settings #

  1. Configure any necessary media handling options (e.g., images) for your products.
WooCommerce-Variation-Import-Single-CSV-Manage-media-upload
  1. Configure the import settings that best suit your needs.
  2. Once done, click on Import to begin the import process.
WooCommerce-Variation-Import-Single-CSV-Import-Configuration-Settings

Step 6: Finalizing the Import #

Your WooCommerce products and variations will now be successfully imported using a single CSV file.

Once the import is completed, you can view the imported products and variations directly from the import summary by clicking on View variations or View products

You can also verify the imported result by navigating to WooCommerce-> Products

WooCommerce-Variation-Single-CSV-import-Import-Summary
WooCommerce-Variation-Import-Imported-Variation
WP Ultimate CSV Importer Pro

WP Ultimate CSV Importer Pro

Get Ultimate CSV/XML Importer to import data on WordPress faster, quicker and safer.

Advanced Topics #

1. Exporting WooComerce Variable Products #

To export a WooCommerce Variable Product in one go, follow the below steps:

  1. Navigate to WP Ultimate CSV importer Pro -> Export
  2. Select the Data type to Export as WooCommerce Products and click on Continue
export-woocommerce-products-&-variations
  1. On the Export configuration settings, enter the File name and choose the desired File type.
  1. You can also use advanced filter options to export your product field data more specifically.
  2. Select “Export CSV file to Google Sheets” to export your CSV file in Google sheet.
woocommerce-variation-export-configuration

Note: To enable this option, you need to link the Google Sheets in our plugin settings. For that, navigate to WP ultimate CSV importer Pro -> Settings-> Google Sheets. Enter the client id, client secret and redirect url of your desired Google sheet to link it with the plugin.

link-google-sheet
  1. On enabling the “Export data with Specific Inclusion” section you can export the specific product attributes. For example: Select product_attribute 1, product_value 1, product_visible 1.
product-attribute-fields
  1. Once done click on Export.
woocommerce-variationd-click-export
  1. You can download your export file or export your file on Google Spreadsheets.
woocommerce-variations-download-csv-file
woocommerce-variations-exported-csv-file

2. Handling Complex Product Variations #

When importing variable products with multiple attributes, ensuring that the variations are correctly linked to the parent product is crucial. Let’s see how we can manage  more complex scenarios:

Multiple Attributes for Variations #

If your variable products require several attributes (e.g., Color, Size, Material), ensure that each variation in your CSV file is properly aligned with the corresponding parent product.

  • CSV Structure: Each product variation needs to be specified in the CSV with its unique combination of attribute values, such as:
    • Product SKU(for the parent product)
    • Attribute Name: Color
    • Attribute Value: Pink, Medium
    • SKU: The variation-specific SKU
    • Price, Stock, etc.

Multiple Attribute Sets for Different Variations #

For products that have more than one set of variations, you must map multiple attributes and values in the CSV. For each variation, define the attribute name, value, and other relevant data. For example, if a T-shirt is available in different colors and sizes, map the multiple attributes corresponding to the CSV.

  • Example CSV Columns:
    • Parent Product SKU: T-Shirt-001
    • Product Attribute 1: Color | Value: Red
    • Product Attribute 2: Size | Value: S
    • Variation SKU: T-Shirt-001-S-Red

This allows you to import all variations in a single CSV while ensuring that each variation is linked to the correct parent product.

3. Handling Custom Attributes in Variations #

WooCommerce allows you to define custom product attributes that go beyond the default attributes like size, color, etc. When importing such custom attributes in a CSV file, the process requires some additional steps:

Custom Attributes Mapping #

If your product uses custom attributes (such as material or custom design), you need to ensure that these attributes are included in the CSV file for each variation.

  • Example:
    • Product Attribute 1: Custom Design
    • Product Attribute Value: Floral Print

In the mapping process, you’ll need to map each custom attribute to the respective field in WooCommerce.

Advanced Attribute Visibility #

You can also control the visibility of custom attributes for each variation (e.g., show or hide certain attributes from the product page).

  • Visibility Option: You can use the visibility codes 1 (visible) and 2 (hidden) to control whether certain attributes appear on the front end.

Note: For every attribute import, you need to follow the above steps given in this guide to import WooCommerce Product and Variations. That is select the WooCommerce type as Variations and the product type number as 8 to indicate variations.

4. Bulk Importing Variation Prices and Stock Levels #

In some cases, you may need to adjust prices or stock levels for each variation dynamically. This can be achieved easily by including the relevant columns in your CSV file for each variation.

  • CSV Structure for Pricing:
    • Parent SKU: T-Shirt-001
    • Variation SKU: T-Shirt-001-S-Red
    • Variation Price: $17.99
    • Variation Stock: 50

If you’re working with products that have numerous variations (e.g., different sizes, colors, and materials), you can bulk update variation prices and stock by ensuring these columns are populated in your CSV.

  • Bulk Update Example:
    • Parent Product: T-Shirt-001
    • Variation SKU: T-Shirt-001-S-Red, Price: $17.99, Stock: 50
    • Variation SKU: T-Shirt-001-M-Red, Price: $19.99, Stock: 45
    • Variation SKU: T-Shirt-001-L-Blue, Price: $21.99, Stock: 30

This method allows you to update prices and stock for multiple variations in one import process.

5. Handling Out of Stock Variations #

Sometimes you may want to import variations that are out of stock. These variations can be included in the CSV, but they should be marked correctly to avoid issues during the import process.

  • Out-of-Stock Variations:
    • Stock Status: Mark the stock status as Out of Stock in your CSV file for variations that aren’t available for sale.
    • Example:
      • Variation SKU: T-Shirt-001-S-Red, Stock Status: Out of Stock

By doing this, you can ensure that the variation is imported, but it won’t show as available for purchase on the front end until stock is replenished.

WP Ultimate CSV Importer Pro

WP Ultimate CSV Importer Pro

Get Ultimate CSV/XML Importer to import data on WordPress faster, quicker and safer.

FAQ: WooCommerce CSV Variation Import #

1. How do I structure my CSV file for products with variations?

For each product with variations, you need to specify the parent product as well as each variation. Ensure that each variation is identified by a unique SKU and has its row in the CSV. Additionally, each row should include:

  • Product ID (for the parent)
  • Variation-specific attributes (e.g., color, size)
  • SKU for each variation
  • Price, stock, and other variation-specific data

2. Can I import multiple variations for the same parent product in one CSV file?

Yes, you can import multiple variations for the same parent product in one CSV file. Each variation should be listed on a separate row with the same parent product identifier (typically the product SKU) and the unique variation attributes.

3. Do I need to link variations to the parent product manually?

No, WP Ultimate CSV Importer automatically links the variations to their parent product based on the product SKU. The parent product must have a unique identifier (SKU), and each variation must be associated with the same product ID or SKU.

4. What happens if I leave some attribute mapping templates empty?

If you leave any attribute mapping templates empty during the mapping process, those attributes will not be imported. However, you can safely leave some templates empty if your CSV file does not include all attributes defined in the plugin. It’s flexible and doesn’t impact the import process as long as the required fields are mapped correctly.

5. Can I import variations without having to create individual products for each?

Yes, when using WP Ultimate CSV Importer, you only need to import the parent product once. The variations are treated as child products and linked to the parent automatically. Each variation can share the same parent SKU while having its attributes and pricing.

6. How do I update existing variations without duplicating them?

To update existing variations, make sure the SKU and Product ID match the existing variations in your WooCommerce store. When importing, select the “Existing” import option. This will update the variation data (like price, stock, or attributes) without creating duplicates.

7. How do I bulk import product variations with custom prices and stock?

To bulk import variations with custom prices and stock, ensure that each variation has its own row in the CSV file with the relevant SKU, Price, and Stock values. The CSV should look like:

  • Parent Product SKU
  • Variation SKU
  • Price
  • Stock Quantity

This way, the variations will be updated or created with their custom prices and stock levels during the import.

8. Can I import variations with different images?

Yes, you can import product variations with different images by including the image URLs in the corresponding columns for each variation. Make sure to map the image fields correctly during the import process.

9. What is the issue with assigning SKUs to products now?

Earlier, when you assigned a Product SKU to one product and tried to assign the same Product SKU to another product, then it won’t allowed, as each product should have a unique Product SKU. But on recent updates, if you assign a product SKU to a product that is already assigned to another product, then the plugin will still import the product, but the Product SKU field will appear as empty in the imported data.

10. How do I prevent the empty SKU issue?

To avoid importing a product with an empty SKU, ensure that each product has a unique SKU. That is, if you need to change or update a Product SKU for a product, then ensure that the new SKU is not assigned to any other product. You can verify the existing SKUs in your system before making any changes to avoid an empty SKU issue.

11. Can I still assign the same SKU to multiple products?

No, each product should have a unique SKU. The recent update has allowed the system to import the product even if an SKU is duplicated, but the SKU will appear empty. For proper data management, it’s recommended to keep SKUs unique for each product to avoid confusion and potential data issues.

New Release Unveiled:

WP Ultimate CSV Importer v8.0