EAN-13 barcode generator

Generate an EAN-13 barcode with its check digit and download it as SVG.

5901234123457

Last updated: October 2026 · Report a calculation error

How an EAN-13 barcode is built

EAN-13 is the 13-digit barcode on products in shops. The first digits are the GS1 prefix of the country organisation that issued the number (for example 400–440 Germany, 482 Ukraine, 500–509 United Kingdom, 590 Poland), then the company and product number, and finally a check digit. The generator draws the code as an SVG, ready to print at any size.

Enter 12 digits and the tool adds the check digit. Enter 13 and it checks whether the last one is correct.

How the check digit is calculated

  1. Multiply digits in odd positions (1st, 3rd, 5th…) by 1 and digits in even positions by 3.
  2. Add up the results.
  3. The check digit is the number that brings the sum up to the next multiple of 10.

Example: for 590123412345 the sum is 83, so the check digit is 7 and the full code is 5901234123457. The check digit lets scanners catch a mistake in any single digit.

Can I make up my own product code?

Not for selling in shops. EAN numbers are issued by GS1 under a paid licence so that no code is ever duplicated — a made-up number may belong to another company. The generator is useful for internal labels (stock, inventory), testing and checking the check digit of existing codes.

Frequently asked questions

Does the prefix show where the product was made?

No — it only shows which national GS1 organisation issued the number. The product could be made anywhere.

What format is the download?

SVG — a vector image that stays sharp at any size. It opens in browsers, Word, Inkscape and Illustrator.

See alsoWhole category

  1. GN-01Password generatorGenerate a strong random password of any length and character set.
  2. GN-02QR code generatorCreate a QR code for any link or text and download it as a high-resolution PNG, with no watermark.
  3. GN-03Random number generatorPick one or more random numbers from any range, with or without repeats — fair and instant for draws, games and classrooms.
  4. GN-04Color palette generatorGenerate a random color palette with HEX, RGB and HSL codes and copy any color with one click.