Sign In
Products
ZPL ViewerBarcode GeneratorImage → ZPLZPL cheat sheetLabel DesignerTemplate Gallery
Developers
API QuickstartAPI ReferenceMCP ServerBulk GenerationWebhooksSDKs & ExamplesLimitsDirectPrint agent NewGitHub ActionVS Code extensionOn-Premise
Solutions
Logistics & ShippingE-CommerceERP & WMSManufacturingRetailHealthcare & LaboratoryAll solutions
Tools
ZPL Diagnostics HubZPL DebuggerSize & DPI AnalyzerDPI ConverterBarcode fit calculatorShipping Label AnalyzerFont InspectorOrientation DebuggerCalibration AssistantPrinter Compatibility CheckerBarcode Readability CheckerPrinter Language DetectorThermal Printer Test PackZPL ToolsEPL ToolsTSPL ToolsCPCL ToolsPrinter Language ConverterAll ToolsGuidesPricing
Language
EnglishTürkçeDeutsch
Home›All TSPL commands›REFERENCE

REFERENCE — Origin

Shifts the origin of the coordinate system; every field is placed relative to this point.

Engine status: Rendered

This command produces visible output in the preview.

Syntax

REFERENCE x, y

Example

SIZE 100 mm, 150 mm
GAP 3 mm, 0 mm
CLS
REFERENCE 0, 0
PRINT 1

Open this example in the preview →

Open the validator →

Rendered example

REFERENCE 0, 0

Output of the example above in our renderer (203 dpi). Not verified on a physical printer.

Parameters

ParameterMeaning
x, yNew origin in dots; every later field is placed relative to it

Common mistake

Forgetting that REFERENCE carries over: the origin stays shifted for the following labels in the stream; send REFERENCE 0, 0 when the next label expects the plain origin.

The same job in other languages

ZPL equivalent: ^LH · EPL R · Language comparison

All TSPL commands

SIZE · GAP · CLS · TEXT · BARCODE · QRCODE · BOX · BAR · BITMAP · PRINT · DIRECTION · DENSITY · SPEED · OFFSET · SET · CODEPAGE · BLINE

All TSPL commands