Skip to content
NoteableInstall on Shopify

Guide

How to print the gift message on your Shopify packing slip

Updated

Shopify keeps a shopper’s gift message with the order, but your packing slip prints it only if its template asks for it. Find where your store keeps the message, then paste the matching lines of Liquid into the template.

Short answer

It depends on where your store keeps the message. The order note and each item’s message both print with a few lines of Liquid in Shopify’s packing slip template, under Settings › Shipping and delivery. Cart fields listed under “Additional details” aren’t among the template’s variables.

Where your store keeps the message

Open a recent order with a gift message and find the message on the order page. It’s in one of three places, and each one needs different lines in the template.

Where a gift message shows on the order page. The note and Additional details belong to the whole order. Line item properties sit under one item, so each gift can have its own message.
Where it showsIn the templatePrints
Notesorder.noteOnce per slip
Additional detailsNo variable for itNot on Shopify’s packing slip
Under an itemline_item.propertiesUnder each item

Print the order note

If the message is under Notes, it’s the order note. There’s one per order, however many gifts are in it.

  1. Open the template. In your Shopify admin, go to Settings Shipping and delivery and click Packing slip template in the Documents section. If Documents lists your document templates instead, click your packing slip template.
  2. Paste the snippet. Put it where you want the message to print, such as under the shipping address.
  3. Preview, then save. Preview the template, save it, and print the packing slip for an order that has a note.
Liquid · packing slip template
{% if order.note != blank %}
  <p><strong>Gift message:</strong> {{ order.note | escape | newline_to_br }}</p>
{% endif %}

newline_to_br keeps the shopper’s line breaks, and escape prints characters such as < just as they were typed. Anything else in the note, such as delivery instructions, prints too.

Print each item’s message

If the message sits under an item on the order page, it’s saved as that item’s line item properties, so each gift in an order can have its own message. In the template, find the loop that prints each item, which starts with {% for line_item in line_items_in_shipment %}, and paste this inside it, under the item’s title.

Liquid · inside the line item loop
{% for property in line_item.properties %}
  {% assign first_char = property.first | slice: 0 %}
  {% if property.last != blank and first_char != "_" %}
    <p>{{ property.first | escape }}: {{ property.last | escape | newline_to_br }}</p>
  {% endif %}
{% endfor %}

It prints each property that has a value, such as Recipient and Message, under its own item. Names that start with an underscore, such as Noteable’s _noteable_template_id, are an app’s own data, so it skips them.

“Additional details”

Some themes and apps add a field to the cart, such as a gift message box. Shopify lists what shoppers enter there under Additional details on the order page. Like the note, it belongs to the whole order, not to one item.

Shopify’s packing slip template can’t print these fields. Its variable reference has the order note and each item’s properties, but no variable for Additional details.

In Shopify Order Printer

Shopify Order Printer is Shopify’s free app for documents you design in HTML, CSS and Liquid, such as packing slips, invoices and pick lists. Its templates have the same order.note and line_item.properties, but loop over the items with {% for line_item in order.line_items %}. Print from an order with More actions Print with Order Printer, or select several orders on the Orders page and print them together.

To see how it compares with printing on a card, read Noteable vs Shopify Order Printer for gift messages.

Where this stops

The message prints in the packing slip’s own layout and font, on plain paper. That’s fine for packing, but it isn’t a card to tuck in with the gift. To print it on your own card design, read How to print gift messages from Shopify orders.

Questions

Why isn’t the gift message showing on my packing slip?

Usually the template doesn’t print the place your store keeps it. Find the message on the order page, then add the matching lines to the packing slip template: order.note for the order note, or a loop over line_item.properties for a message under an item.

What is “Additional details” on a Shopify order?

It lists the fields a theme or app adds to the cart, such as a gift message box or a delivery date. They belong to the whole order, not to one item, and Shopify’s packing slip template has no variable for them.

How do I hide properties that start with an underscore?

Skip them in the loop: print a property only when its name doesn’t start with an underscore. The snippet on this page does this. Apps keep their own data in those properties, so the person packing the order never needs to see them.

Can each item’s message print separately?

Yes, if the message is saved with each item as line item properties. Put the loop inside the template’s item loop and each message prints under its own item. An order note prints once for the whole order.

Do I need an app to print the gift message on the packing slip?

No. A few lines of Liquid in Shopify’s packing slip template print it for free. An app is for printing the message on a separate card in your own design.