Skip to content

Custom Blocks: Free Text, Divider, Custom Liquid and Metafields

The four blocks you can add anywhere on a template, or inside a built-in block: a message, a separator line, your own HTML and Liquid, and selected metafield values.

Medium BusinessUpdated 2026-11-02

Adding and Removing

Hover the canvas: a + button appears just below the middle of each block's bottom outline, and built-in blocks have a second one below its left end. Add Block inserts the new block after it; Add Block Inside places it inside a built-in block (one level deep), so it moves and hides with that block. Below Enterprise, Metafields is listed but greyed out. Pick one of the four below. Unlike the built-in blocks, these can be deleted with Delete Block in their ⋯ menu. They are available for invoices and estimates alike.

Free Text

A heading and a paragraph for a thank-you note, bank details or any fixed message.

  • Show Heading and Heading Text (printed only when not empty).
  • Content: the body; line breaks are kept.
  • Align: Left, Center or Right, for both.

Free Text prints exactly what you type and never reads order data; use Custom Liquid for that.

Divider

A thin horizontal line between sections. It has no settings.

Custom Liquid

Your own HTML and Liquid, with the whole document's data available: order, line_items, customer, shop, metafields and the rest of the Liquid Variables.

  • Heading: optional, hidden when empty.
  • Liquid Code: the code, written right in the block panel in a code font, with spell-check off. Each Custom Liquid block keeps its own code, so several can sit on one template.

A Custom Liquid or Metafields block that prints nothing for the order shows a placeholder in the editor, so you can still select it; the document leaves it out.

<p>Thanks for your order, {{ customer.first_name }}!</p>
{% if order.note_attributes.size > 0 %}
  <p>
    {% for attr in order.note_attributes %}
      {{ attr.name }}: {{ attr.value }}<br>
    {% endfor %}
  </p>
{% endif %}

HTML prints as written. Empty code prints nothing. Code with a Liquid error shows the error banner in the Template Editor and on the template's preview page, and Save stays unavailable until it is fixed; on documents it prints nothing, so the rest of the document still renders. Order values are made safe for HTML before your code sees them (a customer's name can never inject markup). See Liquid and CSS Basics.

Metafields

Prints the order, customer or shop metafields you pick, one "Label: value" row each Enterprise. First select the metafields in Settings → Metafields; the block's picker then lists them under Order, Customer and Shop (on estimates, Order lists the Draft Order metafields you selected). A metafield set to Keep First Value there is marked Keeps first value: it prints the value kept when the document was first made.

  • Select Metafields: tick the entries to print. Under Display Order & Labels rename each printed label and move it with ↑ and ↓.
  • Show Divider Above and Hide When Empty (on by default; off keeps an empty row so the layout stays the same).

A customer metafield prints only when the order has a customer, money, rating, measurement and link metafields print readably ("$12.50", "4 / 5", "2.5 kg", a link with its own text), and any other value starting with https:// prints as a View link. Product and variant metafields belong to each line, so they are switched on in the Line Items block instead. See Using Metafields in Templates.

Was this guide missing something? Tell us and we will fix it.

Contact Us