Skip to content
Log in

Create or update a POS label template

On this page

In StoreConnect, label templates are created using ZPL (Zebra Programming Language) or EPL (Eltron Programming Language), combined with Liquid to inject dynamic product data. ZPL is supported by Zebra printers; EPL is used by older Eltron and Datamax hardware.

You will need to be able to write ZPL or EPL and use Liquid to create dynamic templates. You will also need Salesforce Admin access to add and update templates.

:::tip You don’t need to write ZPL from scratch. Free online ZPL preview tools let you design and test labels in the browser before adding them to StoreConnect. AI tools are also well-suited to generating ZPL for common label layouts — describe your label and ask it to produce the commands. Once you have working ZPL, wrap it in Liquid to inject product data. :::

Add or update a label template

  1. Open the StoreConnect Console.
  2. Go to POS Configuration and select POS Printer Templates.
  3. Select New or open an existing template.
  4. Give the template a Name — use something descriptive, for example “Label — barcode 40×30”.
  5. In the Context field, select label.
  6. In the Printer Type field, select Label.
  7. Enter your label code in the Content field. A sample is provided below.
  8. Select Save.
  9. Test the output and adjust until you are happy with the results.

Sample template

This sample is designed for a 40mm wide × 30mm high label (320 × 240 dots at 8 dots per mm). Adjust ^PW and ^LL values if your label size differs.

```liquid

{% for product in products %} ^XA ^PW320 ^LL240

^FX Product code ^CFA,15 ^FO0,15^FB320,1,,C,^FD{{ product.product_code }}^FS

^FX Product name - centred, max 2 lines ^CF0,22 ^FO0,38^FB320,2,10,C,^FD{{ product.name }}^FS

^FX Code 128 barcode ^FO37,85^BY2,,50^BCN,50,Y,N,N^FD{{ product.barcode }}^FS

^FX Print date ^CF0,22 ^FO15,192^FB150,1,,L,^FD{{ ‘now’ | date: “%m/%d/%Y” }}^FS

^FX Price ^CF0,32 ^FO15,180^FB290,1,,R,^FD{{ product.pricing.price | money }}^FS

^XZ {% endfor %} ```

Explanation of sample template

```liquid

{% for product in products %} // Loop over selected products — one label per product

^XA // Start of label format ^PW320 // Label width in dots (320 dots = 40mm at 8 dots/mm) ^LL240 // Label height in dots (240 dots = 30mm at 8 dots/mm)

^FX Product code ^CFA,15 // Font A, height 15 ^FO0,15^FB320,1,,C,^FD{{ product.product_code }}^FS // Full width, centred

^FX Product name - centred, max 2 lines ^CF0,22 // Font 0, size 22 ^FO0,38^FB320,2,10,C,^FD{{ product.name }}^FS // Up to 2 lines, centred

^FX Code 128 barcode ^FO37,85^BY2,,50^BCN,50,Y,N,N^FD{{ product.barcode }}^FS // ^BCN is Code 128

^FX Date ^CF0,20 // Font 0, size 20 ^FB100,1,,L, // Align left ^FO20,195^FD22/09/23^FS // Fixed date — replace with Liquid for a dynamic date, e.g. // {{ ‘now’ | date: “%d/%m/%Y” }} for DD/MM/YYYY (AU/UK) // {{ ‘now’ | date: “%m/%d/%Y” }} for MM/DD/YYYY (US) // The date filter is not locale-aware — use whichever format suits your region

^FX Price ^CF0,32 // Font 0, size 32 ^FO15,180^FB290,1,,R,^FD{{ product.pricing.price | money }}^FS // Align right

^XZ // End of label format

{% endfor %} // End of product loop ```

Available variables

Label templates receive a products array and a quantity value. Iterate over products to generate one label per product.

Variable Description
products Array of products to print labels for
quantity Number of labels to print per product (default: 1)

Key properties available on each item in the products array:

Property Description
product.name Product name
product.product_code Product code / SKU
product.barcode Barcode value
product.pricing.price Product price (use with the money filter)
product.sfid Salesforce record ID

To print multiple labels per product, use a nested loop:

```liquid

{% for product in products %} {% for i in (1..quantity) %} … label content … {% endfor %} {% endfor %} ```

Was this article helpful?

Was this article helpful?