ZPL
Zebra Programming Language
What is ZPL?
ZPL (Zebra Programming Language) is the command language used to control Zebra thermal label printers. It defines label layout, barcode rendering, text formatting, graphics, and RFID tag encoding — all as printable ASCII commands sent over USB, serial, network, or Bluetooth.
ZPL commands are enclosed between ^XA (start format) and ^XZ (end format). Each command begins with a caret (^) or tilde (~) followed by a two-letter command code and optional parameters.
Used for: Shipping labels, retail price tags, warehouse bin labels, asset tags, healthcare wristbands, and any application involving Zebra printers — which dominate the RFID label printing market.
Key commands for RFID labels
| Command | Purpose | Example |
|---|---|---|
^XA | Start label format | ^XA |
^XZ | End label format | ^XZ |
^BY | Barcode default parameters (width, ratio, height) | ^BY2,3,100 |
^BC | Code 128 / GS1-128 barcode | ^BCN,100,Y,N,N |
^BQ | QR Code barcode | ^BQN,2,5 |
^FO | Field origin (X,Y position) | ^FO50,50 |
^FD | Field data | ^FD>;>8018060141411234560^FS |
^FS | Field separator (end of field) | ^FS |
^RF | RFID encode (write EPC to tag) | ^RFW,H^FD3034257BF7194E4000001A85^FS |
^RS | RFID setup (power, retries) | ^RS8 |
Example: GS1-128 label with RFID
^XA ^FO50,50 ^BY2,3,100 ^BCN,100,Y,N,N ^FD>;>8018060141411234560^FS ^RFW,H^FD3034257BF7194E4000001A85^FS ^XZ
This prints a GS1-128 barcode with AI (01) GTIN data at position (50,50), then writes the corresponding SGTIN-96 EPC to the RFID inlay embedded in the label.
ZPL II vs ZPL
Modern Zebra printers use ZPL II, an extended version of the original ZPL. ZPL II added support for RFID encoding (^RF, ^RS), downloadable fonts, stored graphics, and network configuration. Nearly all current Zebra printers — including the ZT400, ZT600, ZD500R, and ZQ series — use ZPL II. The original ZPL is effectively obsolete.
Try it
Use the ZPL Playground to write ZPL and see labels render live in your browser — with syntax highlighting, autocomplete, 50+ command reference, and step-by-step exercises from beginner to advanced.
The EPC Parser Tool also generates ZPL output for any parsed EPC — select the ZPL format in the barcode section to see the printer commands.