Labels, tickets, inventory tags, library books, event wristbands — sooner or later everyone needs a barcode, and paying for barcode software to make one is unnecessary. This free barcode generator draws real, scannable barcodes right in your browser using the open-source JsBarcode library. Choose from four formats — Code 128, EAN-13, UPC-A and Code 39 — type your content, adjust the size, and download a crisp PNG or an infinitely scalable SVG. Retail codes even get their check digit calculated for you: give the tool the first 12 digits of an EAN-13 and it adds the 13th.
How the barcode generator works
The generator runs the JsBarcode library (version 3.12.1) locally in your browser. When you press the button, the tool first validates your input against the rules of the format you picked: EAN-13 and UPC-A must be digits of the right length, Code 39 accepts only its smaller character set, and Code 128 takes almost any keyboard text. For the two retail formats it also does the check-digit maths — a weighted sum of the digits that produces the final digit scanners use to confirm a code was read correctly. If you enter 12 digits for EAN-13, the tool appends the correct 13th digit and tells you it did. If you enter all 13 and the last one is wrong, it refuses and explains why, which quietly saves you from printing a broken code. The bars themselves are drawn as an SVG graphic, so the PNG download is rendered from a vector original and stays sharp at any size.
How to use it
Type the text or number you want to encode, choose a format (the notes below will help), set the bar width and height, and decide whether the human-readable text should appear under the bars. Press Generate barcode, check the preview, then download the PNG for documents and labels or the SVG for print work and design tools. Print a test copy and scan it with any phone barcode app before printing a whole batch — paper, ink and print size all affect real-world scanning.
Which format should you choose?
Code 128 is the safe default for your own labels: it encodes any text compactly and every modern scanner reads it. EAN-13 is the retail standard outside North America — use it when a shop system asks for a product code, and remember that codes for products sold in shops normally come from GS1; this tool creates the barcode graphic and the correct check digit, but it does not register a product number for you. UPC-A is the North American twin of EAN-13, with 12 digits. Code 39 is the oldest and simplest format — limited to capitals, digits and a few symbols, but readable by absolutely everything, which is why warehouses and libraries still love it.
Barcode Generator – frequently asked questions
Is this barcode generator free?
Yes, completely — no sign-up, no watermark and no limit on how many barcodes you make or download.
Will the barcodes actually scan?
Yes. They are drawn to the real format specifications, including check digits for EAN-13 and UPC-A. Always test-print and scan one copy before a big batch, since printers and paper vary.
Can I sell products with an EAN-13 made here?
The graphic and check digit will be correct, but retail product numbers must be registered through GS1 in your country for shops to accept them. For internal labels, stock, events and testing, you can use the codes straight away.
PNG or SVG — which should I download?
PNG for documents, spreadsheets, labels and websites. SVG for anything going to a printer or a designer, because it scales to any size without going blurry.
Related tools
Generador de Códigos de Barras — versión en español · Food Barcode Lookup — Nutrition by Barcode · UUID Generator.
Embed this tool on your website — free
Copy the code below to add this working tool to your own page. A small credit link stays with it — that’s all we ask.
