Barcode Scanner to Excel: Count Stock and Export It

Scan barcodes into an Excel spreadsheet with your phone, a laptop camera or a USB scanner. Each code read adds one to its quantity; change quantities, add notes, and export an .xlsx file. The counter works offline, keeps your counts on this device and never uploads them.

Each code read adds one. The video stays on this device.

The same code again

Saved on this device

Count

No codes yet

Scanned and typed codes are listed here, newest first, with their quantity and a note.

    Export

    Your counts are stored in this browser on this device only (IndexedDB) and are never uploaded. Clearing this site's data, or closing a private window, deletes them: export or back up a count you need.

    How to Scan Barcodes Into Excel

    Count the codes on this page, then export the count as an Excel file: every row is a code with its quantity and note.

    1. Choose Camera and press Start camera, or plug in a USB scanner and scan into the Code field.
    2. Scan each item: the same code again adds one to its quantity, and a new code gets its own row.
    3. Correct a count with the minus and plus buttons, or type the quantity, and add a note where you need one.
    4. Press Excel (.xlsx) and open the file in Excel, Google Sheets or Numbers.

    What the Counter Reads and Writes

    The counter reads the same barcode types as the Barcode.codes scanner and writes three kinds of file.

    Barcode Types It Reads

    • Product codes: UPC-A, UPC-E, EAN-13 and EAN-8; a UPC-A read as an EAN-13 with a leading 0 is listed as the 12-digit UPC-A.
    • Your own codes: Code 128, Code 39, Code 93, ITF, Codabar and GS1 DataBar.
    • 2D codes: QR Code, Data Matrix, PDF417, Aztec and MaxiCode.

    Ways to Enter a Code

    • Camera: a phone or laptop camera; a code held in view is counted once until it has been out of view for 2 seconds.
    • Images: photos or screenshots: every code found in an image is counted.
    • Code field: type a code with its quantity, or let a USB or Bluetooth scanner type it and press Enter.

    Files It Writes

    • Excel (.xlsx): one sheet named after the session, with a bold, frozen header row.
    • CSV: the same columns as plain text, for other software.
    • Backup (JSON): every session, to restore on this or another device with Restore backup.

    Using a USB Barcode Scanner With Excel

    A USB or Bluetooth barcode scanner types the code like a keyboard and usually presses Enter, so it writes into whatever field or cell has the focus.

    Scanning Straight Into a Spreadsheet

    Click a cell in Excel and scan: the code is typed into the cell and Enter moves to the next row. You get one row per scan and no counts, so 40 scans of the same item are 40 rows to add up yourself.

    Counting First, Then Exporting

    Scan into the Code field of this page instead: the same code adds one to its quantity, so 40 scans are one row with 40. Export the count when you are done, and each code is in Excel once with its total.

    Counting Stock Offline

    After the first visit, the counter opens and works without a connection, so a stockroom or a warehouse without signal does not stop the count.

    How It Works Without Internet

    The page stores itself and the barcode decoder in your browser on the first visit. Without a connection it opens from that copy, reads codes and saves the count on the device; with a connection it always loads the latest version first.

    Install It as an App

    Where the browser offers it, as Chrome and Edge do, an Install app button appears on the page; Barcode.codes then opens from your home screen or desktop in its own window, with this counter among its shortcuts. On an iPhone or iPad, open the page in Safari, press Share and choose Add to Home Screen.

    Where the Count Is Stored

    Counts are kept in this browser's storage (IndexedDB) on this device and are never uploaded. Clearing the site's data or closing a private window deletes them, so export or back up a count you need; Delete all data removes everything at once.

    Keeping Leading Zeros in Excel

    The .xlsx file stores every code as text, so 0012345 stays 0012345 and a long number keeps every digit when Excel opens it.

    • Excel (.xlsx): codes are text cells and quantities are number cells, so you can add up the quantities and the codes stay as scanned.
    • CSV: a CSV file has no cell types, and a spreadsheet that opens it may read 0012345 as the number 12345. Import it as text, or use the .xlsx file.
    • Codes that look like formulas: in the CSV, a code that starts with =, +, - or @ gets a ' in front so a spreadsheet does not run it as a formula; the .xlsx file keeps it as written.

    Your Inventory Count Sheet

    The export is a ready inventory count sheet: one row per code, in the order you counted, with these columns.

    Columns of the exported count
    ColumnWhat It Holds
    CodeThe content of the barcode, exactly as read or typed.
    TypeThe barcode type, such as EAN-13 or Code 128. A typed product number with a valid check digit gets its type; other typed codes are Text.
    QuantityThe count, as a number Excel can add up.
    NoteYour note for that row, such as a shelf or a damaged item.
    First scan, Last scanThe time of the first and the latest scan of the code, in UTC (ISO 8601).
    SourceCamera, the image file name, Typed or USB scanner.

    Inventory barcode generator makes numbered barcode labels for stock, bins and assets, ready to count with this page.

    Frequently Asked Questions

    Is This Barcode Scanner to Excel Free?

    Yes. It needs no account and no subscription, and it has no limit on sessions; a session holds up to 20,000 rows. Everything runs in your browser.

    Does It Work Without Internet?

    Yes, after one visit with a connection: the page and its barcode decoder are stored in your browser. Open the same address, or the installed app, and count; the files export without a connection too.

    How Is This Different From the Barcode Scanner?

    The barcode scanner reads and explains codes, with a Count mode and a CSV file. This counter is made for stocktakes: saved sessions, quantities you can correct, notes, undo, an Excel file and offline use.

    Can I Scan Barcodes Into Excel With My Phone?

    Yes. Open this page on the phone, count with its camera, and export the .xlsx file; open it in the Excel app or send it to your computer. No app from a store is needed.

    Why Does Excel Remove the Leading Zeros of My Codes?

    Excel can read a code such as 0012345 as a number when it opens a CSV file or when a scanner types into a cell. The .xlsx file from this page marks codes as text, so they open as scanned.

    What Happens to My Counts If I Clear My Browser?

    They are deleted: the counts live only in this browser's storage on this device. Save a Backup (JSON) before you clear the browser or change devices, and restore it with Restore backup.