---
title: "Barcode in Google Sheets – IMAGE Formula, Free API"
description: "How to create barcodes in Google Sheets with one IMAGE() formula and our free barcode API: Code 128, UPC, EAN and QR codes for every row, no add-on needed."
url: https://barcodejar.com/barcode-in-google-sheets
source: BarcodeJar (free barcode tools)
---

# How to Make Barcodes in Google Sheets

Put this in a cell and fill it down: `=IMAGE("https://barcodejar.com/api/barcode?type=code128&data="&ENCODEURL(A2))`. Every row gets a real, scannable barcode from our free API, with no add-on or font needed.

_Interactive tool: open https://barcodejar.com/barcode-in-google-sheets to use it in your browser. It is free with no sign-up._

## How to create barcodes in Google Sheets

1.  Put your values in column A (plain text format for numbers with leading zeros).
2.  In B2 enter `=IMAGE("https://barcodejar.com/api/barcode?type=code128&data="&ENCODEURL(A2))`.
3.  Drag the formula down the column and make the rows taller so the barcodes are readable.
4.  Change `type=` for UPC, EAN, QR or any other type, and scan one with our [online scanner](https://barcodejar.com/barcode-scanner) to check.

**Quickest method:** with your codes in column A, enter this in B2 and drag it down:

`=IMAGE("https://barcodejar.com/api/barcode?type=code128&data="&ENCODEURL(A2))`

Change `type=code128` to `upca`, `ean13`, `qrcode` or any type listed on the [barcode API](https://barcodejar.com/barcode-api) page.

## Method 1: IMAGE() with the free barcode API

Google Sheets' IMAGE function displays a picture from a URL in a cell. Our [barcode API](https://barcodejar.com/barcode-api) returns a barcode image for whatever you pass in `data`, so one formula covers the whole column.

| Barcode | Formula (value in A2) |
| --- | --- |
| Code 128 (SKUs, text) | `=IMAGE("https://barcodejar.com/api/barcode?type=code128&data="&ENCODEURL(A2))` |
| UPC-A (11 or 12 digits) | `=IMAGE("https://barcodejar.com/api/barcode?type=upca&data="&A2)` |
| EAN-13 | `=IMAGE("https://barcodejar.com/api/barcode?type=ean13&data="&A2)` |
| QR code (URLs, text) | `=IMAGE("https://barcodejar.com/api/barcode?type=qrcode&data="&ENCODEURL(A2))` |
| Fixed size, 60 × 200 px | `=IMAGE("https://barcodejar.com/api/barcode?type=code128&data="&ENCODEURL(A2), 4, 60, 200)` |

## Tips for the IMAGE formula

-   **ENCODEURL** keeps spaces, & and other symbols from breaking the URL. Plain digits do not need it.
-   **Leading zeros:** format UPC/EAN columns as plain text (Format → Number → Plain text) so Sheets does not drop the zeros.
-   **Size:** by default the image fits the cell. Make rows taller, use mode 4 with a height and width as shown above, or add `&scale=4` for a higher-resolution image.
-   **Options:** add `&hrt=0` to hide the text under the bars, `&height=10` for taller bars, or `&fg=1a1a1a&bg=ffffff` for colours.
-   Cell values are sent to barcodejar.com to draw the image, so avoid confidential data.

## Method 2: Libre Barcode fonts

Open the font menu, choose **More fonts** and add _Libre Barcode 39_. Then use `="*"&UPPER(A2)&"*"` in a column with that font at 24 pt or more. Only Code 39 works this simply; the Libre Code 128 and EAN-13 fonts need specially encoded text, so plain values will not scan. See the [barcode fonts guide](https://barcodejar.com/barcode-fonts).

## Printing barcodes from Sheets

IMAGE() barcodes print with the sheet. For labels, download the sheet as CSV and paste the column into the [label generator](https://barcodejar.com/barcode-label-generator) (Avery and thermal sizes), or the [bulk generator](https://barcodejar.com/bulk-barcode-generator) for a ZIP of PNG/SVG files.

See also: [barcode generators for every platform, product and use case](https://barcodejar.com/barcode-generator-for).

## Frequently asked questions

### Can Google Sheets generate barcodes?

Yes, with the IMAGE function and a barcode API: `=IMAGE("https://barcodejar.com/api/barcode?type=code128&data="&ENCODEURL(A2))`. Our [API](https://barcodejar.com/barcode-api) is free and needs no key.

### How do I make a QR code in Google Sheets?

Use `=IMAGE("https://barcodejar.com/api/barcode?type=qrcode&data="&ENCODEURL(A2))`. ENCODEURL matters here because URLs and text contain characters like & and ?.

### How do I make UPC barcodes in Google Sheets?

Use `type=upca` with your 11 or 12-digit numbers, stored as plain text so leading zeros stay. The check digit is added to 11-digit input.

### Why does my barcode show an error image?

The data is not valid for that type, for example letters in a UPC or a wrong check digit. Open the URL in a browser to see the error message.

### Is there a limit on the barcode API?

It is free with no key. Please keep usage reasonable; see the [barcode API page](https://barcodejar.com/barcode-api) for details and all parameters.

### Can I use a barcode font instead?

Yes, Libre Barcode 39 from the More fonts menu works for Code 39 with asterisks around the value. Other barcode fonts need encoding.

## Related free tools

[**Free Barcode API**Barcode images by URL for img tags, Google Sheets and Excel.](https://barcodejar.com/barcode-api)[**Bulk Barcode Generator**Paste a list or CSV, download hundreds as ZIP or PDF.](https://barcodejar.com/bulk-barcode-generator)[**Barcodes in Excel**IMAGE() formula with our free barcode API, or fonts and bulk images.](https://barcodejar.com/barcode-in-excel)[**Barcode Fonts**Free Libre Barcode fonts, how to use them, and when to use images instead.](https://barcodejar.com/barcode-fonts)[**Barcodes in Word**DISPLAYBARCODE and MERGEBARCODE fields and mail-merge labels in Word.](https://barcodejar.com/barcode-in-word)[**Barcode Label Generator**Print barcodes on Avery and other label sheets as PDF.](https://barcodejar.com/barcode-label-generator)[**QR Code Generator**Free static QR codes with colors and logo. No sign-up.](https://barcodejar.com/qr-code-generator)
