ZPL Text Cut Off or Wrong Size

Fix text that is clipped at the label edge, too small, too large, or a different size than expected in ZPL.

Text is cut off

Text is clipped when part of it falls outside the printable area. Check:

  1. Print width. ^PW must match your label width in dots. A 4-inch label at 203 DPI is ^PW812. If ^PW is too small, the printer crops at that width.
  2. Position + length. Compute: starting x + text width must be less than ^PW. A long string at ^FO700 on a 812-dot label runs off the edge.
  3. Label home offset. ^LH shifts every field. A non-zero ^LH moves content right and down.
  4. Rotation. In rotated text (R, B), length runs along the vertical axis, so it can run past ^LL.
  5. Media setup. The printer’s configured label width may be narrower than your actual media; check with ^XA^HH^XZ.

Wrap long text instead of letting it run off

^XA
^PW812
^FO40,40^A0N,36,36^FB720,3,6,L,0^FDThis long product description wraps inside a 720 dot wide block of at most three lines.^FS
^XZ

^FB takes width, maximum lines, extra line spacing, justification and hanging indent. Text that exceeds the maximum lines is truncated, so give enough lines.

Text is too small or too large

Cause Fix
Designed for 203 DPI, printing on 300 or 600 Scale dots, see sizes by DPI
Bitmap font not at a valid multiple Use a multiple of the base size, or font 0
^A missing, so ^CF or the factory default applies Add ^A to the field
Height given but width not, or the reverse Specify both
^CF set earlier changed the default Search for other ^CF commands
Printer is set to a different resolution Check DPI on the configuration label

Calculate exact values with the size calculator.

Text looks stretched or squashed

In scalable fonts h and w are independent. ^A0N,50,100 is twice as wide as tall. Make them equal for natural proportions, or slightly narrower for condensed text.

Text overlaps other fields

Estimate the width of a line: roughly 0.5 x w x number of characters for font 0 (varies by characters). Leave clearance, or measure with the live preview.

Bitmap text looks blocky

That’s how bitmap fonts work when enlarged. Switch to font 0 or a TrueType font for smooth edges.

Start by finding out which problem you’ve got

“Cut off” and “wrong size” sound similar but have different causes, and mixing them up leads you astray. Cut-off text means part of it is outside the area the printer will print. Wrong-size text means the characters are being drawn at a different size than you intended. A line that’s too long and runs off the edge is cut off, while a line that prints entirely but looks smaller than last week’s labels is a size problem. Decide which you have, then use the matching section.

Cut-off text: measure before you guess

Take a ruler to the printed label, or better, work it out on paper. Measure from the left edge to where the text starts and note how long the text is. Convert both to dots using the size calculator. If the starting position plus the text length is more than the print width, the text can’t fit, however you tweak things.

If the maths says it should fit, look at the settings that define the printable area. The print width ^PW is the main one, and it’s often left at a default that’s narrower than the label. The label home ^LH shifts everything, so a forgotten offset can push text partly off the label. The printer’s own media settings matter too: if the printer thinks it has a narrower label loaded than you actually have, it may crop. Print a configuration label to see what it believes.

Rotated text deserves its own warning. When a field is rotated, its length runs along the vertical axis. A long rotated line can run off the bottom of the label while the same text unrotated would have fitted comfortably across the top.

Let the printer wrap long text

If the length of the text varies, such as product names or addresses, stop trying to guess the right size. Use a field block, which wraps text inside a box of a given width. You set the width, the number of lines, and the spacing, and the printer does the rest. The one trap is the line limit: text beyond the maximum number of lines is simply dropped, so give the block more lines than you expect to need. You can try this out in the live preview using the wrapped text sample.

Also decide what happens when text is too long even for the box. Options include shrinking the font for long values, truncating with an ellipsis in your own software, or flagging the record for review. Silent truncation on a shipping label is how parcels go astray.

Wrong-size text: look at the usual suspects

The first suspect is resolution. A label written for 203 DPI will come out roughly two-thirds the size on a 300 DPI printer. Our guide to font sizes by DPI has the details, and the blog post on 203 versus 300 DPI works through an example.

The second suspect is the bitmap font rule. Bitmap fonts can only be a whole multiple of their base size, so a height you type might be quietly rounded. If you want exact sizes, use font 0 or a downloaded font. See the built-in font list.

The third is a missing or misplaced ^A. A field without its own font command uses the default, and the default is tiny unless you’ve changed it. If a field looks much smaller than its neighbours, check it has its own ^A, and that the command comes before the ^FD, not after. The syntax is covered in the ^A command guide.

Finally, remember that the number in ^A is the height of the character cell. Capital letters occupy only part of it, so don’t expect the printed capitals to match the number.

A tidy way to avoid all of this

Design in millimetres, convert to dots in code, set ^PW and ^LL explicitly in every label, give every field its own font command, and use field blocks wherever text length varies. Then keep one test label with the longest realistic strings and print it whenever anything changes.

Questions

Why is my text slightly off-centre? Centring in ZPL needs a field block with a width, or a calculation of the text width. Positions alone won’t centre text.

My label looks right in the preview and wrong on paper. Compare the printer’s configuration label with your settings.

Can I auto-shrink text to fit? Not in ZPL by itself. Calculate in your software, then send a smaller height.

Is there a font that never overflows? No, but a condensed width in font 0 helps. Learn more in fonts for small labels.

Last reviewed 2026-10-20