Dawn Theme - How To Add Terms Conditions Checkbox To Cart?

Topic summary

Main issue: adding a Terms & Conditions (T&C) checkbox to the cart in the Dawn theme, where older “vintage theme” instructions (theme.js, cart-template.liquid) don’t apply.

Key guidance and solutions:

  • Staff confirms the linked tutorial targets vintage themes; suggests using free apps (e.g., ROAR, EZ Terms) or hiring a developer for custom code.
  • Community code solution (Dawn): create a ‘cart-termsbox’ snippet and register a new block in sections/main-cart-footer, then render it and add via Theme Customizer. Notes: disable dynamic checkout buttons and use Cart popup/page. A detailed external guide is provided. Images/GIFs and code snippets are central.
  • Unchecked by default: simple snippet edit shared to make the checkbox start unchecked.

Cart drawer (slide-out mini cart):

  • Multiple requests to support the drawer. A working approach was shared by rendering the snippet directly in cart-drawer.liquid and hardcoding settings (since drawer lacks blocks). This enforces an unchecked, mandatory checkbox before payment.

Other updates:

  • A 2024 video tutorial link was shared.

Open questions (unresolved):

  • Show T&C only for certain product variants.
  • Implement purely via code without using the Customizer.
Summarized with AI on December 30. AI used: gpt-5.

Hi Renster,

I have just implemented the terms and conditions checkbox to cart page of Dawn theme recently, by utilizing the section block feature. (Demo below)

Demo of checkbox

Here’s the code which can copy paste below.

Go to your theme editor, go to the Sections folder, and Add a new snippet file named “cart-termsbox”

And paste this code into the file :


  
  
  

Next, search for “main-cart-footer” file (located in sections/main-cart-footer), scroll to the bottom, and add the following code right before the { “type”: “@app” } part :

{
  "type": "termsbox",
  "name": "Termsbox",
  "limit": 1,
  "settings": [
    {
      "id": "prelink_text",
      "type": "text",
      "label": "Text before the link to the terms",
      "default": "I have read"
    },
    {
      "id": "link_text",
      "type": "text",
      "label": "The link text of the terms",
      "default": "Terms and Conditions"
    },
    {
      "id": "postlink_text",
      "type": "text",
      "label": "Text after the link to the terms",
      "default": " and agree"
    },
    {
      "id": "terms_page",
      "type": "page",
      "label": "Terms and Conditions page"
    },
    {
      "type": "range",
      "id": "checkbox_scale",
      "min": 1,
      "max": 3,
      "step": 0.1,
      "label": "Checkbox size",
      "default": 1.2
    },
    {
      "type": "checkbox",
      "id": "mandatory",
      "label": "Customer must check the checkbox to checkout",
      "default": true
    },
    {
      "id": "internal_label",
      "type": "text",
      "label": "Internal label that will be shown in the order's Additional Details",
      "default": "Customer agreed to terms"
    }
  ]
},

Then on the same file, you can add the following code, after the render block line that is below "when ‘@app’ ":

{%- when 'termsbox' -%}
  
    {% render 'cart-termsbox' , block: block %}
  

Then after saving, you can go to your Shopify Admin, select the theme and click “Customize” , then navigate to the Cart page :

In the “Subtotal” sections on the left side bar, you can click “Add block”, and select “Terms box” (which is the snippet code you have added earlier) :

You can then edit the text for the checkbox, and click Save :

You would have to ensure customer can only checkout from the cart page, which means you have uncheck the “dynamic checkout button” on the product page in the Theme customize, and also change the “Cart type” to either “Popup” or “Page” in the Theme settings (the settings icon on left side bar in theme customize)

I have written a more detailed guide with screenshots on how to add this checkbox here : https://yagisoftware.com/articles/how-to-add-agree-to-terms-and-conditions-checkbox-in-shopify

Hope this can help!

Regards,

Axel Kee

2 Likes