TSPL vs ZPL: differences, compatibility and conversion
A label template works on one printer but not on its replacement. Before changing cables or rewriting the layout, check the command language. TSPL and ZPL can describe similar labels, yet their instructions are not interchangeable. Some printers offer emulation, while others need a converted template or a different output from the software. This guide explains the distinction and shows how to plan a small, testable migration.

What are TSPL, TSPL2 and ZPL?
TSPL and TSPL2 are programming languages documented by TSC for label printers. Their readable commands include SIZE, CLS, TEXT, BARCODE and PRINT. TSPL2 is not another name for ZPL: TSC documents differences between TSPL and TSPL2, including font behavior. A command or font available on one device may not behave identically on another. Use the manual for the actual model and firmware as your reference.
ZPL means Zebra Programming Language. ZPL II label formats commonly start with ^XA and finish with ^XZ, with instructions such as ^FO for positioning and ^FD for field data. Both language families describe label content; neither name tells you the paper size, transport connection or resolution. A USB cable and an Ethernet connection can carry the same language, and a different cable does not translate it.
The practical differences that affect a label
The first difference is syntax. TSPL uses command names followed by parameters, often separated by commas. ZPL uses compact command prefixes and field terminators. The second difference is how fonts, coordinates and printer settings are interpreted. Similar-looking text is not proof of identical font metrics. Compare the printed width of long product names, not only a short demonstration word.
Avoid treating one language as universally better. A working TSPL application may be the right choice for an existing installation. ZPL can fit a system that already produces ZPL templates. The relevant questions are which commands the device supports, what your software exports and how you will maintain the templates. Include logos, special characters, barcode types and stored resources in that assessment.
Can a TSPL printer print ZPL?
Some TSC printers offer firmware with ZPL emulation; TSC documents language families such as TSPL-EZ and TSPL-EZD. Emulation means the printer interprets another language. It does not make TSPL source code identical to ZPL or guarantee every command behaves exactly like the original device. Check the supported languages for the exact printer configuration, then test representative labels.
Separate three questions: what language is in the file, what language the printer accepts, and what the driver sends. Print a configuration report or consult the manufacturer utility and manual. A product listing saying “thermal label printer” is not enough. Before converting, see whether the generating application can already export the target language. That can reduce manual maintenance and preserve variable data handling.
The same message in TSPL and ZPL
The examples below print HELLO on a label approximately 50 × 30 mm at 203 DPI. The TSPL sample declares millimeters; the ZPL sample uses 400 × 240 dots. Rounding means the sizes are approximate. They demonstrate equivalent intent rather than identical typography: TSPL font 3 and ZPL font 0 have different metrics. Keep the sample separate from live shipping data.
In TSPL, SIZE sets the format, GAP describes the media gap, CLS clears the image buffer, TEXT places the text and PRINT requests output. Adjust the example’s 2 mm gap to match your stock before a physical test. The ZPL example does not configure gap sensing. Set up media and calibration for the target printer independently; a language example is not a complete hardware setup script.
TSPL
SIZE 50 mm,30 mm
GAP 2 mm,0 mm
CLS
TEXT 30,30,"3",0,1,1,"HELLO"
PRINT 1,1ZPL
^XA
^PW400
^LL240
^FO30,30^A0N,24,16^FDHELLO^FS
^XZDPI: converting commands does not preserve physical size automatically
At 203 DPI, 400 dots measure approximately 50 mm. At 300 DPI, the same 400 dots measure about 34 mm. This affects field positions, text size and barcode modules. Converting a command name without accounting for resolution can produce a label that fits on screen but has the wrong physical dimensions. Note the source and target DPI before editing anything.
For the same physical size, scale dot-based dimensions by target DPI divided by source DPI, then review rounding and barcode requirements. Do not scale encoded barcode data or numeric product identifiers. Millimeter-based settings and dot-based coordinates require different treatment. In the current EditorZPL TSPL converter, physical SIZE values are converted using 203 DPI; selecting another preview DPI does not regenerate all coordinates for that resolution.
How to convert TSPL to ZPL in EditorZPL
Keep the original TSPL file and a known-good printed reference. Open the converter, paste or import one complete label and inspect the generated ZPL. Review the warnings and compare the preview at the intended dimensions. Check every field, including text that may look unimportant: a batch number or a truncated address can invalidate an otherwise attractive label.
The converter handles common layout commands, not a complete printer program. It approximates font metrics, skips BITMAP graphics and does not preserve every setup instruction. Commands such as DIRECTION, REFERENCE, CODEPAGE and PRINT are currently skipped, so orientation, character handling and copy counts need explicit review. REVERSE is approximated by a filled box. These are converter limitations, not evidence that ZPL cannot represent those features.
Open the TSPL-to-ZPL converterA migration checklist before production
Test the longest realistic text, accented characters, empty fields, rotated elements and your actual barcode data. If the converter reports an unknown barcode type, stop and review the mapping: it may substitute Code 128. A barcode that scans is not necessarily the requested symbology or payload. Compare scanner output with the source values and with the requirements of the receiving system.
Print a small sample on the destination device using the real media. Check physical dimensions, orientation, contrast, clipping and quiet zones. Missing logos may need to be rebuilt or installed separately. Test one label before a batch, and verify quantities instead of assuming the TSPL PRINT settings survived. Keep the previous template available and record the printer model, firmware, DPI and conversion changes for future maintenance.
When to keep TSPL, use emulation or migrate
Keep TSPL when your application and printer support it reliably and no requirement justifies a change. Consider documented emulation when replacing a device while retaining existing templates. Convert when the receiving workflow requires ZPL and native export is unavailable. Compare these routes with a representative label rather than choosing by language age or the printer brand alone.
If a simple label works but a production template fails, add its elements back one at a time. Separate communication problems from layout problems: a device that receives no job needs a different investigation from one that prints an incomplete barcode. The aim is a repeatable workflow with checked output, not merely a file that passes a converter without warnings.
Frequently asked questions
Are TSPL and ZPL the same language?
No. Their syntax and interpretation differ. Similar labels require different instructions unless the printer offers suitable emulation.
Can every TSC printer accept ZPL?
Do not assume so. Check the specific model, firmware and enabled emulation, then validate your actual template.
Can I preview TSPL online?
The TSPL-to-ZPL tool converts supported instructions and previews the resulting ZPL. It is not a complete TSPL firmware emulator; omitted or approximated commands can affect the preview.
Can this tool convert ZPL back to TSPL?
This tool converts TSPL to ZPL. The reverse direction requires a separate implementation or a template exported by your label software; changing the extension is not conversion.
Related guides
Official references
- TSC: TSPL/TSPL2 Programming Manual
- TSC: Customizable Printer Language Firmware
- TSC: FAQs — TSPL-EZ / TSPL-EZC
- Zebra: ^XA — Start Format
References and converter behavior checked on 4 October 2026. AI-generated illustration of generic printers.
About the author
Eduard Diaz
Eduard Diaz is an IT technician (development) at S-IE, an official Zebra partner with more than 20 years providing identification and labelling services. He builds and maintains EditorZPL to make working with ZPL and Zebra label printers easier.
s-ie.cat