How do I create SKUs for my product variants?
Last updated
A name, or a short code you already use for it.
Separate values with commas. The order here is the order in the code.
Choose once and keep it for the whole catalogue.
6 to 40 characters. Leave blank for no limit.
Enter a product and at least one option with values, then press Generate SKUs.
How a variant code is put together
A SKU generator gives every variant of a product its own short stock code built from readable parts, so an organic crew tee in black, size medium becomes ORGCRWTEE-BLK-M, and the same inputs always produce the same code, which keeps a spreadsheet, a warehouse shelf and a Shopify variant in step.
The short forms follow common warehouse conventions rather than a published standard, and the rules are fixed, so a code never changes between runs.
A stock keeping unit is an internal label, never shown to shoppers unless you choose to. Every code here has the same anatomy, and each part is meant to be read by a person picking an order as well as by a spreadsheet.
- Product part
- The front of every code, shared by all the variants of one item. Type an existing short code such as MUG12 and it is kept as it is; type a name and it is shortened to a few readable letters per word.
- Options
- Up to 3 things a variant can differ by, such as colour, size or material, each with up to 20 values. The order you list them is the order they appear in the code.
- Value codes
- Short forms for each value. Common sizes and colours use the forms warehouses already read, so Black is BLK and Extra large is XL; anything else is shortened to its first letters. Numbers such as 32 or 500ML are kept whole.
- Separator and case
- A hyphen, underscore, full stop or nothing between the parts, and upper or lower case. Pick once and keep it for the whole catalogue: mixing styles is how the same item ends up with two codes.
- Length limit
- Optional. Some label printers, marketplaces and inventory tools cap how long a SKU can be. If the codes would run over, the product part is shortened first; the option codes never are, because cutting them is what creates duplicates.
- Clash handling
- When two values shorten to the same letters, such as Blush and Blossom, the second gets a digit in place of its last letter. When two whole codes would still match, a number is added to the end. Either way the result says what it changed.
Nudgesmart is available on the Shopify App Store. Browse the template library or see what it costs.
Five catalogues, coded
Invented products. Each row runs through the same function as the generator above, so the codes, the clash notes and the lengths here are exactly what it produces for those inputs.
| Catalogue | Options | Variants | First and last SKU | What the generator did |
|---|---|---|---|---|
| A T-shirt in three colours and four sizesOrganic Crew Tee | Colour: Black, White, Navy · Size: S, M, L, XL | 12 | ORGCRWTEE-BLK-SORGCRWTEE-NVY-XL | Nothing to fix. Longest code 16 characters. |
| An existing code, one optionMUG12 | Glaze: Sea glass, Sand, Slate | 3 | MUG12-SGMUG12-SLT | Nothing to fix. Longest code 9 characters. |
| Two values that abbreviate alikeLinen Napkin Set | Colour: Blush, Blossom, Sage | 3 | LNNNPKSET_BLSLNNNPKSET_SGA | Blossom became BL2 to avoid BLS |
| A tight length limitWaxed Canvas Tote | Colour: Olive, Tan · Size: Small, Large | 4 | WXDC-OLV-SWXDC-TAN-L | The product part was shortened from WXDCNVTTO to WXDC to fit 10 characters. |
| Three options, lower caseTrail Harness | Size: XS, S, M, L · Colour: Red, Blue · Buckle: Metal, Plastic | 16 | trlhrn-xs-red-mtltrlhrn-l-blu-pls | Nothing to fix. Longest code 17 characters. |
What to settle before importing SKUs
It cannot see the SKUs you already have
Codes are unique within one run of the generator. If a different product already uses ORG as its product part, this page has no way of knowing. Check the new codes against your existing export before importing.
Changing a live SKU has knock-on effects
Inventory apps, fulfilment partners and marketplace listings may key on the old code. Renaming an existing variant can break those links, so use the generator for new products or a planned clean-up, not a casual edit.
Short forms are a convention, not a standard
BLK for black is widely read, but there is no single rulebook. If your supplier or warehouse already has its own codes, match theirs instead of these.
The order of options is a decision
Colour before size groups a shelf by colour; size before colour groups it by size. Choose the order that matches how stock is physically stored, then keep it.
SKU questions
What is a good SKU format for a Shopify store?
Short, readable parts in a fixed order: the product first, then each option, joined by one separator. Avoid spaces, and avoid letters that are easily misread on a label. The same item must always get the same code, which is why this generator uses fixed rules and no randomness.
Should SKUs include the colour and size?
For a product with variants, yes. Each variant is a separate thing on a shelf, so each needs its own code, and putting the option in the code means a picker can read BLK-M without looking anything up.
Why does it stop at 200 rows?
Because the number of variants multiplies fast. Three options with ten values each is a thousand combinations, which is almost never one real product. The generator lists and exports the first 200, tells you the full total, and suggests splitting the item.
What happens when two values abbreviate to the same letters?
The first keeps its code and the next gets a digit in its place, so the codes stay the same length and stay unique. The result lists every value it changed, so you can rename one instead if you prefer.
Can I import these SKUs straight into Shopify?
The CSV has one row per variant with the option values and the SKU, which you can paste into the SKU column of a product export and import back. Match the option names and values to the ones already on the product, or the rows will not line up.
Is my product data sent anywhere?
No. The codes and the CSV are built in your browser, and the download is created there too.
A tidy catalogue does not stop a browser from leaving empty-handed.
Nudgesmart builds a popup for the visitor who browses and leaves, starting from a ready-made template grouped by industry and campaign type.