Skip to product information
1 of 1
Published:2026.08.26

[Horizon] Show pre-purchase confirmation checkboxes and block the Add to Cart button until all are checked

[Horizon] Show pre-purchase confirmation checkboxes and block the Add to Cart button until all are checked

Applications

  • 商品情報管理・編集
View full details

Add a single "Pre-purchase Checkbox" block to your Horizon product page to show up to three confirmation checkboxes — terms of service, return policy, and so on. While even one checkbox is left unchecked, an overlay blocks the Add to Cart button and accelerated-checkout buttons like Shop Pay together.

Result: an overlay blocks the buy buttons until every checkbox is checked


How to add it (1): Add the block via the code editor

◆Shopify admin → Online Store → Themes → "…" → Edit code

Step 1: select Edit code from the theme list menu

◆In the blocks folder, create a new file named pre-purchase-checkbox.liquid and paste the purchased code, then save

Step 2: create a new file in the blocks folder and paste the code


How to add it (2): Add the block in the theme editor

◆Theme editor → Product page template → "Product information" → "Details" → "Add block" → select "Pre-purchase Checkbox"

Step 3: add the Pre-purchase Checkbox block in the theme editor and fill in the settings


Settings

◆Checkbox items 1–3: a checkbox is shown for each item you fill in. Blank items are hidden
◆Message shown when unchecked: the text shown inside the overlay (use <br> for line breaks)


How it works

While any checkbox is left unchecked, an overlay is layered on top of the element that wraps the Add to Cart and accelerated-checkout buttons, blocking clicks. Instead of disabling each button individually, this approach covers the whole button group — including Shopify's native payment buttons like Shop Pay, which can't be disabled directly via JavaScript.


See the Dawn version here → [Dawn] Show a checkbox on the Dawn theme's product page and enable the buy button once all boxes are checked

After making a purchase (all items are ¥0), you will be able to view the sample code.

If you have already made a purchase, please login here.

Sample Codes

Test Theme :Horizon 4.1.1

blocks/pre-purchase-checkbox.liquid(新規作成)