ZPL compatibility of the OpenZPL engine
The OpenZPL engine draws the 51 ZPL commands of the command reference, one of them partially, and skips the ones that configure the printer. The barcode and text commands listed under “Not supported yet” don't draw correctly today.
Tested 2026-10-20 with openzpl-api 689632b at 8 dpmm.
How we test
Every example on this site is a fixture: a short synthetic label that the engine renders to a PNG when the site is built. If a fixture's ZPL changes and its image isn't rendered again, the build fails, so the image always shows what the engine does with that exact code.
The 115 fixtures are public in fixtures.json, with their size, density and image, under CC0. Use them to test any ZPL renderer.
A preview isn't a print. Darkness, media, firmware and the fonts installed on a printer change the result, so check critical labels on the printer itself.
Drawn
| Command | ماذا يفعل | Category | Evidence |
|---|---|---|---|
^XA |
يفتح ملصقاً. كل شيء حتى ^XZ هو ملصق واحد. | تنسيق الملصق | Rendered example |
^XZ |
يغلق الملصق المفتوح بواسطة ^XA ويطبعه. | تنسيق الملصق | Rendered example |
^PW |
يحدد عرض الملصق بالنقاط. | تنسيق الملصق | Rendered example |
^LL |
يحدد طول الملصق بالنقاط. | تنسيق الملصق | Rendered example |
^LH |
يغير الأصل الذي يتم قياس كل موقع حقل منه. | تنسيق الملصق | Rendered example |
^LS |
ينقل كل حقل إلى اليسار بعدد النقاط المعطاة. | تنسيق الملصق | Rendered example |
^LT |
يحرك اللصاقة بالكامل لأعلى أو لأسفل بعدد صفوف النقاط المعطاة. | تنسيق الملصق | Rendered example |
^PO |
يطبع التسمية بشكل عادي (N) أو مقلوب (I). | تنسيق الملصق | Rendered example |
^PM |
يعكس اللصاقة بالكامل أفقيًا عند تعيينه إلى Y. | تنسيق الملصق | Rendered example |
^PQ |
يحدد عدد الملصقات التي سيتم طباعتها؛ كل واحدة تُعتبر ملصقًا في المعاينة. | تنسيق الملصق | Rendered example |
^MU |
يغير وحدة القياس إلى نقاط أو بوصات أو مليمترات. | تنسيق الملصق | Rendered example |
^CI |
يختار مجموعة الأحرف. ^CI28 هو UTF-8. | تنسيق الملصق | Rendered example |
^FO |
يحدد موقع الحقل: إحداثيات x، y بالنقاط من الزاوية العلوية اليسرى. | الحقول والموقع | Rendered example |
^FT |
يضع حقلًا بناءً على خط قاعدته بدلاً من الزاوية العليا اليسرى. | الحقول والموقع | Rendered example |
^FD |
نص أو بيانات الباركود للحقل الحالي. | الحقول والموقع | Rendered example |
^FS |
ينهي الحقل الحالي. | الحقول والموقع | Rendered example |
^FB |
يلف النص في كتلة بعرض وعدد خطوط ومحاذاة. | الحقول والموقع | Rendered example |
^FR |
يطبع الحقل بالأبيض على الأسود فوق أي شيء تحته. | الحقول والموقع | Rendered example |
^FH |
يسمح لـ ^FD احتواء الهكس الهارب مثل _0D. | الحقول والموقع | Rendered example |
^FW |
يحدد التدوير الافتراضي للحقول التالية. | الحقول والموقع | Rendered example |
^FN |
يسمي حقلًا متغيرًا في تنسيق مخزن. | الحقول والموقع | Rendered example |
^FX |
تعليق. يتجاهل الطابعة كل شيء حتى الأمر التالي. | الحقول والموقع | Rendered example |
^SN |
يطبع رقمًا يزداد في كل تسمية. | الحقول والموقع | PartialRead but not drawn: the serial field is left out and copies aren't incremented (the same as Labelary's preview). Rendered example |
^A |
يختار الخط، التدوير والحجم للحقل النصي التالي. | النصوص والخطوط | Rendered example |
^A@ |
يختار خطا حسب اسمه في الطابعة. | النصوص والخطوط | Rendered example |
^CF |
يحدد الخط والحجم المستخدمان عندما لا يحتوي الحقل على ^A. | النصوص والخطوط | Rendered example |
^CW |
يعيّن اسمًا وحيد الحرف لملف خط. | النصوص والخطوط | Stores or recalls data; no image of its own |
^BY |
يحدد عرض الوحدة، نسبة العرض إلى الارتفاع والارتفاع لرموز الشريط التالية. | الرموز الشريطية | Rendered example |
^BC |
رمز شريطي كود 128، الأكثر شيوعًا على ملصقات الشحن. | الرموز الشريطية | Rendered example |
^B3 |
رمز شريطي كود 39. | الرموز الشريطية | Rendered example |
^B2 |
رمز شريطي 2 من 5 متداخلة، رقمي فقط. | الرموز الشريطية | Rendered example |
^BE |
رمز شريطي للبيع بالتجزئة EAN-13. | الرموز الشريطية | Rendered example |
^B8 |
رمز شريطي للبيع بالتجزئة EAN-8. | الرموز الشريطية | Rendered example |
^BU |
باركود البيع بالتجزئة UPC-A. | الرموز الشريطية | Rendered example |
^B9 |
باركود البيع بالتجزئة UPC-E. | الرموز الشريطية | Rendered example |
^BQ |
رمز الاستجابة السريعة. تبدأ البيانات بتصحيح الأخطاء ووضع الإدخال، مثل QA، | الرموز الشريطية | Rendered example |
^BX |
رمز شريطي ثنائي الأبعاد من شبكة البيانات. | الرموز الشريطية | Rendered example |
^B7 |
رمز شريطي ثنائي الأبعاد PDF417 متراص. | الرموز الشريطية | Rendered example |
^BO |
رمز شريطي أزتك ثنائي الأبعاد. | الرموز الشريطية | Rendered example |
^BD |
ماكسي كود، يُستخدم بواسطة UPS. | الرموز الشريطية | Rendered example |
^GB |
يرسم مربعًا أو خطًا: العرض، الارتفاع، سمك الحدود، اللون والزاوية. | رسوميات | Rendered example |
^GC |
يرسم دائرة: القطر، سمك الحدود واللون. | رسوميات | Rendered example |
^GE |
يرسم بيضاوي. | رسوميات | Rendered example |
^GD |
يرسم خطًا قطريًا. | رسوميات | Rendered example |
^GF |
يدمج صورة نقطية في العلامة (أسكي hex، ثنائي أو Z64). | رسوميات | Rendered example |
^GS |
يطبع رمزًا مسجلاً أو علامة تجارية أو رمزًا آخر. | رسوميات | Rendered example |
^DF |
يخزن تنسيق الملصق على الطابعة تحت اسم. | التنسيقات والصور المخزنة | Rendered example |
^XF |
يسترجع تنسيقًا مخزنًا لملء حقول ^FN الخاصة به. | التنسيقات والصور المخزنة | Rendered example |
~DG |
يخزن صورة على الطابعة تحت اسم. | التنسيقات والصور المخزنة | Stores or recalls data; no image of its own |
^XG |
يطبع صورة مخزنة باستخدام ~DG. | التنسيقات والصور المخزنة | Stores or recalls data; no image of its own |
^IM |
يطبع صورة مخزنة عند أصل الحقل الحالي. | التنسيقات والصور المخزنة | Stores or recalls data; no image of its own |
Ignored on purpose
These commands set up the printer, not the label. The API accepts them and renders the label as if they weren't there; we checked that the image is byte-identical without them.
| Group | Commands |
|---|---|
| Media and sensors | ^MM, ^MN, ^MT, ^MF, ~JS |
| Speed, darkness and tear-off | ^PR, ~SD, ^MD, ~TA |
| Calibration and printer state | ~JC, ~JA, ~JR, ^JU, ~HS |
| Network, RFID setup and host queries | ^NC, ^NI, ^RS, ~HI, ~HM |
Not supported yet
Each one was tested by placing it in a label at 8 dpmm. None of them fails the request: the label renders, without the symbol.
| Command | Symbology or feature | What the engine does today |
|---|---|---|
^TB | Text block | Text is drawn on one line; the block doesn't wrap. Use ^FB instead. |
^B0 | Aztec (alias) | No symbol drawn. ^BO, the other Aztec command, is drawn. |
^B1 | Code 11 | No bars; the data is printed as text. |
^B4 | Code 49 | No bars; the data is printed as text. |
^B5 | Planet Code | No bars; the data is printed as text. |
^BA | Code 93 | No bars; the data is printed as text. |
^BB | CODABLOCK | No symbol; the data is printed as text. |
^BF | MicroPDF417 | No symbol; the data is printed as text. |
^BK | ANSI Codabar | No bars; the data is printed as text. |
^BL | LOGMARS | No bars; the data is printed as text. |
^BM | MSI | No bars; the data is printed as text. |
^BP | Plessey | No bars; the data is printed as text. |
^BR | GS1 DataBar | No symbol; the data is printed as text. |
^BS | UPC/EAN extensions | No bars; the data is printed as text. |
^BT | TLC39 | No symbol; the data is printed as text. |
^BZ | POSTAL | No bars; the data is printed as text. |
Known differences
- A format with no fields, such as
^XA^XZ, returns400 ERROR: No labels found in the ZPLinstead of a blank image. - Fonts: Zebra's font 0 (CG Triumvirate Bold Condensed) can't be bundled, so
^A0is drawn with Roboto Condensed Bold, with spacing calibrated per character. The bitmap fonts^AA–^AHare drawn with DejaVu Sans Mono. Text widths can differ by a few dots from a given printer. - An RFID write (
^RFfollowed by^FD…^FS) draws its data as text; a printer encodes it in the tag and prints nothing.
Moving from Labelary
The API keeps Labelary's v1 paths and headers, so most clients only change the host. See Migrate from Labelary for the tested differences and OpenZPL vs Labelary for the comparison.