JavaScript API for barcode scanning based on the WebAssembly technology

Dynamsoft Barcode Reader JavaScript Edition is a JavaScript API for barcode scanning based on the WebAssembly technology. It supports real-time localization and decoding of various types of barcodes. The library is capable of scanning barcodes from a static image, and more importantly, directly from a live video stream. It supports reading multiple barcodes at a time.

Before going any further, please try the demo from a desktop browser or mobile browser to see it in action.

Barcode Scanning Online Demo

Zero Footprint

The core of Dynamsoft Barcode Reader is written in C++ for performance. We compiled the library to WebAssembly so that it can run alongside with JavaScript.

Supported Barcode Symbologies

Linear Barcodes (1D):

Include Code 39, Code 93, Code 128, Codabar, Interleaved 2 of 5, EAN-8, EAN-13, UPC-A, UPC-E, Industrial 2 of 5

2D Barcodes:

QR code, Datamatrix, PDF417 and Aztec are supported.

Supported Browser and Platform

Supported Browsers for Desktop:
Chrome v61 or up recommended
Edge v16 or up
Firefox v58 or up recommended
Safari v11 or up (could be slow)
Internet Explorer No
Supported Browsers for Mobile:
Chrome for Android v61 or up recommended
Edge slow
Firefox for Android v58 or up recommended
Safari v11 or up (could be slow)
Android Webview v61 or up recommended

Estimated Performance

Generally speaking, the performance heavily depends on the network connection, device and browser used.
Below is some preliminary data from our testing.

  • The initial load (cold cache) column lists the time spent on downloading the WASM file and compilation when a user first accesses the above demo page.
  • The subsequent visits (warm cache) column lists the time spent on page load from the second time forward.
Device Browser Initial load (ms) Subsequent visits (ms)
Win10 CPU: i7-4790 Chrome Version 70 (64-bit) 546 346
Win10 CPU: i7-4790 Firefox Quantum 63 (64-bit) 220 80
Win10 CPU: i7-4790 Microsoft Edge 42 339 83
Ubuntu: 16.0.4 Firefox Quantum 63 (64-bit) 396 152
Mac: 10.13.6 Safari 12 4,540 2,687
Mac: 10.13.6 Firefox Quantum 63 (64-bit) 290 152
Mac: 10.13.6 Chrome 71 (64-bit) 975 631
iPhone 7 Safari 11.4 6,936 4,718
iPhone X Safari 12.1 4,211 3,164
HUAWEI Mate20
CPU: Hisilicon Kirin 980
Chrome 70 4,998 2,743
HUAWEI Mate20
CPU: Hisilicon Kirin 980
Firefox 63 1,617 434

Overall, WebAssembly edition comes with a clear advantage: your end users don't need to install anything to use your application; Meanwhile, this relatively new technology relies on browsers a lot so the performance might be an issue, especially for the first time load. The loading performance will be improved down the road. Please contact us if you have questions choosing the right edition and would like to optimize the reading accuracy or the performance.