Barcode Generator | QR Code
generation / barcode Barcode Generator
Generate barcodes in a wide range of symbologies — EAN, UPC, Code 128, ITF, MSI, pharmacode, and many more. Set the dimensions, choose your own colors, and download the result as SVG, which stays sharp at any print size. Enter several lines to produce a batch of barcodes and download them together. Everything is rendered in your browser.
Configuration options
Scale sets the width of the narrowest bar and height sets the bar height. Both matter more than they look: a barcode is read by measuring the ratio of bar widths, so printing one too small is the most common reason a symbol fails to scan.
Supported barcode types
| Symbology | Encodes | Length | Standard |
|---|---|---|---|
| EAN-13 | Digits | 13 incl. check | ISO/IEC 15420 |
| EAN-8 | Digits | 8 incl. check | ISO/IEC 15420 |
| UPC-A | Digits | 12 incl. check | ISO/IEC 15420 |
| UPC-E | Digits | 8, zero-suppressed | ISO/IEC 15420 |
| Code 128 | Full ASCII | Variable | ISO/IEC 15417 |
| Code 39 | Digits, A–Z, some symbols | Variable | ISO/IEC 16388 |
| ITF-14 | Digits | 14 incl. check | ISO/IEC 16390 |
| GS1-128 | Structured data with AIs | Variable | GS1 General Specifications |
The retail symbologies are not interchangeable with the general-purpose ones. An EAN-13 identifies a product registered with GS1 and is meaningless if invented; Code 128 encodes whatever you give it, which is what makes it right for internal labelling and wrong for anything crossing a till.
How barcodes work
A linear barcode encodes data in the widths of its bars and the spaces between them, read along a single axis. A scanner sweeps across it, measures the pattern of light and dark, and decodes the sequence. The height carries no information at all — it exists purely so the scanner still finds a readable path if the beam crosses at a slight angle.
That one-dimensional nature is the main limit. A linear barcode typically holds between 8 and 30 characters, where a QR code can hold thousands, because it uses both dimensions. Barcodes persist because they are fast, cheap to print, and read reliably by inexpensive laser scanners.
Choosing a symbology
The symbology is the encoding scheme, and picking the right one matters more than any other setting — each was designed for a particular industry with its own constraints.
Retail products
EAN-13 is the global standard for retail, and UPC-A is its 12-digit North American counterpart. EAN-8 and UPC-E are compressed forms for packages too small for the full symbol. These require registered company prefixes if the product is to be sold through retail channels — you cannot simply invent a number.
General purpose
Code 39 (ISO/IEC 16388) is the older of the two, encoding digits, capitals and a few symbols at low density; Code 128 supersedes it for most uses by encoding the full ASCII range far more compactly.
Code 128 is the usual choice for anything not sold at retail. It encodes the full ASCII set, is compact, and handles letters as well as digits. Code 39 is older and less dense but remains common in defense and automotive contexts.
Logistics
Interleaved 2 of 5 encodes digit pairs efficiently and is used on shipping cartons. ITF-14 is the standard for shipping container labels, encoding the case-level identifier for a product.
Specialist
MSI Modified Plessey appears in inventory and shelf labeling. Pharmacode is used in pharmaceutical packaging, where it was designed to be readable even when printed with poor contrast on a production line.
Check digits
Most retail and logistics symbologies include a check digit — a final digit calculated from the preceding ones. The scanner recomputes it and rejects the read if it does not match.
This is why a misread barcode almost always produces no result rather than the wrong result, which matters a great deal at a checkout. It also means an invented number will often simply fail to encode: the check digit has to be arithmetically correct, not merely present.
Printing barcodes that scan
- Keep the quiet zone.The blank margin either side of the symbol tells the scanner where the code begins and ends. Cropping it is the most frequent cause of failure.
- Use maximum contrast.Black on white is ideal. Red bars are effectively invisible to a red laser scanner, so avoid inverted or low-contrast color schemes.
- Do not scale non-uniformly.Stretching horizontally distorts the bar-width ratios the decoder depends on. Scale both axes together, or adjust height separately.
- Prefer SVG for print.Because it is vector output, it stays crisp at any size — bar edges remain sharp where a scaled-up raster image would blur them.
- Mind the substrate.Glossy, reflective, or curved surfaces scatter the beam. Matte labels read far more reliably.
- Test before a print run.Scan the actual printed output, not the screen, with the equipment that will be used in practice.
Common uses
- Retail products— EAN and UPC codes for items sold through stores.
- Inventory and asset tracking— Code 128 labels linking physical items to database records.
- Shipping and warehousing— ITF-14 and Code 128 on cartons and pallets.
- Libraries and archives— item identifiers for lending systems.
- Manufacturing— serial numbers and batch codes for traceability.
- Pharmaceuticals— pharmacode on packaging for automated verification.
Frequently asked questions
Can I make my own retail barcode?
Which symbology should I pick?
Why won't my barcode encode?
Barcode or QR code?
Does the height matter?
Is my data sent anywhere?
Standards and references
- ISO/IEC 15420 EAN/UPC bar code symbology specification 2009
- ISO/IEC 15417 Code 128 bar code symbology specification 2007
- ISO/IEC 16388 Code 39 bar code symbology specification 2007
- GS1 GS1 General Specifications — application identifiers and check digit calculation