Skip to main content
The back-in-stock button shows on a product page when the variant the shopper selects is sold out. The shopper clicks the button, gives a phone number and agrees to one WhatsApp message. When the variant is back in stock, TextYess starts your automation with the “Product Back in Stock” trigger once for each shopper on the list.
A sold-out product page with the Notify me on WhatsApp button under the Add to cart area
The alert is sent by an automation with the “Product Back in Stock” trigger. Before you install the button, open the “Setup” tab of the back-in-stock page and click “Create automation”. If this button does not show, create the automation in “Automations”. Then publish the automation. Until an automation is live, shoppers wait on the list. They get the message on the first restock after the automation is live. The “Waitlist” tab shows who is waiting.
The Product Back in Stock trigger followed by the WhatsApp alert step on the flow canvas

Two ways to install

Install from the theme editor

This method changes no theme code. It needs an Online Store 2.0 theme.
1

Open the theme editor from TextYess

In TextYess, click “Growth Tool Kit” in the menu. On the “Back-in-stock button” card, click “Set up the button”. In the “Install” card, click “Open Shopify Theme Editor”.Shopify opens your product template. The “TextYess Back in Stock” block is already in the main section. It is not saved yet.
2

Move the block under Add to cart

Drag the block under the “Add to cart” button. Click “Save”.
If the block is not there, open the “Apps” section of the product template and add “TextYess Back in Stock”. Shopify always shows this name in English.
3

Set the colors and the texts

Go back to the back-in-stock configurator in TextYess. Set the colors, the texts and the “Ask on WhatsApp” button. Click “Save”. Your store shows the change within a few minutes.The block in the theme editor also has a switch for the “Ask on WhatsApp” button and a consent line. When either switch is off, the button does not show. The consent line you save in TextYess replaces the one in the block.
4

Check a sold-out product

In the editor, open a product that has a sold-out variant. The button shows under “Add to cart”. On a variant that is in stock, only a grey note stays. Shoppers never see that note.
The block uses the settings you saved in the back-in-stock configurator. Until you save, it takes its colors and corner radius from “Widget brand style” in the Growth Tool Kit. Button shape and text size always come from “Widget brand style”. A text you did not change shows in the shopper’s own language.

Install with the code snippet

Use this method when your theme is older, or when you want the button somewhere the block cannot go. The block goes on the product template only. Make a backup of your theme before you edit it.
1

Set the texts and the colors

In TextYess, click “Growth Tool Kit” in the menu. On the “Back-in-stock button” card, click “Set up the button”. Change the button label, the colors and the consent line. The preview on the right uses a real product from your catalog.
2

Copy the snippet

In the “Install” card, under “Install with code”, click “Copy snippet”. The snippet carries your store id, your texts and your colors.
3

Open the theme code

In Shopify, open “Online Store”, then “Themes”. Click the three dots on your theme, then “Edit code”.
4

Paste the snippet under the Add to cart button

Open the file that renders the buy buttons on the product page. Common names are main-product.liquid and buy-buttons.liquid. Paste the snippet after the “Add to cart” button, then click “Save”.
If you cannot find the buttons, press cmd + F on Mac or ctrl + F on Windows and search for cart.
5

Check a sold-out product

Open a product that has a sold-out variant. The button shows under the disabled “Add to cart” button. On a variant that is in stock, the button does not show.
If the button never shows on a sold-out product, the snippet is in a file that does not know which product the page shows. Move it into the product template, next to the “Add to cart” button.
If you installed the snippet before September 2026, copy it again. The older snippet does not follow the variant the shopper selects.

What shoppers see

At first the product page shows the “Notify me on WhatsApp” button. It stands next to “Ask on WhatsApp” when you keep that second button on. The phone field and the consent line open on the first click. The button follows the variant on the page. A shopper who switches from an in-stock variant to a sold-out one sees the button right away. If a page has the block and the snippet, the shopper sees only the snippet. The snippet keeps your own colors and your own consent line.

What shoppers agree to

The consent line under the button is a service consent for one alert. It does not add the shopper to your marketing list, and it does not change their marketing opt-in. You can edit the wording in the configurator, or in the block settings.