App features
[Free plan]
Show images, text, custom HTML, recommended products, and coupons on the thank-you page
Adding just a LINE QR code is free!
* Up to 2 blocks for free
[Pro plan]
Place a coupon on the thank-you page and grow your subscribers by getting newsletter consent in exchange for issuing a coupon (delivered by email)
Note
For stores that have moved to the new thank-you page
Note: besides "SAKU Thanks Custom", this setup uses the "Shopify Flow" app (free) and the "Messaging" app (free).
[Terms] A "block" is a piece of content shown on the Thank you page (you create blocks in this app's "Blocks" page). The "app block" is "SAKU Thanks Custom", which you place in Shopify's checkout editor. Once the app block is in place, the blocks you created appear on the Thank you page.
The Thank you page (the page shown when a purchase is complete) appears as "Thank you" in Shopify's editor. They're the same page.
"SAKU Thanks Custom" helps you grow your email list from the Thank you page (the order completion page). Buyers who subscribe get a one-time coupon that only they can use, delivered by email. The coupon feature is available on the Pro plan ($4.99/month or $49.90/year). If you're on the Free plan, upgrade to the Pro plan. (A Partner development store is a free store that app developers and others create for testing; it can use every feature for free. A store that sells normally is not one of these.)
In this article
- How growing your email list works, and what buyers see
- Everything from creating a coupon block to sending emails with Shopify Flow and Messaging
- What to check when the email doesn't arrive
- The coupon code that's issued, and what's saved to the customer's details
Where to go: Shopify admin → Apps → "SAKU Thanks Custom" (Home) / Shopify admin → Apps → Flow / Messaging
First, how it works
- A coupon block is shown on the Thank you page (Pro plan).
- When a buyer ticks "Subscribe to our newsletter and receive this coupon by email" and presses the button, a coupon code just for them is issued.
- The issued code is delivered by email through Shopify Flow and Messaging.
- As a fallback in case the email doesn't arrive, the code can also be shown on the order status page.
- On the app's Home, you can see how many email subscribers you've gained this month and in total.
By default, the coupon code isn't shown on the page and is delivered only by email. Subscribing (ticking the box) is how buyers get the coupon.
- The "Subscribe to our newsletter and receive this coupon by email" checkbox starts ticked. You can change this with the "Pre-tick the subscribe checkbox" setting.
- When the code isn't shown on the page (the default), unticking the box disables the "Get your coupon" button.
- Buyers who already subscribe to your newsletter don't see the checkbox. They can press the button right away.
- If you turn on "Show the coupon code on the Thank you page", the code is shown on the spot right after the button is pressed. In that case, the button works even when the box is unticked (and buyers can choose "Also send by email" later).
Note: the coupon is shown only to buyers who are logged in. For guest checkouts (no login), the block itself isn't shown. Step 1-④ takes care of this.
1️⃣ Get ready
① Install Shopify Flow
It's free and works on stores on the Basic plan or higher: https://apps.shopify.com/flow
② Install Shopify Messaging
It's free: https://apps.shopify.com/shopify-messaging
③ Subscribe to the "SAKU Thanks Custom" Pro plan
The Pro plan is $4.99/month or $49.90/year (with a 7-day free trial). Partner development stores are free and can use every feature. On the Free plan, you can't create coupon blocks and no codes are issued. For how to subscribe, see "The differences between the Free and Pro plans, and how to change plans".
④ Change your checkout settings (to prevent guest checkouts)
In the Shopify admin, open "Settings" → "Checkout" and, under "Customer contact method", tick "Require customers to log in before checkout". After the change, "Save" appears on the screen. Be sure to press it, or the setting won't take effect. The setting applies to orders placed from then on. Guest orders that have already been placed won't get a coupon.

With new customer accounts, even first-time buyers just enter the verification code sent to their email, and an account is created and logged in automatically. Shopify warns that requiring login may cause some customers to abandon checkout. Keep this in mind when you change the setting.
2️⃣ Add the coupon block to the order status page (a fallback if the email doesn't arrive)
In the app's Home, under the setup guide step "3. Add the coupon block to the Order status page", press "Open Order status page". The checkout editor opens. On the left, press the "+" to the right of "SAKU Thanks Coupon", choose "Order status" under "Add to:", and press "Save" at the top right.

The red boxes show the page switcher, the main "Add block", "SAKU Thanks Coupon" and "Save".
Even buyers whose email didn't arrive can see their issued code by logging in and opening the order status page. For detailed steps, see How to show the coupon code again on the order status page.
3️⃣ Create a coupon block
In the left menu, go to "Blocks" → "Create block" → "Coupon". "Coupon" has a "Pro plan" badge.

The form runs in this order: "Basic settings" → "Coupon" → "Wording" → "Appearance" → "Display rules" → "Before you turn this on". The meaning and default of every setting are covered in Every coupon block setting explained. Here we cover only the most important parts.
If you're not sure what to enter, use this example: Discount type "Percentage off", percentage "10", valid for "30" days, "Limit the code to a single use" on, and minimum subtotal left blank. For "Button text", the pre-filled "Get your coupon" is fine as it is.

The red boxes show "Basic settings" and "Coupon" (discount type, percentage, validity, single use, minimum subtotal), and the preview on the right.
- "Coupon": enter the "Discount type" ("Percentage off", "Fixed amount off" or "Free shipping"), the percentage or amount, "Valid for (days after it is issued)", "Limit the code to a single use" and "Minimum subtotal to redeem (optional)". The minimum subtotal applies to the next order (when the coupon is used), not this one.

- "Wording": fill this in while watching the preview on the right. "Button text" is required and starts as "Get your coupon".
- "Show the coupon code on the Thank you page": when on, the code is shown on the spot right after the button is pressed. When off (the default), the code isn't shown on the page and is delivered by email.
- "Pre-tick the subscribe checkbox": the initial state of the checkbox. Set it in line with the consent rules that apply to your customers.

The red boxes show the devices, display rules and customer tags, "Before you turn this on", and the "Save" button.
- "Display rules": choose "Who can get it" (Everyone / First-time buyers only / Repeat buyers only (not their first order)), "Minimum order total for this order (optional)", "Show on devices", "Display rule" and "Customer tags (comma-separated)". The block is shown only to buyers who meet all of them.
When you're done, press "Save".
After saving, check that the block is "Active". Next, place "SAKU Thanks Custom" on the Thank you page. If you haven't placed it yet, follow step 6 of "How to add images and text to the Thank you page" and make sure to press "Save" at the top right. The coupon isn't shown until it's placed.

The red boxes show the page switcher, the main "Add block" and "SAKU Thanks Custom".
You can create more than one coupon block (for example, a first-purchase reward and a repeat-buyer reward). Each block issues at most one code per order. If an order matches several blocks, a separate code is issued for each block. When you place several coupon blocks, blocks whose conditions don't match are skipped and the rest move up (the order is kept).
4️⃣ Import the workflow into Shopify Flow
Shopify Flow's template list may show "Email the thank you page coupon to new subscribers" (only on stores that have installed this app). It's the same workflow. Either way, you still need to write the email and paste the Custom Liquid separately.
Next, you set up the "workflow" that sends an email when a coupon is issued. Just import the file and the trigger and condition are already configured. Don't turn it "on" yet.
Open "Help" in the app's left menu and, in the "Send the coupon by email (Shopify Flow + Shopify Messaging)" section, download the workflow file "saku-thanks-coupon-email.flow".
Then, in the Shopify admin, open "Apps" → "Flow", choose "Import" from the workflow list, and import the downloaded file.

Open the imported workflow "SAKUサンクスカスタム:メールでクーポン送付" (the name is in Japanese and means "SAKU Thanks Custom: send coupon by email") and press "Edit".

The workflow works like this:
- Trigger "Thank you page coupon issued": runs when the app issues a coupon.
- Condition: whether the buyer's email marketing state is "SUBSCRIBED".
- "Send marketing email": sends the email. The email body is empty, so you'll create it in the next step.
Open the "Send marketing email" step and press "Select template".

5️⃣ Create the email in Messaging
You're taken to the Messaging app. From here on, you work inside Messaging. Each store writes its own email body, so this part is done by hand.
- If a screen for setting up your brand (logo and colors) appears, set your store's logo and colors and press "Next" at the top right. If this screen doesn't appear, go straight to the template list.
- In the template list, choose "Blank".

- Enter the "Subject".
- Press "Add section" at the bottom left and add "Text" (greeting) → "Custom Liquid" (coupon details) → "Text" (closing), in that order. "Custom Liquid" is the section that automatically inserts the coupon code and other details into the email (if Messaging shows "Custom HTML" instead, choose that).

Example text:
- Subject: Here's a coupon for your next purchase
- Greeting: Thank you for your purchase. As a token of our appreciation, here is a coupon you can use on your next order.
- Closing: We look forward to serving you again.

Paste the code below into the "Custom Liquid" section, exactly as it is, without changing a single character. Place it between the greeting and the closing. Keep only one "Custom Liquid" section per email.
Drag the mouse from the top left to the bottom right of the code box to select all of it, then copy it (Ctrl+C on Windows, Command+C on Mac). Click the input field of the email's "Custom Liquid" section and paste it (Ctrl+V on Windows, Command+V on Mac).
{% assign coupon = customer.metafields['app--380928032769'].coupon_code | strip %}
{% assign expires = customer.metafields['app--380928032769'].coupon_expires_at | strip %}
{% assign reward = customer.metafields['app--380928032769'].coupon_reward | strip %}
{% assign once = customer.metafields['app--380928032769'].coupon_single_use | strip %}
{% assign coupon_head = coupon | slice: 0, 7 %}{% assign coupon_size = coupon | size %}
{% if coupon_head != 'THANKS-' or coupon_size != 13 %}{% assign coupon = '' %}{% endif %}
{% if coupon != blank %}
<div style="text-align:center; padding:16px 0;">
<p style="font-size:16px; margin:0 0 8px;">Your coupon code for next time</p>
<p style="font-size:28px; font-weight:bold; letter-spacing:2px; margin:0 0 12px;">{{ coupon | escape }}</p>
<p style="font-size:14px; color:#555; margin:0; line-height:1.8;">
{% if reward != blank %}{{ reward | escape }} off your order{% endif %}
{% if expires != blank %}<br>Valid until {{ expires | date: "%b %d, %Y" | escape }}{% endif %}
{% if once == 'true' %}<br>* One use per customer{% endif %}
<br>* Valid only on your registered account
</p>
</div>
{% endif %}
In the Messaging editor preview, the coupon section looks empty. That's normal (the sample customer has no coupon). Check it with a real order.
Finally, press "Set as active" at the top right. Make sure the "This email is in draft" notice has disappeared. A draft email is never sent.
6️⃣ Go back to Flow and turn on the workflow
In the Shopify admin, open "Apps" → "Flow" and click the workflow you imported in step 4, "SAKUサンクスカスタム:メールでクーポン送付", to open it. In the "Send marketing email" step, check that the email you created in step 5 is selected. Then press "Turn on workflow" at the top right.

7️⃣ Check that it works
- Check by actually buying something in your own store. While logged in, add one product to the cart and go all the way through checkout. The screen that appears when the purchase is complete, such as "Thank you for your order", is the Thank you page. Don't cancel or refund the order until you've finished checking (cancelling or refunding makes the coupon disappear). The coupon is no longer shown once 24 hours have passed since the order. On live stores, test orders don't issue coupons. On Partner development stores (stores for testing), test orders do issue them.
- In the Shopify admin, open "Apps" → "Flow" and check Flow's run history ("Recent runs") to confirm the workflow ran and succeeded.
- Check that the email arrived and shows the coupon code, the discount and the expiry date.

How it looks in your store after setup
On the buyer's Thank you page, it's shown like this:

Before claiming, the block shows, in order: border (optional) → display title → discount line ("[ 10% OFF ]", "[ ¥500 OFF ]", "[ Free shipping ]") → the checkbox "Subscribe to our newsletter and receive this coupon by email" (only for buyers who aren't subscribed yet) → note → button → "Text under the button".
| Situation | What the buyer sees |
|---|---|
| Right after pressing the button | The button changes to "Issuing...". |
| After claiming (code not shown) | "Your coupon has been issued and will be sent to your email address." (you can change this text in the settings) appears and the button disappears. If the order status block is in place, "You can also find your coupon code on the order status page after logging in." appears in small text. The code isn't shown on the page. |
| After claiming (code shown) | "Your coupon has been issued." (can be changed) → the code → "Valid until [date]" → "Valid on purchases of … or more" when there's a minimum subtotal → the buttons "Use this coupon" and "Copy code". |
| Code shown, and claimed without ticking the checkbox | "Tick the box and press the button below to also receive this coupon by email." appears with a checkbox and an "Also send by email" button (it can't be pressed while the box is unticked). After pressing it, the message changes to "This coupon will also be sent to your email address." If the buyer was already subscribed or claimed with the box ticked, this message is shown from the start. |
| Page reloaded or opened on another device | For the same order and the same block, the same code is shown again. No extra codes are created. |
| When a coupon can't be issued | "This coupon isn't available for this order." and "Try again" appear. While payment is processing, "Payment is still processing. Try again after it completes." and "Try again" appear. |
When the buyer's language isn't Japanese, the built-in text is in English, such as "10% OFF", "Valid until …", "Copy code" and "Use this coupon". The title, button text and messages you entered in the block are shown as they are, without translation.
If some orders don't show the button, see What to check when coupons aren't shown or issued. Guest checkouts and orders whose payment isn't complete (convenience store payment, pay-later, bank transfer and so on) aren't eligible.
What's created in your store when a coupon is claimed
When the claim button is pressed, a discount code is created under "Discounts" in Shopify, and this app's own fields (coupon code, expiry date, discount and whether it's single use) are saved to the buyer's customer details. You can see these fields in the admin, but you can't edit them. They're overwritten the next time the customer claims a coupon. For details, see "How issued coupons, customer data and the Flow trigger work".
You can also open these steps from the app's Home
The setup guide on the app's Home has step 4, "Send the coupon by email" (with "Pro plan" and "Optional" badges). Open the step and you'll find a "View the illustrated guide" button, which opens the SAKU Apps blog (support articles) in a new tab. If the right article doesn't open, open this article from the blog list (https://saku-apps.com/en/blogs/thanks). This step isn't checked automatically, so tick its checkbox yourself when you're done.

"About this app" on the right side of Home also says: "After creating a block, add the app block in the checkout editor. See Help for the full setup steps." The "Help" page in the app's left menu has the same content as this article (the Shopify Flow + Messaging steps, the Custom Liquid code to paste and the workflow file).
Troubleshooting
-
The email doesn't arrive
Check these in order. ① Is the Flow workflow on, and does its run history show a successful run? ② Is the Messaging email set to active with "Set as active"? (A draft is never sent.) ③ Does the email have a "Custom Liquid" section, and is the code unchanged? (If the coupon section is empty, the code is missing or was changed. Paste it again.) ④ Marketing emails only reach subscribed customers. If only some people don't get it, check their email marketing state. -
I can't "Set as active" the email
If you see a message saying that {{customer.*}} variables are limited to one section per email, there are two "Custom Liquid" sections. In the editor, select the section that looks blank, delete it with the trash icon, and press "Set as active" again. -
Does the app check that the email arrived?
No. The app can only confirm that it sent the Flow trigger. It can't check your Flow settings or whether the email arrived. If you don't show the code on the page, test the email path first. As a fallback, also place the order status page block. -
The email goes to the spam folder
This is more likely when you send from Shopify's shared address. In the Shopify admin, go to "Settings" → "Notifications", change the sender email to an address on your own domain, and complete domain authentication (SPF/DKIM). Also make sure your store name and address are set correctly. Nothing can fully prevent spam filtering, so place the order status page block as a fallback as well. -
The Flow trigger fails
Temporary failures are retried automatically (up to 5 times). Errors that retrying won't fix, such as permission denied, aren't retried. Check Flow's run history. -
The code isn't shown on the page, but nothing arrives even when the box is ticked
Buyers who claim with the box ticked become "Subscribed" and meet the condition of the included workflow. Check that the Flow condition is set to SUBSCRIBED and that the email is set to active. -
Some orders don't get a coupon
Coupons aren't issued for guest checkouts, orders whose payment isn't complete, orders more than 24 hours old, and so on. See the full list of things to check.