UPC & EAN Barcode Generator
Build a real UPC-A or EAN-13 symbol in your browser and download it as vector SVG — sized in millimeters, at a magnification you choose, with the quiet zones already in the file. Leave the check digit off and we work it out; paste the whole number and we verify it and say plainly when it is wrong. Nothing uploads, and nothing here issues you a number: real GTINs are licensed from GS1.
Enter your UPC-A digits to build a barcode.
We do not certify files and we will not call one print ready. Whatever you build here, a human at SHIFT proofs it before it prints. Request a free quote →
A planning aid, not a quote — exact specs come with your quote. Request a free quote →
Barcode Generator FAQ
Built by SHIFT Design in Buffalo, MN — free to use, no sign-up. When you are ready to make it real, we design and print it.
The quiet zone is the empty margin either side of the symbol, and it is measured in modules rather than millimeters — 9 modules on each side of a UPC-A, 11 on the left and 7 on the right of an EAN-13. At nominal 100% size that is about 3 mm on a UPC-A, and it scales with the code: shrink the symbol and the margin shrinks with it, enlarge it and the margin has to grow too. Empty means empty. A keyline, a nutrition panel, an ingredient list, a fold, a can seam, or the edge of a colored block all count as intrusion, and a clipped quiet zone is the single most common reason a perfectly well-printed barcode will not read. On EAN-13 a small chevron sits after the last digit to mark where the right margin ends — that light-margin indicator is part of the specification, not decoration.
The X-dimension is the width of the narrowest bar, and every other dimension hangs off it. Nominal is 0.330 mm, which GS1 calls 100% magnification. The permitted range for a barcode that will cross a retail point of sale is 80% to 200% — an X-dimension between about 0.264 mm and 0.660 mm, giving a symbol somewhere between roughly 30 mm and 75 mm wide. Below 80% you are outside the specification and retailers can reject the packaging over it. Small is also where print stops being forgiving: at 80% on kraft, corrugated, or an absorbent uncoated face stock, ink spread eats a proportionally larger share of every bar. If the label has room, use it.
You can, and this tool will do it, but understand what you are giving up. GS1 publishes one bar height per magnification — 22.85 mm at 100% — and does not endorse cutting it. Bar height is not decoration: an omnidirectional scanner sweeps a pattern of lines across the symbol and needs vertical depth to land at least one clean pass through every bar. Take the height away and you take scan opportunities with it, which is why a short-barred code is the one that gets sawed back and forth at the register while the line builds. If the pack genuinely leaves no room, shorten the bars knowing the trade, and give the code the flattest, smoothest, highest-contrast spot on the package to make up for it. Better still, move something else.
Almost never the encoding, and almost always the printing or the placement. The usual suspects, in rough order of frequency: the quiet zone has been crowded by other artwork; the symbol was scaled below 80% to make it fit the space; the bars were shortened so far that an omnidirectional scanner cannot find a clean path across them; ink spread on an absorbent stock has fattened the bars into their neighboring spaces; or the symbol landed on a seam, a fold, a curve tight enough to distort it, or under a foil or gloss varnish that flares the scanner's own light straight back at it. Every one of those is a decision made in the artwork, which is why a barcode is worth looking at before the job prints rather than after.
There are two traps here and they catch people in opposite directions. The first is color physics: laser scanners read with red light at around 660 nm, so red, orange, yellow and pink behave like white to them and vanish completely when used for bars. Dark blue, dark green, dark brown and black absorb red and work. A barcode in the brand red is not a barcode. Backgrounds follow the same rule in reverse — they have to reflect, so white is safest, and dark, metallic or transparent substrates are where the trouble starts. The second trap is the build. In CMYK, set the bars to 100% K and nothing else: a rich black or a four-color build puts every bar edge at the mercy of press registration, and a bar that is sharp on one plate and a hair off on three others has soft, fattened edges. Leave the white behind it as unprinted stock or a clean knockout, never a tint.
You can make up twelve digits that pass the check-digit test — the arithmetic does not know or care who you are. What you cannot do is make up a number that belongs to you. GTINs are licensed from GS1, which issues each business a company prefix and lets you allocate item numbers underneath it, and retailers check. An invented number will either fail to resolve in their catalog or, worse, resolve to somebody else's product. There are two narrow exceptions: UPC-A number system 4, and EAN-13 prefixes in the 2 range, are reserved for a retailer's own internal use, which means in-store only. If your product is going anywhere near a register you do not own, the number comes from GS1. This tool encodes; it does not issue.
No, and this is the most durable myth in packaging. The leading digits are a GS1 prefix, and a prefix identifies the GS1 Member Organization that issued the company prefix — usually the country where the business registered, which has nothing necessarily to do with where the goods were made, packed, or shipped from. A company that registered with GS1 US carries a US-range prefix on products manufactured anywhere on earth. If you need to state country of origin, that is a label statement, not a barcode.
Behind the numbers
A UPC-A or EAN-13 symbol is 95 modules wide, and a module is simply the width of the narrowest bar. Bars and spaces are built from one, two, three or four modules butted together — there is no gap between characters and no separator to find. The scanner locates the symbol by its three guard patterns: a bar-space-bar 101 at each end, and a space-bar-space-bar-space 01010 through the middle. Between those guards sit twelve characters of seven modules each, and every single character is exactly two bars and two spaces. That constraint is what makes the code self-checking. Any element pattern that does not resolve to two bars and two spaces inside seven modules is not a character, so the scanner throws the read away rather than guessing at it.
Twelve characters — but EAN-13 carries thirteen digits. The extra one is never drawn. Each of the six left-hand characters can be encoded from one of two sets: an odd-parity set with an odd number of dark modules, and an even-parity set with an even number. The pattern of odd and even choices across those six characters spells out the first digit. LLGLGG means the symbol starts with a 1; LGGLGL means it starts with a 9; six odd characters in a row means it starts with a 0. Right-hand characters use a third set, the exact inverse of the odd set, which always begins with a bar and always ends with a space — that is how a scanner knows it just swept the symbol backwards and needs to reverse what it read. It also settles the thing people find confusing: a UPC-A is an EAN-13 whose first digit is zero. The bar patterns are byte-for-byte identical.
The last digit is arithmetic, not data. Weight the digits alternately by three and one, working leftwards from the check position, add them up, and the check digit is whatever carries that total to the next multiple of ten. On 03600029145 the weighted sum comes to 58, so the check digit is 2 and the full GTIN-12 is 036000291452. Change any single digit and the total falls off the multiple of ten, every time — that part is airtight. Transpositions are where it is weaker: swapping two neighbouring digits shifts the total by exactly twice their difference, so a swap of two digits five apart (0 and 5, 1 and 6, 2 and 7, 3 and 8, 4 and 9) sails straight through. Roughly one adjacent transposition in nine survives the test, which is worth knowing before you trust a number somebody read to you over the phone. And what a check digit can never do is tell you the number is yours — it is a parity test, not a registry lookup, and 000000000000 passes it cleanly. Real retail numbers are licensed from GS1, one company prefix per business, and no generator can issue one. This tool encodes a number you already hold.
Everything above is geometry with no size attached, and size is what actually decides whether the thing scans. The nominal X-dimension — the width of one module — is 0.330 mm, which GS1 calls 100% magnification, and the symbol is fixed at 113 modules across: 95 for the code plus the quiet zones, 9 modules either side on UPC-A, 11 left and 7 right on EAN-13. At nominal that is 37.29 mm wide, with bars 22.85 mm tall and 25.93 mm overall once the human-readable digits are counted in. Every other legal size is that same shape multiplied by a magnification between 0.80 and 2.00. Nothing else in the artwork is negotiable: the quiet zones stay empty, the bars stay dark on light, and the height is what lets an omnidirectional scanner find a clean path across the symbol. What is not fixed is bar width reduction, the deliberate thinning that compensates for ink spread on press — that belongs to the process, since flexo on corrugated behaves nothing like litho on a coated face stock, so tell us how it is printing and we will set it. Then size the label itself with the label size calculator, check the file against the print-ready files guide, and see product labels or the sticker material guide.
Ready to start your project?
Tell us what you need and we'll put together a custom quote — no cost, no commitment.