📊

Barcode & QR Decoder

Decode barcodes and QR codes from any image

GET 1 credit /v1/barcode/decode
curl "https://barcode.toolkitapi.io/v1/barcode/decode?url=https://toolkitapi.io/barcode-label.png"
import httpx

resp = httpx.get(
    "https://barcode.toolkitapi.io/v1/barcode/decode?url=https://toolkitapi.io/barcode-label.png",
)
print(resp.json())
const resp = await fetch("https://barcode.toolkitapi.io/v1/barcode/decode?url=https://toolkitapi.io/barcode-label.png", {
});
const data = await resp.json();
console.log(data);
# See curl example
Response 200 OK
{
  "found": 2,
  "results": [
    {
      "data": "ABC-12345",
      "type": "CODE128",
      "quality": "high",
      "position": {"points": [[10,10],[200,10],[200,80],[10,80]]}
    },
    {
      "data": "https://toolkitapi.io",
      "type": "QRCODE",
      "quality": "high",
      "position": {"points": [[220,10],[350,10],[350,140],[220,140]]}
    }
  ]
}

Try It Live

Live Demo

Description

Decode barcodes and QR codes from any image

How to Use

1

1. Make a GET request with `url` set to a publicly accessible image containing one or more barcodes or QR codes.

2

2. Check the `found` field in the response to see how many codes were detected. Each item in `results` contains the decoded `data`, the symbol `type`, and a `quality` rating.

3

3. Use the `position` data to map detected codes back to their physical locations in the original image.

About This Tool

Use the Barcode & QR Decoder to extract data from any image containing one or more barcodes or QR codes. Pass a URL to a publicly accessible image and the API detects, locates, and decodes every symbol found in it.

The decoder supports all common 1D symbologies (Code 128, EAN-13, UPC-A, Code 39, ITF, etc.) as well as 2D codes (QR codes, Data Matrix). It returns the decoded payload, symbol type, quality indicator, and the bounding polygon for each detected code.

This is useful for automating data extraction from photos of product labels, warehouse shelves, shipping documents, or any image that contains scannable codes.

Why Use This Tool

Frequently Asked Questions

Can it decode multiple barcodes in one image?
Yes. The decoder finds and returns all barcodes and QR codes present in the image. Each one gets its own entry in the `results` array with independent data, type, and position.
What image formats are supported?
The decoder accepts PNG, JPEG, GIF, BMP, and TIFF images. The image must be accessible via a public URL.
How large can the image be?
There is no hard size limit imposed by the API, but very large images will increase processing time. For best results keep images under 10 MB.
Does it detect both 1D barcodes and QR codes?
Yes — the same endpoint handles all symbologies. The `type` field in each result tells you exactly what was detected (e.g. CODE128, EAN13, QRCODE).

Start using Barcode & QR Decoder now

Get your free API key and make your first request in under a minute.