Ready to get started?Download WordPress

Plugin Directory

WooCommerce Product SKU Generator

Automatically generate WooCommerce product SKUs from the product slug and/or variation attributes.

Requires: WooCommerce 2.1+, Compatible with WooCommerce 2.2 & 2.3

Automatically generate a SKU for parent / simple products, variations, or both when the product is published or updated. Generated SKUs for parent / simple products will use the product slug for the SKU.

If the product is a variable product, this plugin can append attributes for each variation to the SKU to differentiate between them. If you opt to generate all SKUs, the variation attributes will be appended to the product slug. If you only generate variation SKUs, the variation attributes will be appended to whatever you set for the parent SKU.

IMPORTANT: The SKU field will be disabled for simple products and parent products if you generate them using this plugin. Your own SKUs previously assigned to products will be overridden if you update a product, and they will change if you change your product slug. Be sure you want to complete automate SKUs if you leave this enabled all of the time.

You can also selectively enable and disable the plugin if you don't want to override existing SKUs when saving products. You can view product documentation for help.


This plugin provides options to:

  • automatically generate simple / parent product SKUs when the product is published or updated using the product slug (filterable to use something like the ID if desired)
  • generate SKUs for product variations using the parent SKU + variation attributes
  • generate both the parent and variation SKUs automatically
  • use the bulk product update action to easily generate SKUs for products created before installing this plugin.

SKUs for all product types

The WooCommerce Product SKU generator allows you to determine whether all products, parent / simple products, or product variations should have automatically generated SKUs.

If parent /simple product SKUs are generated, product SKUs will be generated any time a product is published or updated. For example, a product with a slug 'wp-tee-shirt' will have an SKU of 'wp-tee-shirt' (even if this is a parent product of a variable product). The SKU can change if the product slug changes.

Variable Products

You can enable SKU creation for variable products under WooCommerce > Settings > Products as well. Should you choose to create unique SKUs for each product variation, the attributes for that variation will be appended to the parent SKU.

Let's say you generate SKUs for all products. For a variable product whose parent is 'wp-tee-shirt', the SKU will first use the parent slug, then append the attributes for each variation. For example, if the shirt has a small variation in white, the SKU for that variation will be 'wp-tee-shirt-small-white'.

If you only generate SKUs for variations, you can set the parent SKU. If the parent SKU for the same shirt is 1234, the generated SKU will instead look like '1234-small-white'.

If you only create parent / simple SKUs, you will be able to manually create your own variation SKUs, as these will not be overridden by saving or updating a product.

Bulk Updating

You can bulk add SKUs to products that you've created prior to installing this plugin. If you select the products you want to update, then bulk edit them, all you have to do is hit "Update". When the products are saved, SKUs will be generated for all products.

This action will also automatically generate the SKUs for product variations if you have them enabled.

More Details

Requires: 3.8 or higher
Compatible up to: 4.1.1
Last Updated: 2015-3-3
Active Installs: 1,000+


5 out of 5 stars


1 of 2 support threads in the last two months have been resolved.

Got something to say? Need help?


Not enough data

0 people say it works.
0 people say it's broken.