1. Home
  2. Barcode & Generate
  3. ZPL Viewer

ZPL Viewer

Render ZPL label code in your browser. Your code never leaves the page.

Runs in your browser · No upload
Printer resolution (dpi)
Label 1 of 1
Labels
1
Size
101.6×62.6 mm · 812×500 dots
Fonts differ from your printer, so letter shapes and widths can vary a little. Do a test print for labels that matter.

How to use

  1. Paste ZPL code (^XA … ^XZ) into the box, or load a .zpl, .prn or .txt file. A sample is filled in at first.
  2. Choose the printer resolution (203, 300 or 600 dpi). Coordinates and sizes in ZPL are in dots, so the physical size depends on the resolution.
  3. By default the label size comes from ^PW (width) and ^LL (length) in the code. If either is missing, 4×6 in is assumed; you can pick a preset or type a size in mm instead.
  4. Check the preview, then save PNG (current label) or PDF (all labels, one page each).

Several ^XA…^XZ blocks make several labels; use Previous and Next to flip through them. Up to 200 labels are shown at a time.

Supported commands

Group Commands
Structure ^XA ^XZ ^PW ^LL ^LH (origin shift) ^PQ (quantity shown only) ^FX (comment)
Position and fields ^FO ^FT ^FD ^FV ^FS ^FR (reverse) ^FW (default rotation)
Text ^A0 to ^AZ, ^A@ (size, rotation) ^CF (default font) ^FB (text block) ^FH (hex escapes) ^CI (encoding)
Shapes ^GB (box, line, rounding) ^GC (circle) ^GD (diagonal)
Barcodes ^BY ^BC (Code 128) ^BE (EAN-13) ^B8 (EAN-8) ^BU (UPC-A) ^B3 (Code 39) ^BQ (QR) ^BX (Data Matrix) ^B7 (PDF417)

Setup commands starting with ~ and print settings that do not change the picture, such as ^MM and ^PR, are skipped silently. Any other command (for example ^GF graphics or ^XG image recall) is not drawn and is reported on screen by command name and line number.

How it is drawn

  • Coordinates are used as printer dots, so ^FO50,60 is the 50th dot from the left and the 60th from the top. For example a 4×6 in label is 812×1218 dots at 203 dpi, and a 100×50 mm label is 799×400 dots.
  • Fonts are approximated with the browser’s sans-serif (for ^A0) and a monospace face (for bitmap fonts), not the printer’s built-in fonts. Letter widths and line breaks can differ a little from a real print.
  • Barcodes are drawn with one module (the thinnest bar) equal to the ^BY width in dots, so they come out at the printer’s size. If a value does not fit the symbology, for example a wrong EAN-13 length, a red dashed box and the reason are shown in its place.
  • With ^FH_, _5E becomes ^ and _7E becomes ~. Combined with ^CI28, consecutive bytes are read as UTF-8 characters (for example _EA_B0_80 is the Korean letter 가).
  • Unrotated text and barcodes placed with ^FT are aligned by baseline or bottom edge. The ^FT position of rotated fields differs between printers, so it is approximate.
  • Very large labels (longest side over 8000 px or more than 40 million pixels) are drawn at a reduced size.

Tips

  • Paste code made with the ZPL, TSPL & EPL Generator or the Label Maker to check the result before printing.
  • Labels often hold addresses and phone numbers. This tool never sends your code to an external preview service; it is drawn in this browser only.
  • Even a matching preview can print differently depending on printer settings (resolution, darkness, media), so test-print one label when it matters.

Related tools: ZPL, TSPL & EPL Generator, Label Maker, Barcode Generator, A4 Label Sheet Printer.

Your code is processed only in your browser and is never sent to a server.

Can't find the tool you need?

Tell us what you want to do. We build the most requested tools first.