Your country

Tools that support it use your country for local currency, number formats, units and paper size. Your choice is saved only in this browser.

Type a name or a two-letter code. Use the up and down arrow keys to move through the countries, Enter to choose one and Escape to close.

Barcode Scanner Online (Camera or Image)

Read any barcode on your device, with its check digit, GTIN, batch and expiry explained.

Utility No upload Free, no sign-up

Scan a barcode

What the barcode says

Start the camera, choose a picture or type a number. You will see the barcode type, whether its check digit is right, the GTIN and its GS1 prefix, and any batch, serial or expiry data.

Scan history

Codes you scan or check appear here, newest first.

    Pictures, camera frames and typed numbers are decoded on this device and never uploaded. Browsers without a built-in barcode reader download the decoder (zxing-wasm, about 0.9 MB) from this site once, and a HEIC photo in a browser that cannot open HEIC needs the HEIC decoder (about 1.4 MB), also from this site.

    Next steps

    About the Barcode Scanner Online (Camera or Image)

    Scan 1D and 2D barcodes with your camera, from a photo or screenshot, or type the number printed under the bars. The scanner reads EAN-13, EAN-8, UPC-A, UPC-E, ITF-14, Code 128, Code 39, Code 93, Codabar, GS1 DataBar, Data Matrix, PDF417, Aztec and QR codes and explains what each one holds: the check digit, worked out step by step; the GTIN and the GS1 office that issued its prefix; ISBN and ISSN numbers on books and magazines; and the GS1 Application Identifiers on medicine and food packs — batch, serial number and the expiry date with the days left.

    Every scan goes into a history on this device, which you can copy, download as CSV or Excel, or switch off. Decoding happens in your browser: with its built-in barcode reader where it has one, otherwise with the open-source zxing-wasm decoder served from this site.

    How to use it

    1. Choose Camera and press Start camera, then hold the barcode inside the frame, about 10–20 cm away. Or choose Photo to pick, drop or paste a picture, or Type a number to check a number by hand.
    2. Read the result: the barcode type and value, whether the check digit is right (open How it is worked out to see the sum), the GTIN with its GS1 prefix, and any batch, serial or expiry data.
    3. Keep scanning: each new code goes to the top of the Scan history. Copy a value, download the history as CSV or as an Excel file (which keeps the leading zeros of UPC and GTIN numbers), or clear it.
    4. For a product or book, the look-up buttons open Open Food Facts or Open Library in a new tab, only if you choose them.

    Examples

    A product barcode (EAN-13)
    Input
    4006381333931
    Result
    Check digit 1 correct (weighted sum 89, next multiple of 10 is 90) · GS1 prefix 400: GS1 Germany
    A small-pack code (UPC-E)
    Input
    01234565
    Result
    Stands for the UPC-A 012345000065 · check digit 5 correct
    A medicine pack (GS1 DataMatrix)
    Input
    (01)08901234567890(17)271231(10)B7X(21)ABC123
    Result
    GTIN 08901234567890 (GS1 India) · expiry 31 Dec 2027 with the days left · batch B7X · serial ABC123
    A book
    Input
    9780306406157
    Result
    ISBN-13 978-0306406157 · ISBN-10 0306406152 · a link to the book on Open Library
    A number without its check digit
    Input
    400638133393
    Result
    If it is an EAN-13 without its check digit, the full number is 4006381333931

    Common uses

    • Checking the batch, serial number and expiry date in the GS1 DataMatrix code on a medicine pack.
    • Verifying EAN or UPC numbers and their check digits before printing labels or listing products online.
    • Reading ISBNs from books and ISSNs from magazines.
    • Scanning stock, parcels and cartons (ITF-14, SSCC) into a list and downloading it as CSV or Excel.
    • Reading a barcode from a screenshot or a photo on a laptop that has no scanner.

    A barcode prefix is not the country of origin

    The first digits of an EAN-13 are a GS1 prefix. They show which national GS1 office licensed the number to the brand owner — 890 for GS1 India, 400–440 for GS1 Germany, 690–699 for GS1 China — not where the product was made: a company can license its numbers in one country and make its goods anywhere. In GS1’s own words, “GS1 Prefixes do not identify the country of origin for a given product.” Look for “Made in” or “Country of origin” on the pack instead.

    UPC-A codes (12 digits) are read with an implied leading 0, so 036000291452 has the prefix 003 (GS1 US). Numbers starting 02, 04 or 20–29 are restricted-circulation numbers used inside one shop, company or country, for example for goods weighed and priced at the counter; 978–979 are books (ISBN), 977 serial publications (ISSN), and 952 is reserved for examples. The scanner uses GS1’s list of GS1 prefixes.

    How a check digit is worked out

    EAN, UPC, ITF-14, GTIN-14, SSCC and GLN numbers end with a GS1 check digit (mod 10). Multiply the digits before it by 3 and 1 alternately, starting with 3 at the right, and add them up; the check digit is what brings the sum up to the next multiple of 10. For 4006381333931 the weighted sum of the first twelve digits is 89, so the check digit is 1. A wrong check digit means the number was misread, mistyped or misprinted. GS1 explains the method with its own check digit calculator.

    Code 128, Code 93, GS1 DataBar and the 2D codes carry checks inside the symbol that the decoder verifies while it reads. Code 39 and ITF only have optional check characters, which the scanner tests for; Codabar has no standard one. ISBN-10 and ISSN use a mod 11 check character, which can be an X.

    GS1 data on medicines, food and cartons

    GS1-128 barcodes, GS1 DataMatrix and GS1 DataBar carry several pieces of data, each after an Application Identifier (AI) in brackets: (01) the GTIN, (10) the batch or lot, (21) the serial number, (17) the expiry date, (15) best before, (11) the production date, (3103) the net weight in kilograms with three decimals, and (00) the SSCC of a pallet or parcel. Dates are written YYMMDD, and a day of 00 means the end of that month. The scanner splits the data, checks each part’s format and check digit and shows how many days are left until the expiry date.

    QR codes in the GS1 Digital Link format, such as https://id.gs1.org/01/09506000134352/10/ABC1?17=271231, carry the same data in a web address and are read the same way; the link is opened only if you choose to.

    Limitations

    • A barcode holds only a number or text, not the product’s name or price. The scanner does not look products up; the optional look-up buttons open Open Food Facts or Open Library with the number, and only their listings are shown there.
    • The GS1 prefix names the GS1 office that issued the number, not the country of origin, and restricted-circulation numbers (02, 04, 20–29) mean different things in different shops and countries.
    • Very small, blurred, curved, glossy or damaged barcodes may not read. For a photo, try Search again more thoroughly, which also reads the picture turned a little and with other contrast settings; otherwise use even light, hold the camera steady and straight, or take a sharper photo.
    • The small add-on barcode (2 or 5 digits) printed beside some book and magazine EANs is not read.
    • Commonly used Application Identifiers are named; others are shown as unknown so you can look them up in the GS1 General Specifications.
    • The camera needs your permission and stops when you leave the page or switch to another tab.

    Privacy

    Pictures, camera frames and typed numbers are decoded in your browser and never uploaded. The scan history is kept only in this browser — untick “Save history on this device” to stop that and remove it — and can be cleared at any time. The Open Food Facts and Open Library buttons send the number to those sites only when you click them.

    Frequently asked questions

    Can a barcode tell me which country a product comes from?

    No. The first digits (the GS1 prefix) show which GS1 office licensed the number — 890 is GS1 India, 690–699 GS1 China — but companies can make their products anywhere. The country of origin is printed on the pack, not encoded in the EAN.

    How do I check if a barcode number is valid?

    Choose Type a number and enter the digits under the barcode. The scanner works out the GS1 check digit and says whether the last digit matches — for 4006381333931 the check digit must be 1. If you typed the number without its last digit, it tells you what the full number is.

    How do I read the expiry date and batch number in a medicine barcode?

    Scan the square GS1 DataMatrix code on the pack. The scanner lists every part: (01) the GTIN, (10) the batch, (21) the serial number and (17) the expiry date, with the number of days left or how long ago it expired.

    Can I scan a barcode without a camera?

    Yes. Choose Photo and pick a photo or screenshot of the barcode — or paste it with Ctrl+V or ⌘V — or type the number printed under the bars.

    Why does it say the check digit is wrong?

    The last digit does not match the others: a digit was misread (try a sharper photo or better light), mistyped, or printed wrongly on the label. Decoders normally reject EAN and UPC codes with a bad check digit, so this mostly happens with typed numbers.

    Where is my scan history kept?

    Only in this browser on this device. It holds the last 200 scans with the time, barcode type and value. Download it as CSV or Excel, delete single entries, clear it, or untick “Save history on this device” to keep it only until you leave the page.

    Quick answers and tool search

    Type to search tools or to get a quick answer, for example 18% of 2500. Use the up and down arrow keys to move through the results, Enter to choose, and Escape to close.