How to Add a Gift Message to Shopify Order Emails Without an App

2026-11-22 · upselling

Gift messages are one of the cheapest ways to make a Shopify order feel personal—and you don't need a paid app to collect them or print them in your order emails. Shopify's built-in cart notes field and order notification templates can do the whole job with a few lines of Liquid. This guide walks through the full setup, from adding the message field to testing the email before a real customer sees it.

Why Add a Gift Message to Order Emails (Without an App)

Most gift message apps charge a monthly fee and inject a script into your theme. For a small store, that's overhead you can skip. Shopify already lets customers leave a note at checkout, and order notification templates can pull that note into the confirmation email automatically.

Doing it yourself has three practical advantages:

The tradeoff is that you're editing Liquid, Shopify's templating language. The steps below keep the code minimal so you don't need to be a developer.

What You Need Before You Start

Before touching any code, confirm you have the following:

One clarification on terminology: Shopify's default "note" field on the cart page is a general order note. Customers can type anything there—delivery instructions, gift messages, or nothing. If you want a dedicated gift message field, you'll need to either rename the note field or use checkout UI extensions (available on Shopify Plus and some plans). For most small stores, repurposing the cart note is the simplest path, and that's what this guide covers.

Step 1: Add a Gift Message Field to Your Cart or Checkout Notes

Shopify's cart note field is enabled by default in most themes, but you should verify it's visible and labeled clearly.

  1. In your Shopify admin, go to Online Store > Themes > Customize.
  2. Open the Cart template (or the cart drawer, depending on your theme).
  3. Look for the cart note block. In Dawn and most modern themes, it's a block called Cart note that you can enable under the cart section settings.
  4. Change the label text to something explicit, like "Gift message (optional)". In Dawn, you can edit this in the theme language settings under Online Store > Themes > Edit default theme content, searching for "Note".
  5. Save.

If your theme doesn't include a cart note block, you can add one manually by editing sections/main-cart-footer.liquid (or your theme's equivalent) and inserting a textarea bound to the cart.note object:

<label for="CartNote">Gift message (optional)</label>
<textarea name="note" id="CartNote">{{ cart.note }}</textarea>

The name="note" attribute is what tells Shopify to save the input as the order note. Don't change it.

Step 2: Find the Right Order Notification Template in Shopify

Go to Settings > Notifications in your admin. You'll see a list of customer and staff notifications. The one you want is Order confirmation, which is sent to the customer immediately after purchase.

A few notes on which template to edit:

Click Order confirmation to open the editor. You'll see an HTML email template with Liquid tags. Click the <> code view toggle if you're in the visual editor, since you'll be pasting Liquid directly.

Step 3: Insert the Liquid Snippet Into Your Order Confirmation Email

Find a logical spot in the template—typically after the order summary table and before the shipping address block. Paste this snippet:

{% if note != blank %}
  <div style="margin: 24px 0; padding: 16px; border-left: 4px solid #c9a227; background-color: #faf7ef;">
    <p style="margin: 0 0 8px; font-size: 13px; text-transform: uppercase; letter-spacing: 1px; color: #7a6a3a;">Gift message</p>
    <p style="margin: 0; font-size: 16px; line-height: 1.5; color: #333;">{{ note }}</p>
  </div>
{% endif %}

How this works:

If you want the message to appear in the shipping confirmation too, repeat the same snippet in that template. The note variable is available in all order-related notifications.

Step 4: Style the Gift Message So It Stands Out

Email clients are notoriously inconsistent with CSS. Inline styles (as in the snippet above) are the safest approach. A few rules that keep the message readable across Gmail, Apple Mail, and Outlook:

A quick comparison of output options:

Liquid tag What it does When to use
{{ note }} Outputs the note as-is Single-line gift messages
{{ note | newline_to_br }} Converts line breaks to <br> tags Multi-line messages
{{ note | escape }} Escapes HTML characters If you're worried about customers pasting HTML
{{ note | strip_html }} Removes any HTML tags Safest for user-generated content

For most stores, {{ note | escape | newline_to_br }} is the best default—it strips the risk of injected HTML while preserving line breaks.

Step 5: Test Your Gift Message Email Before Going Live

Don't rely on the preview alone. Run through these checks:

  1. Place a test order with a gift message in the cart note field. Use a real checkout, then cancel and refund the order afterward.
  2. Open the confirmation email on both desktop and mobile. Check that the gift message box renders correctly and the text is legible.
  3. Place a second test order with an empty note. Confirm the gift message block doesn't appear at all.
  4. Test with a long message (200+ characters) to make sure the box expands without breaking the layout.
  5. Use Shopify's "Send test email" button in the notification editor to preview with sample data before sending a real order.

If you want to preview with a specific note value, Shopify's test email uses placeholder data. For accurate testing, a real test order is the most reliable method.

Common Liquid Mistakes and How to Fix Them

Conclusion

Adding a gift message to Shopify order emails without an app takes about 15 minutes of setup and zero ongoing cost. The cart note field handles collection, and a short Liquid snippet with an {% if %} check handles display. Test with real orders before going live, and keep a backup of your template so you can revert if needed.

FAQ

Can I use a separate field just for gift messages instead of the general cart note? On standard Shopify plans, the cart note is the simplest option. A dedicated gift message field requires checkout UI extensions, which are available on Shopify Plus and select plans—check your plan's checkout customization features.

Will the gift message appear on the packing slip too? Yes, if you add the same {{ note }} snippet to the packing slip template under Settings > Notifications. The note variable is available there as well.

What happens if a customer writes something inappropriate in the note field? The note is customer-generated content and will appear in their own confirmation email. It's not displayed publicly. If you're concerned about HTML injection, use the escape or strip_html filter as shown in Step 4.