Free 30-minute introductory call: find out what you can automate.

Free tool

Validate an EAN code and calculate the check digit

Check whether an EAN-13, EAN-8, UPC-A or GTIN-14 is valid, calculate a missing check digit, and validate a whole list in one go.

One code per line, or paste a column from Excel. Spaces and dashes are ignored; with several columns we use the first non-empty cell. Up to 5,000 lines.

What do you want to do?

Result

Enter a code and choose Validate, or load the example.

Runs entirely in your browser: what you enter is not sent to us or stored.

Checking an EAN code: how to use the checker

This EAN checker tells you whether a barcode number is valid and calculates the correct check digit. Paste one code or a whole column of codes into the input field and choose Validate. The checker recognises the type by the number of digits: 8 digits is an EAN-8, 12 a UPC-A, 13 an EAN-13 and 14 a GTIN-14. Spaces, dashes and dots are ignored, so 978-0-306-40615-7 or 8711 0000 0000 7 are recognised just fine. If you copy several columns from Excel, the tool uses the first non-empty cell on each line.

For a single code you see straight away whether it is valid, what the correct check digit is and which GS1 prefix it contains. For a valid EAN-13 or EAN-8 we also show a preview of the barcode. For a list you get a table with the status per line, counters for valid, invalid and duplicate, a filter to show only the errors, and the option to copy the result or download it as a CSV.

If your code is missing its last digit, for example because you assign numbers yourself within your GS1 range, choose Calculate check digit. The tool completes 7, 11, 12 or 13 digits into a full EAN-8, UPC-A, EAN-13 or GTIN-14. That choice is deliberately explicit: twelve digits can be either a complete UPC-A or an EAN-13 without its check digit, and no tool can guess which one you mean.

How the check digit of an EAN or GTIN works

All GS1 codes use the same modulo 10 calculation. Take the digits without the last one and start from the right: multiply the rightmost digit by 3, the next by 1, then by 3 again, and so on. Add everything up and see how much you need to reach the next multiple of ten. That number (0 to 9) is the check digit. For 871100000000 the sum is 33, so the check digit is 7 and the complete EAN-13 is 8711000000007.

Because the weighting starts from the right, a leading zero does not change the check digit. A UPC-A with a zero in front is therefore also a valid EAN-13, and an EAN-13 with a zero in front a valid GTIN-14. The check digit catches every single-digit error and most swaps of two adjacent digits. It says nothing about whether the code has actually been assigned to your product: for that you need the registration with GS1.

What the GS1 prefix does and does not tell you

The first two or three digits of an EAN-13 form the GS1 prefix. 870 to 879 is issued by GS1 Netherlands, 540 to 549 by GS1 Belgium and Luxembourg, and 400 to 440 by GS1 Germany. The prefix indicates the country of the GS1 membership, not the country of origin. A Dutch company that manufactures in Asia simply uses an 87 code, and a foreign brand with a Dutch subsidiary can do the same.

Some ranges are not meant for global product codes. Codes starting with 20 to 29 are for internal use, such as weighed items where the weight or price is part of the code. They are only unique within one shop or company. 977 is reserved for periodicals (ISSN) and 978 and 979 for books (ISBN). Codes starting with 0 or 1 usually come from the United States or Canada, where UPC-A is the standard.

Common mistakes in product files

The most common mistake happens in Excel. To Excel, an EAN-13 is a number, and long numbers are displayed as 8.71E+12. Once you save that file, the last digits are gone for good. Leading zeros also disappear without warning, so a 12-digit UPC-A suddenly has 11 digits. Set the column to Text before pasting or importing. The checker recognises both cases and tells you so.

Other classics are duplicate codes in a product file, for example because a variant was given the code of the base product by mistake, and codes made up without GS1 registration. The latter can have a correct check digit and still be rejected by marketplaces and retailers, who check whether the code belongs to your company prefix. Use the checker as a first filter, and if in doubt, look up in the GS1 registry who a code belongs to.

If you work with thousands of items, several suppliers or a webshop connected to marketplaces, you do not want to do these checks by hand. Have them run automatically when supplier files are imported and before products are published, so a wrong code never reaches your ERP, WMS or webshop.

Frequently asked questions

EAN checker: your questions answered

How do I check whether an EAN code is valid?

Paste the code into the checker and choose Validate. The tool calculates the check digit from the first digits and compares it with the last digit of your code. If they match, the code is technically valid; if not, you see which check digit it should have had.

Does a valid EAN code mean the product exists?

No. A correct check digit only means the code is built correctly. Whether the code has been assigned to a company and product is something you check in the GS1 registry. Marketplaces do this more and more, so made-up codes get rejected there.

What is the difference between EAN-13, UPC-A and GTIN-14?

They are all GS1 GTIN codes of different lengths. EAN-13 is the standard on consumer products in Europe, the 12-digit UPC-A in the United States and Canada, and GTIN-14 is used for outer packaging such as cases and trays. EAN-8 is a short version for small packages.

Does a product with an EAN starting with 87 come from the Netherlands?

Not necessarily. The prefix 870 to 879 means the code was issued by GS1 Netherlands to a company that is a member there. You cannot tell from it where the product was made.

How do I calculate the check digit of a new EAN-13?

Choose Calculate check digit and enter the first 12 digits. The tool works out the thirteenth digit and shows the complete code. You can also complete a whole list in one go and download it as a CSV.

Why has my EAN code turned into 8.71E+12 in Excel?

Excel treats the code as a number and shows it in scientific notation. As soon as you save the file, you lose the last digits. Set the column to Text before pasting or importing codes, or import the file with Get Data and set the column to text.

Free tools

More free tools

All tools
  • AI readiness scan

    Answer ten questions about one process and see straight away whether AI, rule-based automation or something else is the right first step.

  • Savings calculator

    Enter how much time your team spends on manual work and get an instant estimate of the savings per year.

  • Cron expression generator

    Build a schedule or paste a cron expression and read in plain English when it runs, with the next run times.

  • JSON formatter & validator

    Paste JSON, make it readable or compact, and see exactly where an error is, by line and column. Everything stays in your browser.

  • CSV to JSON converter

    Turn a CSV export from Excel, your webshop or your accounting software into JSON for an API or import. The delimiter is detected automatically.

  • Custom software or SaaS

    Compare the cost of an off-the-shelf package with custom software over several years, using your own numbers.

  • Dutch VAT calculator

    Convert an amount from excluding to including Dutch VAT or back, at 21%, 9% or 0%, and see exactly how much VAT it contains.

  • Margin calculator

    Enter two of cost price, selling price, margin or markup and get the rest, including the difference between margin and markup and the price with VAT.

  • Reorder point calculator

    Work out the stock level at which to reorder, how much safety stock you need and what a sensible order quantity is.

Team talking and laughing around a laptop

Free introductory call

Curious what Kantex could automate for you?

Book a free 30-minute introductory call. We walk through your process and show where software, integrations or AI deliver the most.

  • No obligation and no sales pitch
  • Concrete opportunities for your process
  • A clear next step and quote
Four colleagues discussing a design on a laptop

Free process analysis

Find out in 30 minutes what you can automate

Together we walk through one process and show where software, integrations or AI save time. No obligation.