~/online-free-barcode-generator qr code bulk qr vcard qr ☕ Support me apps ← back to terminal
NAME

Free barcode generator online — Barcode generator — EAN-13, UPC, Code 128, GS1 & more

SYNOPSISbarcode [create|batch|labels] data
NOTESruns in this tab · nothing you type is uploaded · 47 barcode types · size set in millimetres for your printer
Ready.
Image—
Printed size—
Narrowest bar—
Margin—
—
Save

Guide — a print-ready barcode in five steps

The barcode is drawn by your own browser. The page loads the open-source barcode code it works with from public CDNs, and that is the only thing that travels.

1Pick the type

Press a button under What is it for? or open Barcode type. A shop till needs EAN-13 (UPC-A in North America) with a GS1 number. For your own labels Code 128 is the right default, and QR or Data Matrix hold more in less space.

2Type the data

Type 12 digits and the 13th, the check digit, is added. Paste all 13 and the page checks yours instead. For pallet and medicine labels the GS1 builder turns a GTIN, expiry date, batch and serial into correct Application Identifiers.

3Set the size in millimetres

Choose the narrowest bar, the height and the empty margin, and the resolution of your printer. The page snaps every bar to whole printer dots and tells you when you are below the retail minimum. Print-safe fixes it in one press.

4Save the picture

Download a PNG that opens at its real size, an SVG in exact millimetres, a JPG, or copy the picture or the SVG code straight into your document.

5Batch or label sheet

Batch turns a pasted list or a run of serial numbers into a ZIP. Label sheet places them on A4, Letter or a label roll, to print at 100% or save as a PDF.

Quick reference

RETAILSold in shops
EAN-13
Europe and most of the world
UPC-A
North America
EAN-8, UPC-E
Very small packs
ISBN, EAN-5
Books, with a price add-on
LOGISTICSWarehouse and shipping
Code 128
Letters and digits, compact
GS1-128
Batch, expiry and serial
ITF-14
Outer cartons
Code 39
Older systems
2DMore data, small space
QR
Links, read by every phone
Data Matrix
Small parts, medicine packs
PDF417
Licences, boarding passes
Aztec
Tickets, no margin needed
KEYSShortcuts
1 2 3
One barcode, Batch, Label sheet
Ctrl+Enter
Download PNG, ZIP or PDF
F
Full screen
?
Show all shortcuts

Barcode generator, explained

This is a barcode maker for people who have to print the result. You pick a type, type the number, and the barcode is drawn at once with the right check digit. What sets it apart from most free generators is that the size is in millimetres: you say how wide the narrowest bar must be, how tall the bars are and how large the empty margin is, you say what resolution your printer has, and the page makes a picture that prints at exactly that size, with every bar a whole number of printer dots wide. Bars of unequal width are the usual reason a printed barcode will not scan, and this removes it.

Everything happens in your browser. The numbers, batch codes and serials you type are not sent anywhere, there is no account, no watermark and no daily limit. That makes it practical for product codes, asset tags, pharmacy batches and anything else you would rather not paste into somebody else's website.

47 types

EAN, UPC, ISBN, Code 128, Code 39, ITF-14, GS1-128, GS1 DataBar, Data Matrix, QR, PDF417, Aztec and six postal codes, all in one list.

Check digits

Type 12 digits and the 13th is added. Type all 13 and the page checks yours and offers the fix when it is wrong.

Size in millimetres

Bar width, height and margin in mm, for 203, 300 or 600 dpi, with the GS1 retail range checked and a print-safe button.

GS1 builder

A GTIN, expiry, batch, serial, weight and count become correct Application Identifiers for GS1-128, DataBar and GS1 Data Matrix.

Batch

Paste a list, open a CSV or generate serial numbers, up to 500 at a time, and save them as a ZIP of PNG or SVG files.

Label sheets

A4, Letter, Avery-style grids and label printer rolls. Print at 100% or download a PDF.

Which barcode for which job

Two questions settle it nearly every time. Is it going to be scanned at a shop till? Then you need EAN-13, or UPC-A in North America, and a number that GS1 has licensed to you. Is it for your own use, such as asset tags, shelf labels, work orders and warehouse bins? Then Code 128 is the right default: it takes letters and digits, it is compact and it carries its own check character. Everything else in the list is a special case of one of those two, or a 2D code for when the data will not fit in a row of bars.

TypeHoldsLengthCheck digitTypical use
EAN-13Digits13Yes, added for youRetail products worldwide, books
UPC-ADigits12Yes, added for youRetail in the US and Canada
EAN-8, UPC-EDigits8 (UPC-E: 6 or 8)YesVery small retail packs
ITF-14Digits14Yes, added for youShipping cartons and cases
Code 128Full ASCIIAny, keep it shortBuilt inAsset tags, logistics, internal labels
GS1-128Application IdentifiersAnyBuilt in, plus the GTINPallet and case labels with batch and expiry
Code 39, Code 93Capitals, digits, symbolsAnyOptional / built inOlder industrial and government systems
Codabar, MSI, PharmacodeDigits (and a few symbols)Any / 3 to 131070DependsLibraries, shelf labels, pharma packaging lines
GS1 DataBarGTIN, plus AIs when expanded14 and moreYesLoose produce, small healthcare items
Data Matrix, GS1 Data MatrixText or bytesAbout 2,300 charactersReed–SolomonParts, medicine packs
QR, Micro QRText or bytesUp to about 3,000 bytesReed–SolomonLinks and text for phones
PDF417, AztecText or bytesAbout 1,800 / 3,000Reed–SolomonLicences, boarding passes, tickets

For links, Wi-Fi and contact cards with a logo in the middle, the QR code generator gives you more control than a general barcode page can. Reading a barcode from a picture is a job for the QR and barcode scanner.

Retail, GS1 and ISBN

A barcode for a shop till is a number, and the number is licensed. The GTIN comes from GS1, the company prefix in it is yours alone, and retailers check it. This page draws a valid symbol from any 12 or 13 digits and it will scan, but only a number you own is yours to sell with. Made-up numbers are fine for tests, mock-ups and internal use. For anything internal, such as warehouse labels, asset tags, event tickets and library codes, no registration is needed at all.

The first digits are the GS1 prefix, which names the GS1 office that issued the number and not the country where the product was made. An ISBN starts with 978 or 979 and is an EAN-13: choose ISBN and the hyphenated number is printed above the bars as on a book cover, and add an EAN-5 next to it for the price. A magazine uses an ISSN behind the prefix 977, often with an EAN-2 for the issue. A UPC-A is an EAN-13 with a leading zero, and a UPC-E is a UPC-A squeezed into 8 digits for a tiny pack, which scanners expand again before looking it up.

Every sellable variant needs its own GTIN, since a different size, colour or multipack is a different product to a till. The same item can carry several symbols: an EAN-13 on the consumer pack, an ITF-14 on the outer case, which is made to print on corrugated cardboard and is framed by a bearer bar, and a GS1-128 on the pallet label with batch and expiry.

Check digits and data rules

A check digit is computed from all the other digits so that a scanner can tell it misread. For an EAN-13 the digits are weighted 1, 3, 1, 3 and so on from the left, the weighted digits are added, and the check digit is what makes the total a multiple of ten. For 590123412345 the sum is 60, so the check digit is 0. UPC-A, EAN-8 and ITF-14 use the same scheme. You never have to do the sum: press Add check digit, or just type one digit short. If you type the full number and the last digit does not match, the page shows the digit it should be and offers to fix it.

Each type has rules and the page names the one you broke: EAN-13 wants 12 or 13 digits, EAN-8 wants 7 or 8, UPC-A 11 or 12, ITF an even number of digits, and Codabar must start and end with A, B, C or D. Code 128 takes essentially any ASCII and Code 39 takes capitals, digits and - . $ / + % space. Accented letters and emoji are not part of the linear codes. For those, and for anything longer than about 20 characters, use a 2D code such as Data Matrix or QR, which handle UTF-8. If you type only digits, the page also tells you which retail type has that length and offers to switch.

Size in millimetres and what dpi does

A barcode scans or fails because of one number, the X-dimension: the width of the narrowest bar. Everything else, the total width, the margins and the height, is a multiple of it. The generator therefore asks for it directly, as bar width in millimetres, and works out the rest. The default of 0.33 mm is the nominal size of an EAN-13. GS1 allows retail symbols to be scaled from 80% to 200%, which is 0.264 mm to 0.660 mm, and the page tells you whether you are inside that range. Below 80% a retailer's verification can reject the pack.

The empty margin is counted in bars. Without it the scanner cannot find the edges, and it is the most common reason a well-printed barcode refuses to scan: somebody cropped it tight or drew a frame around it. An EAN or UPC wants 11 bars on the left and 7 on the right, Code 128 and most others at least 10. The default is 10, and the size note warns when you go lower. The height matters too: a shorter bar is harder to hit with a scanner held at an angle, so cut it only for internal labels.

The picture you save is made for your printer. At 300 dpi a dot is 0.085 mm, so a bar of 0.33 mm cannot be exactly 3.9 dots wide; the page rounds it to 4 dots, shows you the real width (0.339 mm) and draws every bar and space with that same whole number of dots. That is why the same barcode looks crisp on a printer, whereas one scaled up from a small picture has soft, uneven bars. For a 203 dpi thermal label printer choose 203. The PNG stores its resolution, so Word, Pages and Illustrator open it at the real size, and a JPG stores it too. The SVG carries its size in millimetres and stays sharp at any magnification, which makes it the best choice for artwork and for print shops.

Colours need care. Scanners read contrast, usually in the red part of the spectrum, where red bars look white. Black on white is the one safe combination; dark blue or dark green on white usually works; red, orange and yellow do not, and neither does anything on a dark background. The page shows the contrast ratio and warns about light bars on a dark background. A barcode on a phone screen scans with a camera but may not with an older laser scanner, and a night filter that tints the white kills contrast.

GS1 Application Identifiers

GS1-128 is Code 128 with a function character at the start and data arranged in Application Identifiers: (01) for the GTIN, (17) for an expiry date as YYMMDD, (10) for a batch and (21) for a serial number. That is how a receiving system knows that six digits are a date and not a weight. GS1 DataBar Expanded, GS1 Data Matrix and GS1 QR Code carry the same strings. When you pick one of them the GS1 data form appears: enter the GTIN with or without its check digit, dates from a calendar, and a batch, serial, net weight in kilograms and count, and the page writes (01)09501101020917(17)280531(10)ABC123 into the field for you. The brackets are for people. The symbol itself holds no brackets: the page encodes the separators the standard requires after variable-length fields. The page also checks the GTIN inside (01) and (02) and tells you the correct check digit when it is wrong, since a wrong one is rejected by every scanner that validates.

Batch and serial numbers

The Batch tool turns a list into barcodes in the type and size you set under One barcode. Put one value on each line, or value,caption when you want text under the label, or open a CSV or TXT file whose first column is the value and the second the caption. To number things, type a prefix, a suffix, a start number, how many and how many digits, and the page writes SN-000001, SN-000002 and so on, adding them to the list or replacing it. Up to 500 lines are used; the first 120 are shown as cards and all of them go into the file. A line that cannot be encoded is not hidden: it gets a red card that says why, and the valid ones are still made, so one typo in 300 rows does not cost you the whole run.

Save the result as a ZIP of PNG pictures at your printer resolution or as SVG vectors. Every file is named with its number and its value, and a list.csv in the ZIP lists the files, values and captions, ready for a mail merge or a database import.

Label sheets and PDF

The label sheet puts barcodes on a page of labels. Choose a layout: A4 with 3 × 8 labels, the common Avery-style grids of 21, 14, 8 and 65 labels (L7160, L7163, L7165 and L7651 sizes), Letter 5160 and 5163, a label printer roll of 100 × 150, 50 × 30 or 102 × 51 mm, or enter your own columns, rows, label size, margins and gaps. Fill it with the single barcode repeated, or with the Batch list with any number of copies, start at label 7 to use up a half-used sheet, and show or hide the caption and the outlines. The preview is drawn to scale. A barcode that is larger than its label is shrunk to fit and you are told by how much, so the size you set is never changed in silence.

Print uses your browser's print window: set the scale to 100% and switch off fit to page, or every barcode will be resized. Download PDF makes the same pages as a PDF with the right paper size, ready for a print shop or a different computer. Print one page on plain paper first and hold it against the labels, because printers differ by a millimetre or two and thirty seconds saves a sheet of stock. Label names such as Avery are used only to describe the size of the grid; they are not endorsed by, or connected with, those companies.

Privacy and what the page requests

The barcode is drawn in this tab, from the characters you typed. Nothing you type, no batch list and no file is uploaded. What the page downloads, the first time it needs it, is open-source code: JsBarcode for the common linear codes and bwip-js for the rest, both from jsDelivr (with unpkg as backup), JSZip from cdnjs when you save a ZIP, and pdf-lib from unpkg when you save a PDF. The type you choose decides which engine loads, and the others never do. The font comes from Google Fonts. Those servers see a request for a library file and your IP address, as any website does, and nothing about your numbers. Page statistics come from SimpleAnalytics, which uses no cookies. The page keeps your settings and your last ten barcodes in the browser's local storage, under the keys jb-barcode-ui and jb-barcode-history, plus jb-theme for light or dark. Press clear beside Recent to wipe the history.

When a barcode will not scan

Check in this order. First the margin: is there clear white space on both sides, with no border, text or artwork touching the bars? Second the size: is the narrowest bar at least what the size note shows as safe, and does the printout measure what you expect? Third the contrast: dark bars on a white background, never red. Fourth the print: sharp bars, not smudged or filled in, and plain paper rather than glossy. Last the type, since a scanner set for retail EAN may simply ignore Code 39. Nine failures out of ten are the first two.

If the scanner shows a different number from the one you encoded, it is usually the scanner's setting: a UPC-A read as EAN-13 gains a leading zero, and a UPC-E arrives expanded to its 12 digits. Both are correct. A retailer that rejects a barcode that scans fine on your desk is grading to ISO/IEC 15416, which scores edge contrast, decodability and defects as well, so printing under 80% size, ink that spreads on absorbent packaging and artwork that eats the margin are the usual causes. Ask for a verification report instead of guessing. If a picture looks soft when enlarged, you scaled up a raster: save the SVG instead, or choose a higher resolution. If nothing is drawn after you pick a type, the engine for it could not be loaded from its CDN, and a blocker or an offline connection is the usual reason; the other types of the same engine keep working once it has loaded.

More free tools

This page makes barcodes. For links, Wi-Fi and contacts see the QR tools below, and find more in the full list of tools.