Give the product a short base code, list its attributes such as colour and size with a code for each option, and choose a separator. The generator writes one SKU for every combination, adds an optional sequence number, flags any duplicates and lets you download the list as a CSV to import into your store or spreadsheet.
| Code | Who makes it | Format | Used for |
|---|---|---|---|
| SKU | You, the seller | Any letters and digits you choose | Your own stock tracking and reports |
| GTIN-12 (UPC) | Licensed through GS1 | 12 digits | Scanning at checkout, mainly North America |
| GTIN-13 (EAN) | Licensed through GS1 | 13 digits | Scanning at checkout, mainly outside North America |
| GTIN-8 | Licensed through GS1 | 8 digits | Small items at checkout |
| GTIN-14 | Licensed through GS1 | 14 digits, never starts with 0 | Cases and other groupings of a product |
Updated
A SKU (stock keeping unit) is your own name for one exact sellable thing: the medium blue shirt, not just the shirt. Because you invent it, it can carry meaning, so anyone in the stockroom can read TEE-BLU-M and know what to pick. The trick is a consistent pattern, which is what this tool enforces.
Base code (product line): TEE
Separator: -
Colour: Blue=BLU, Sage=SAG, Black=BLK
Size: Small=S, Medium=M, Large=L
Add a sequence number
9 SKUs
| SKU | Colour | Size |
|---|---|---|
| TEE-BLU-S | Blue | Small |
| TEE-BLU-M | Blue | Medium |
| TEE-BLU-L | Blue | Large |
| TEE-SAG-S | Sage | Small |
| TEE-SAG-M | Sage | Medium |
| TEE-SAG-L | Sage | Large |
| TEE-BLK-S | Black | Small |
| TEE-BLK-M | Black | Medium |
| TEE-BLK-L | Black | Large |
Built in your browser; nothing is uploaded.
The same rule in a few lines of JavaScript, for when you import products from a spreadsheet or a supplier file.
flatMap builds the combinations one attribute at a time. Run it in your browser console to see the list.
const base = "TEE";
const attrs = [["BLU", "SAG", "BLK"], ["S", "M", "L"]];
const skus = attrs.reduce(
(combos, codes) => combos.flatMap((c) => codes.map((code) => [...c, code])),
[[base]],
).map((parts) => parts.join("-"));
console.log(skus); // ["TEE-BLU-S", "TEE-BLU-M", ... 9 SKUs]
Decide the parts once and write them down: product line, then each attribute in a fixed order, then an optional number. TEE-BLU-M, TEE-BLU-L and MUG-SAG-12 all follow the same rule, so a new product never needs a meeting.
Fixed-length codes per attribute (three letters for colour, one or two for size) keep SKUs lined up in a list, which makes mistakes easier to spot.
If you sell through other retailers or marketplaces that ask for a UPC or EAN, you need GTINs licensed through GS1 for each variant. Keep a column in your sheet that maps each SKU to its GTIN, then print barcodes from the GTIN, not the SKU.
For your own shelves and bins, you can print a barcode that encodes the SKU itself, because that code is only ever read inside your business.
A SKU is an internal code you create for your own inventory, and two shops can give the same item different SKUs. A UPC is a GTIN-12, a 12-digit number licensed through GS1 that identifies the product the same way everywhere. GS1 US sells single GTINs from $30 with no renewal fee, as of October 2026.
No. Google's gtin attribute takes real GTINs such as UPC, EAN, JAN, ISBN or ITF-14, and its help page says to only provide a GTIN if you are sure it is correct. Put your SKU in the product's own SKU or ID field instead.
Shopify calls SKUs an optional code that identifies the product within your business and says each SKU needs to be unique for effective tracking. Barcodes are a separate field.
No. They are built in this browser tab. Download the CSV or copy the list before you close the page.
Yes. Fields that contain a comma or a double quote are wrapped in double quotes, with inner quotes doubled, following RFC 4180, and lines end with CRLF.
Related: Barcode generator, Product label maker, Packing slip generator, Shopify pricing guide.
Start for free or see all free tools. We.Inc is free to start, with no card needed. AI building is on paid plans from $20 a month.
We.Inc is an AI-powered website builder you can resell under your own brand. Launch a branded client dashboard, bill on Stripe Connect, and deliver AI-generated websites in minutes. White-label plans start at $99 a month for 25 client sites, with a 7-day free trial and no per-site fees.