Skip to contentSellstamp

Barcode generator

Make a CODE128, EAN-13, UPC-A, EAN-8 or CODE39 barcode, with the check digit worked out for you, and download it as PNG or SVG.

13 digits — or type the first 12 and the check digit is worked out for you.

The narrowest bar. 2 or more survives being printed and photocopied.

Keep this on for retail. It is what a cashier types when a scan fails.

Type a value.

We’ll send you tips and updates from Sellstamp. Unsubscribe any time.

Stays on your device

Everything runs in your browser. Nothing you type is sent anywhere unless you choose to email yourself the result.

Naming something to sell?

Sellstamp gives it a storefront, a checkout into your own payment account and automatic delivery. Open a free store

How to use it

  1. Pick the format: CODE128 for your own labels, EAN-13 or UPC-A for retail.
  2. Type the value. For EAN-13, twelve digits are enough: the thirteenth is calculated.
  3. Set the bar width (2 or more prints reliably) and the height.
  4. Download the PNG or SVG and test-scan the printed label.

The check digit is the part that goes wrong

An EAN-13 is not thirteen free digits. The last one is computed from the first twelve: each digit is weighted 1, 3, 1, 3 from the left, the weighted total is summed, and the check digit is whatever takes that sum up to the next multiple of ten. A scanner recomputes it on every read and rejects the code if it disagrees.

That is why this tool works it out rather than trusting what you typed. Enter twelve digits and it appends the thirteenth and tells you it did. Enter thirteen that do not agree and it refuses, and says which digit would have been right — because a mismatch usually means a typo somewhere in the middle of the number, and silently rewriting the last digit would turn a caught mistake into a barcode that scans perfectly as a different product.

Which format to use

EAN-13 and UPC-A are retail barcodes, and the numbers in them are allocated — a GS1 prefix identifies the company, and you have to be a member to have one. Making a valid EAN-13 here does not make it yours. For internal use — stock, shelf labels, asset tags, anything scanned only by your own system — CODE128 is the right answer: it takes letters and digits, has no length limit, and nobody has to allocate you a number.

Printing one that scans

Keep the bar width at 2 px or more, do not scale the image non-uniformly, leave the white space at each end alone, and print it black on white. Barcodes fail in exactly the ways you would expect — stretched, shrunk, low contrast, or printed over a texture — and a test scan of the real label takes ten seconds.

Questions

How is the EAN-13 check digit calculated?

The first twelve digits are weighted 1, 3, 1, 3 and so on from the left and added up; the check digit is whatever takes that total to the next multiple of ten. Type twelve digits and the tool adds it.

Can I make my own EAN or UPC numbers?

You can make a barcode that scans, but retail numbers are allocated: the GS1 company prefix identifies the owner, and you need a GS1 membership to have one. A valid number made up here does not belong to you.

Which barcode should I use for my own stock?

CODE128. It takes letters and digits, has no fixed length, and nobody has to allocate you a number.

Why does the tool refuse my 13-digit EAN?

Because the last digit does not match the first twelve. That usually means a typo in the middle of the number, so the tool shows which check digit would be right instead of silently changing it.

How big should I print a barcode?

Keep the narrowest bar at 2 pixels or more, never stretch the image in one direction only, keep the white space at both ends, and print black on white.