Published:
Many carriers and shipping platforms hand you the label as ZPL — the command language of Zebra-class thermal printers. Without such a printer, an office laser printer or a browser prints ZPL as lines of text. You do not need to buy a Zebra: render the ZPL to a PDF or PNG and print it on the printer you have, and once there are tens or hundreds of labels a day, let a script do the conversion through the API. This page shows where each carrier's documentation says the ZPL comes from, and then the same three steps for all of them.
Carrier fields below were read in each carrier's own developer documentation on 2026-11-10 (Turkish carriers on 2026-10-31 and 2026-11-02, as noted). Field names change between API versions; check the current reference before you build on them.
^XA.The render endpoint takes the ZPL as the request body. The path carries the density and the label size in inches; the last part is the label index in the file.
# first label as PNG (203 dpi = 8 dots/mm, 4x6 inch)
curl -X POST "https://api.labelixa.com/v1/printers/8dpmm/labels/4x6/0" \
-H "X-API-Key: $LABELIXA_KEY" --data-binary @label.zpl -o label.png
Leave the index out and ask for PDF to get every label in the file, one per page — useful when a carrier returns a multi-parcel shipment as one buffer:
base64 -d label.b64 > label.zpl # when the carrier returns base64
curl -X POST "https://api.labelixa.com/v1/printers/8dpmm/labels/4x6/" \
-H "X-API-Key: $LABELIXA_KEY" -H "Accept: application/pdf" \
--data-binary @label.zpl -o labels.pdf
Use 12dpmm for a label written for 300 dpi. The URL scheme
is the one Labelary uses, so code written for it usually needs only a new
host — see the Labelary-compatible
endpoint. To stop a broken label before it is printed,
/v1/diagnostics returns findings as JSON; the full reference
is in the API documentation.
When a script converts every label you ship, the conversion service is part of your shipping line: if it does not answer, parcels wait. Two things are worth checking before you rely on any service, ours included:
Carrier ZPL is almost always written for a 4×6 inch (about 100×150 mm) label. What the converter and the API do with that today, measured on 2026-11-10:
X-Page-Size: A4 and X-Page-Layout: 2x2 put four
labels on each A4 page; each is scaled to fit its cell, to about 90%
(91×137 mm); a 2×3 grid is about 60%. With 1x1 (the default
once a page size is set) the label is centred at true size and never
enlarged; a 4×6 label on A6 is shrunk to about 89% to fit. The converter
offers A4, Letter, A5, A6 and Legal sheets.Only carriers whose own documentation we could read are listed here. Labelixa does not buy labels or talk to the carriers; it renders the ZPL you already received.
Shipping API, POST /shipments/{version}/ship:
LabelSpecification.LabelImageFormat.Code = ZPL,
LabelStockSize 4×6 or 4×8 inches. The specification has no
resolution field, so read the density from the file. Request fields and
response paths: UPS ZPL
labels.
Ship API: labelSpecification.imageType =
ZPLII, labelStockType such as
STOCK_4X6, resolution 203 or 300 (300 only with
ZPLII; the default is 203). Details:
FedEx ZPL labels.
Domestic Labels 3.0 API (POST /labels/v3/label): USPS lists
the label formats PDF, TIFF, SVG, JPG, ZPL203DPI and
ZPL300DPI — the density is part of the format name. We could
not read the label size field in the current schema.
MyDHL API 3.4.0: imageOptions → encodingFormat
accepts zpl next to epl, lp2 and
pdf; DHL notes that invoices and receipts always come back as
PDF. Read on 2026-10-31; we did not read a density field.
Shipping API v2 (Buy Shipping): the requested document specification
takes a format of PDF, PNG or
ZPL, a size, a dpi and a page
layout; the values allowed for a shipment are those returned by
getRates (supportedDPIs). The label comes back
base64-encoded in the package documents.
ShipStation API: label_format = zpl. ZPL labels
are 4×6 inches only; the response gives a label_download.zpl
link, or base64 inline when you ask for that download type.
Set label_file_type to ZPLII when you create
the transaction; without it, the default format from the Shippo dashboard
is used. Shippo lists no size for the ZPL token.
Shipment options: label_format = ZPL; the
documented label_size for ZPL is 4x6, and carrier guides list
carrier-specific sizes.
In the GraphQL Admin API (2026-10), a shipping label's documents carry a
format of PDF or ZPL and a
url. We did not read a size or density for them.
With ZPL chosen, the Get Artifact call returns ZPL II commands, and the output format must be 4x6. Canada Post asks for a printer that can truncate text, and recommends PDF otherwise.
Shipping and Tracking API, create labels: a request with ZPL labels is
limited to 50 parcels, and the thermal layout is
THERMAL-LABEL-A6-1PP. Australia Post's help page for
international CN22 labels says ZPL is enabled for the CN22 label only, so
check which of your products it covers.
DPD's ShipmentService 3.5 (documented by DPD Switzerland):
printOptions.printerLanguage = ZPL,
paperFormat A6, and
printerResolution 203, 300 or 600 (also 150 and 200), which
must match the printer's head. DPD runs separate web services per country;
check your country's documentation.
Labelling webservice: printer type Zebra|Generic ZPL II at
200, 300 or 600 dpi. PostNL advises against sending PDF labels straight to
a Zebra printer.
Read on 2026-10-31 and 2026-11-02: the Trendyol common label
("format": "ZPL"), HepsiJet (zplBarcode),
Yurtiçi (docCargoZpl), Aras (ZebraZpl), UPS
Türkiye (CreateShipment_Type3_ZPL), Kolay Gelsin and Sendeo
(BarcodeZpl) and PTT AVM ("type": "zpl"). Calls
and fields: Trendyol
and HepsiJet ZPL labels.
Labelixa is not affiliated with any of the carriers or platforms named on this page; their names are used only to say which documentation was read.
Yes. Convert the ZPL to a PDF or PNG and print that on any printer. Each PDF page is the label size by default; print it at actual size (100%).
Yes. Post each ZPL file to the render endpoint from your shipping script and print the PDF or PNG it returns. Starter is $9 a month for 25,000 labels a month.
One label per page prints at full size when you print the label-size PDF at 100%. The A4 grid layouts put four or six labels on a page, scaled to about 90% or 60%.
Turn a spreadsheet into hundreds of ZPL labels: template variables, CSV column mapping, batch generation and the honest limits of each step.
Printing Trendyol and HepsiJet ZPL shipping labelsTrendyol's common label and HepsiJet's barcode API return ZPL, not a PDF. How to check it and send it to a Zebra-class thermal printer.
ERP label printing with ZPLWhere ERP label pipelines break, and the validation gate that stops a bad template before it reaches a warehouse printer.
UPS ZPL labels: request, preview and fixThe Shipping API fields behind a ZPL label (format code, stock size, character set), the per-package path to the payload and why density is read from the file.