SBPL Command Reference
All 51 SATO Barcode Printer Language commands — grouped by category with syntax, parameters, and examples.
Control
ESC+ASupportedThis is the opening command for every SBPL label — like pressing "New Document". It tells the printer "I'm about to describe a label". Every SBPL job must begin with ESC+A.
ESC+ZSupportedThis closes the label and triggers printing. Think of it as pressing "Print". Every label that starts with ESC+A must end with ESC+Z.
ESC+QSupportedSets how many copies of the label to print. The number can be 1 to 999999. If you don't specify this, the printer defaults to 1 copy.
ESC+IDUnsupportedAssigns a numeric ID to the print job. This is used for job management — you can reference the ID to cancel or track a specific job in the printer's queue.
ESC+WKUnsupportedAssigns a human-readable name to the print job. This appears in the printer's status display and job listings, making it easier to identify what's printing.
Position
ESC+HSupportedSets where the next item will be placed horizontally (left-to-right) on the label. The value is in dots from the left edge. At 203 DPI, there are about 8 dots per millimetre.
ESC+VSupportedSets where the next item will be placed vertically (top-to-bottom) on the label. The value is in dots from the top edge. At 203 DPI, about 8 dots per millimetre.
ESC+#SupportedSets a base offset that shifts everything on the label. All subsequent ESC+H and ESC+V positions are relative to this reference point. It's like setting page margins — instead of adjusting every position, you offset the entire design.
Text & Fonts
ESC+PSupportedSets the character spacing (pitch) for bitmap fonts. Higher values add more space between characters. This controls the dot gap between each character in the current font.
ESC+LSupportedEnlarges the current font by multiplying its width and height. The first two digits set horizontal enlargement, the second two set vertical enlargement. For example, L0202 doubles both width and height.
ESC+%SupportedRotates the next field. 0 = no rotation, 1 = 90 degrees clockwise, 2 = 180 degrees (upside-down), 3 = 270 degrees clockwise. Applies to text, barcodes, and 2D codes.
ESC+PSSupportedEnables proportional spacing — each character takes up only as much width as it needs ("i" is narrower than "m"). This gives a more natural, professional look to text.
ESC+PRSupportedDisables proportional spacing and returns to fixed-width (monospaced) mode. Every character takes the same width, which is useful for aligning columns of data.
ESC+ESupportedSets the automatic line feed spacing in dots. When enabled, text commands automatically advance the vertical position by this amount after printing. Set to 0 to disable.
ESC+X20SupportedSelects the tiny X20 bitmap font (5 dots wide, 9 dots tall) and prints the text that follows. This is the smallest built-in font — good for fine print and dense information.
ESC+X21SupportedSelects the X21 bitmap font (17 dots wide, 17 dots tall) and prints the text. A small-to-medium fixed-width font, suitable for general-purpose text.
ESC+X22SupportedSelects the X22 proportional font (24 dots base) and prints the text. This is one of the most commonly used SBPL fonts — a good default for readable label text.
ESC+X23SupportedSelects the large X23 proportional font (48 dots base) and prints the text. A big, bold font for headings and prominent information.
ESC+X24SupportedSelects the X24 proportional font (48 dots base) and prints the text. Similar in size to X23, but a different typeface. Offers an alternative look for large text.
ESC+XUSupportedSelects the Helvetica-style scalable font and prints the text. This is a clean, professional sans-serif font commonly used for product labels.
ESC+XSSupportedSelects the small Universe Condensed Bold font and prints the text. A condensed font that fits more characters per line.
ESC+XMSupportedSelects the medium Universe Condensed Bold font (24 dots base) and prints the text. This is the default font used by the SBPL engine when no font is explicitly selected.
ESC+XBSupportedSelects the large Universe Condensed Bold font (48 dots base) and prints the text. A large, bold condensed font for headings that need to be dense but impactful.
ESC+XLSupportedSelects the large Sans Serif font (48 dots base) and prints the text. A clean, large sans-serif typeface for prominent text.
ESC+USupportedSelects the tiny U bitmap font (5 dots wide, 9 dots tall) and prints the text. A monospaced micro font for extremely dense or technical data.
ESC+SSupportedSelects the S bitmap font (8 dots wide, 15 dots tall) and prints the text. A small monospaced font — readable and compact.
ESC+MSupportedSelects the M bitmap font (13 dots wide, 20 dots tall) and prints the text. A medium monospaced font — good for data that needs to align in columns.
ESC+WBSupportedSelects the WB bitmap font (18 dots wide, 30 dots tall) and prints the text. A large monospaced font — bold and easy to read.
ESC+WLSupportedSelects the WL bitmap font (28 dots wide, 52 dots tall) and prints the text. The largest built-in monospaced font — for text that absolutely must be read from a distance.
Graphics
ESC+FWSupportedDraws a ruled line or box at the current position. You specify vertical border width, horizontal border width, vertical length, and horizontal length in dots. If the border widths are thin and the lengths are large, you get a rectangle outline. If one length is very small, you get a line.
ESC+FCSupportedDraws a circle at the current position. You specify the radius and line width in dots. The centre of the circle is at the current H,V position.
ESC+FTSupportedDraws a triangle by specifying three corner points and a line width. Each point is given as x,y coordinates in dots.
Barcodes
ESC+BGSupportedPrints a Code 128 barcode — the most versatile 1D barcode that can encode all 128 ASCII characters. It automatically selects the most efficient subset (A, B, or C). This is the go-to barcode for most modern labelling applications.
ESC+BSupportedPrints a Code 39 barcode with a 1:3 wide-to-narrow ratio. Code 39 is one of the oldest barcode standards — it encodes uppercase letters, digits, and a few special characters. The 1:3 ratio produces a more compact barcode.
ESC+DSupportedPrints a Code 39 barcode with a 1:2 wide-to-narrow ratio. This produces a wider, more easily scanned barcode compared to ESC+B. The wider ratio improves readability at the cost of more label space.
ESC+BCSupportedPrints a Code 93 barcode. Code 93 is a denser version of Code 39 — it encodes the same characters but takes up about 25% less space. It includes two mandatory check characters for higher reliability.
ESC+BISupportedPrints a GS1-128 barcode (formerly EAN-128). This is the supply-chain standard — it uses Code 128 encoding but adds GS1 Application Identifiers (AIs) to structure the data. AIs identify what each piece of data means (lot number, expiry date, weight, etc.).
2D Codes
ESC+2D30SupportedPrints a QR code — the familiar square matrix barcode you see everywhere. QR codes can hold thousands of characters and are scannable by any smartphone camera. They support error correction so they still work even if partially damaged.
ESC+2D50SupportedPrints a DataMatrix code — a compact 2D barcode popular in manufacturing, electronics, and healthcare. It's smaller than QR for the same data, making it ideal for marking small items like electronic components or medicine vials.
ESC+2D10SupportedPrints a PDF417 barcode — a stacked 2D barcode that looks like a series of small 1D barcodes on top of each other. It can hold a lot of data and is used on ID cards, boarding passes, and postage stamps.
System
ESC+A1SupportedSets the label dimensions. V sets the vertical size (height, or feed length) and H sets the horizontal size (width) — both in dots. At 203 DPI, a standard 4"x2" label is about H0812V0406.
ESC+CSUnsupportedSets the print speed. Lower speeds give better print quality (sharper, more precise), while higher speeds increase throughput. The available speeds depend on your printer model.
ESC+#FUnsupportedSets the print darkness (head temperature). Higher values make the print darker but can cause smearing or ribbon wrinkle on thermal-transfer labels. Lower values produce lighter print but use less ribbon and extend head life.
ESC+POUnsupportedAdjusts the horizontal print position offset. This shifts the entire printable area left or right — useful for fine-tuning alignment when the print head doesn't perfectly line up with the label stock.
RFID
ESC+IP0UnsupportedWrites data to the EPC (Electronic Product Code) memory bank of a UHF RFID tag. The EPC is the main identifier stored on the tag — it's what gets read when an RFID reader scans the label. This is the core command for RFID-enabled labels.
ESC+IP5UnsupportedSets the RFID antenna power level. Higher power gives better read/write range but can cause issues with densely packed tags (reading the wrong tag). Lower power is more precise but the tag must be closer to the antenna.
Memory
ESC+&SSupportedStores the current label design as a form overlay in the printer's memory. A form overlay is like a template — the static parts of your label (logos, borders, fixed text) that don't change. You can recall it later with ESC+&R and only send the variable data.
ESC+&RSupportedRecalls a previously stored form overlay from the printer's memory and applies it to the current label. The recalled overlay provides the static design elements, and you add the variable data on top.
Calendar
ESC+WTSupportedConfigures the date/time format for calendar printing. The format string uses placeholders like YY (year), MM (month), DD (day), hh (hour), mm (minute). The printer substitutes these with its internal clock values at print time.
ESC+WPSupportedAdds or subtracts a fixed offset from the calendar date set by ESC+WT. Use this to print future or past dates — for example, an expiry date 1 year from the print date.
ESC+WASupportedPrints the date/time at the current position using the format previously configured with ESC+WT. The printer substitutes the format placeholders with its real-time clock values when the label is printed.
Try these commands live
The SBPL Playground lets you write SBPL and see labels render in real time — with syntax highlighting, autocomplete, and the full command reference built in.