Label and sticker sizes

ZPL course · ZPL FAQ

Command reference: Labelary ZPL introduction.

Below, commands are bold, parameters are colored, field data stays plain.

Label sizes — match the format to the media

Goal

Set ^PW and ^LL from the physical sticker so nothing prints off the edge.

Description

ZPL positions everything in dots. A 203 dpi head prints 203 dots per inch, so a 4 by 6 inch shipping sticker is 812 by 1218 dots, and a 4 by 2 inch small sticker is 812 by 406 dots. ^PW sets the width, ^LL the length; at 300 dpi multiply everything by 300/203 instead. ^PO with I rotates the whole label 180 degrees when the roll feeds the other way. Calibrate first with lesson 44 — a format with perfect numbers still misprints on an uncalibrated printer.

Example

^XA
^PW812
^LL1218
^FO50,50^A0N,40,40^FD4x6 shipping sticker^FS
^XZ

Rendered 4x6 label

Result

One line of text inside a 4 by 6 frame. Swap the two numbers for a 4 by 2 sticker: ^PW812 with ^LL406.

Article author: Arthur Isaev