Image tools / Barcode
Barcode Generator
Generate a barcode in six common formats and download it as SVG or PNG. The check digit is worked out for you, and nothing you type leaves this browser.
Set up: choose a barcode type
Code 128 takes any printable ASCII, at any length.
Ready. Nothing is uploaded.
Result and downloads
Scan the downloaded image with a separate device before you print a run of labels.
Which barcode type should you choose?
Most people arriving here need Code 128 for an internal label, or EAN-13 and UPC-A for something sold in a shop. The rest of this table is the short version of a decision the other generators leave you to make on your own.
| Type | Encodes | Length | Use it for |
|---|---|---|---|
| Code 128 | Any ASCII character | Any length | Logistics, shipping and internal tracking. The usual default when nothing forces another choice. |
| EAN-13 | Digits only | 12 digits, or 13 with the check digit | The global retail standard, scanned at the till outside North America. |
| UPC-A | Digits only | 11 digits, or 12 with the check digit | North American retail. It is an EAN-13 with a leading zero. |
| EAN-8 | Digits only | 7 digits, or 8 with the check digit | Small retail packaging with no room for a full EAN-13. |
| Code 39 | A–Z, 0–9, space and - . $ / + % | Any length | Industry, defence and older inventory systems. Widely readable, but wide for its data. |
| ITF-14 | Digits only | 13 digits, or 14 with the check digit | Shipping cartons and outer cases, printed large on corrugated board. |
The check digit, and why barcodes fail to scan
EAN-13, UPC-A, EAN-8 and ITF-14 all end in a check digit: one digit derived from the others so a scanner can tell a misread from a real code. Getting it wrong is the most common reason a generated barcode will not scan, so this generator computes it rather than trusting you to.
Enter the digits without it and the check digit is added. Enter the full code including it and the digit is verified, and if it disagrees the page says which digit it should have been and shows the arithmetic. The working appears under every generated code, so you can check it by hand.
Code 128 has a check symbol too, but it is hidden: the scanner verifies it and nobody prints it. Code 39 has no required check digit at all.
Can you make your own UPC or EAN for retail?
No. Barcode numbers for products sold through shops or large marketplaces come from GS1, which issues your company prefix; a number you invent may already belong to someone else and will be rejected. This generator will happily draw any number you give it, which is exactly what you want for internal stock, asset tags, library codes, shelf labels and testing — and is not a substitute for registering.
Free SVG, and why that matters
SVG is a vector image: it stays sharp at any size, which is what a printer wants for a label. Most free generators give you a PNG and keep SVG for a paid plan. Both are free here, and both are produced in this page.
Privacy and print quality
The barcode is drawn in your browser from the value you type. Nothing is uploaded by this tool, which matters because product codes and stock identifiers are commercially sensitive. The site’s usual page-visit analytics may run.
Leave the pale margin either side of the bars — the quiet zone — clear of text and artwork, or scanners will struggle. Print black on white at the largest size the label allows, and avoid scaling the image unevenly.
Need a 2D code instead? Open the QR code generator →
Checking which characters Code 128 can carry? Open the ASCII table →
Updated