^GF Graphic Field
Embeds a bitmap image in the label (ASCII hex, binary or Z64).
Graphics · Updated 2026-10-20
Syntax
^GFa,b,c,d,data
Parameters
| Parameter | What it does | Values |
|---|---|---|
a | Compression type. | A = ASCII hex, B = binary, C = compressed binary |
b | Total bytes of data. | 1 to 99999 |
c | Total bytes of the image. | 1 to 99999 |
d | Bytes per row. | 1 to 99999 |
data | The image data. | Hex, binary or Z64/B64 |
Common mistakes
- Bytes per row is ceil(width in dots / 8). A wrong value skews the image into diagonal stripes.
- The viewer's “Add image” builds the ^GFA for you from a PNG or JPEG.
Example
Edit the code and the label redraws. This is the same engine as the API.
Questions
What does ^GF do in ZPL?
Embeds a bitmap image in the label (ASCII hex, binary or Z64).
What is the syntax of ^GF?
^GFa,b,c,d,data
What should I watch out for with ^GF?
Bytes per row is ceil(width in dots / 8). A wrong value skews the image into diagonal stripes.