
Quality guarantee
A high-trust product page section that displays brand quality markers and certifications. It features a two-column layout with a grid of icon-led benefits, a call-to-action button, and a flavor-conditional image display system.
- Icon-based benefit grid
- Flavor-conditional image logic via data attributes
- Fully responsive two-column to single-column layout stack
- Custom typography and hover-state button animations
- Showcasing manufacturing standards (e.g., Made in England) on PDPs.
- Displaying quality certifications like Third Party Tested or Organic.
- Building customer confidence via a transparency section.
- Most Shopify themes
The code
1<div id="shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB" class="shopify-section">234<style>5 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .section_holder {6 padding-top: 50px;7 padding-bottom: 50px;8 }9 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .section_holder_wrapper {10 display: flex;11 max-width: 1360px;12 margin: auto;13 padding: 0 80px;14 min-height: 200px;15 }16 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .left_part {17 min-width: 1px;18 width: 100%;19 margin-right: 80px;20 }21 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .right_part {22 min-width: 1px;23 width: 100%;24 }25 [data-subject] {26 display: none;27 }28 [data-subject='Coffee'] {29 display: block;30 }31 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .seciton_title {32 color: #000001;33 font-family: 'TAN - MEMORIES';34 font-size: 44px;35 font-weight: 400;36 line-height: 1.2;37 letter-spacing: -1px;38 margin-bottom: 22px;39 }40 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .sction_subheading {41 color: #000;42 font-family: Apercu Pro;43 font-size: 20px;44 font-weight: 500;45 line-height: 1.5;46 letter-spacing: -0.2px;47 margin-bottom: 40px;48 }49 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .section_items {50 display: grid;51 grid-template-columns: 1fr 1fr;52 grid-gap: 32px 22px;53 margin-bottom: 56px;54 }55 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .item_text {56 align-self: stretch;57 color: #000;58 display: flex;59 flex-direction: column;60 font-family: Apercu Pro;61 font-size: 18px;62 font-weight: 500;63 justify-content: flex-start;64 letter-spacing: -.01em;65 line-height: 1.5;66 max-width: 100%;67 position: relative;68 }69 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .item_image {70 width: 48px;71 height: 48px;72 margin-bottom: 12px;73 }74 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .right_part img {75 width: 100%;76 height: 100%;77 object-fit: cover;78 }79 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .section_btn {80 align-items: center;81 background: #f27;82 border-radius: 10px;83 border-style: solid;84 border-width: 0;85 column-gap: 12px;86 display: flex;87 flex-direction: row;88 flex-wrap: nowrap;89 justify-content: center;90 margin: 16px 0 0;91 padding: 16px 32px;92 position: relative;93 row-gap: 12px;94 transition-duration: 50ms;95 transition-timing-function: ease-in-out;96 width: fit-content;97 color: #fff;98 display: flex;99 flex-direction: column;100 font-family: Apercu Pro;101 font-size: 20px;102 font-weight: 700;103 justify-content: center;104 letter-spacing: -.01em;105 line-height: 1.4;106 position: relative;107 text-decoration: none;108 }109 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .section_btn:hover {110 background: #000;111 border-style: solid;112 border-width: 0;113 }114 @media screen and (max-width: 900px) {115 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .section_holder_wrapper {116 flex-direction: column-reverse;117 }118 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .left_part {119 margin-right: 0;120 margin-top: 30px;121 }122 }123 @media screen and (max-width: 768px) {124 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .section_btn {125 width: 100%;126 }127 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .section_holder_wrapper {128 padding: 0 48px;129 }130 }131 @media screen and (max-width: 575px) {132 #shopify-section-template--17389125894327__pdp_quality_guarantee_v3_n63jFB .section_holder_wrapper {133 padding: 0 24px;134 }135 }136</style>137138<div pdp_q_guarantee="" class="section_holder">139 <div class="section_holder_wrapper">140 <div class="left_part">141 <div class="seciton_title">Quality guarantee -</div>142 <div class="sction_subheading">two of our core brand values are quality & trust, which is why everything we do is built on a foundation of excellence & transparency. Our products are -</div>143 <div class="section_items">144 <div class="section_item">145 <div class="item_image">146 <img src="//spacegoods.com/cdn/shop/t/346/assets/icon_bud.svg?v=139630195289706213671722621925" alt="icon_bud">147 </div>148 <div class="item_text">149 100% fruiting body of the mushroom150 </div>151 </div>152 <div class="section_item">153 <div class="item_image">154 <img src="//spacegoods.com/cdn/shop/t/346/assets/icon_flag.svg?v=154114963166449663751722621934" alt="Flag">155 </div>156 <div class="item_text">157 Proudly made in England158 </div>159 </div>160 <div class="section_item">161 <div class="item_image">162 <img src="//spacegoods.com/cdn/shop/t/346/assets/icon_pointed.svg?v=139022816020327971601722621943" alt="pointed">163 </div>164 <div class="item_text">165 Dual extracted166 </div>167 </div>168 <div class="section_item">169 <div class="item_image">170 <img src="//spacegoods.com/cdn/shop/t/346/assets/icon_plasc.svg?v=77407900391982634181722621923" alt="plasc">171 </div>172 <div class="item_text">173 Third party tested174 </div>175 </div>176177 </div>178 <a href="https://spacegoods.com/pages/science" class="section_btn">Read more here -</a>179 </div>180 <div class="right_part">181182 <img src="//spacegoods.com/cdn/shop/files/choc_cup_2000x.webp?v=1720521348" alt="Image" data-flavor="Coffee">183184 <img src="//spacegoods.com/cdn/shop/files/choc_cup_2000x.webp?v=1720521348" alt="Image" data-flavor="Chocolate" style="display: none;">185186 <img src="//spacegoods.com/cdn/shop/files/rainbow-dust-vanilla-cinnamon-travel-pack-Spacegoods-59366555_2000x.webp?v=1729941007" alt="Image" data-flavor="Vanilla Cinnamon" style="display: none;">187188 <img src="//spacegoods.com/cdn/shop/files/Screenshot_2024-07-22_at_21.10.06_2000x.png?v=1721813805" alt="Image" data-flavor="Strawberry" style="display: none;">189190 <img src="//spacegoods.com/cdn/shop/files/choc_cup_2000x.webp?v=1720521348" alt="Image" data-flavor="Raw Chocolate (Decaf)" style="display: none;">191192 </div>193 </div>194</div>195<script>196197</script>198199</div>
How to install Quality guarantee on your Shopify theme
This snippet belongs in sections/main-product.liquid, directly under the Add to cart button, where it reinforces the purchase decision. Expect the whole job to take about 15–25 minutes.
- 1From your Shopify admin, open Online Store → Themes, click the … button on your live theme and choose Duplicate. Always work on a copy so you can roll back instantly.
- 2On the duplicated theme, click … → Edit code to open the theme code editor.
- 3Open sections/main-product.liquid in the file tree. If your theme uses different file names, search for the template that renders the area where you want the block to show up.
- 4Click Copy code on this page, then paste the snippet directly under the Add to cart button, where it reinforces the purchase decision.
- 5The snippet ships with its own scoped
<style>block, so you do not need to touchbase.cssortheme.css. If you prefer to keep CSS centralised, move the contents of the style tag into your theme stylesheet and delete the inline block. - 6Keep the
<script>tag at the end of the snippet. It only runs once the surrounding markup exists in the DOM, so moving it higher up the file can break the behaviour. - 7Click Save, then hit Preview and check the block on desktop, tablet and mobile widths.
- 8When you are happy with the result, publish the duplicated theme from Online Store → Themes → Actions → Publish.
How to customise it
Every value below lives inside the snippet, so you can adapt Quality guarantee to your brand without touching the rest of the theme.
- Colours — the snippet uses
#000001,#000,#f27,#fff. Replace those values inside the style block with your brand palette, keeping at least a 4.5:1 contrast ratio between text and background so the block stays accessible. - Typography — the block declares
font-family: 'TAN - MEMORIES'. Delete that line to inherit your theme font instead, which usually looks better integrated. - Sizing — adjust the font-size values (44px, 20px, 18px) and the padding so the block carries the same visual weight as the elements around it.
- Corners —
border-radius: 10pxcontrols the roundness. Set it to 0 for a sharper editorial look, or increase it for a softer, app-like feel. - Images — replace the placeholder image URLs with your own assets. Upload them under Content → Files in Shopify admin and use the generated CDN URL, or reference a theme asset with
{{ 'my-image.png' | asset_url }}. - Copy — rewrite the hard-coded text (for example “Quality guarantee -”) in your own brand voice, and translate it if you sell in more than one language.
- Responsive behaviour — the
@mediaquery defines the mobile breakpoint. Adjust the pixel value if your theme uses a different breakpoint scale.
Common mistakes to avoid
These are the issues merchants run into most often when installing a snippet like this one.
- Editing the live theme directly. Duplicate it first — a single unbalanced Liquid tag can take a storefront down mid-campaign.
- Pasting the code into the wrong file. Dropped into
layout/theme.liquidinstead ofsections/main-product.liquid, this block will render on every page of the store, including ones where it makes no sense. - Renaming the CSS classes in the markup but not in the style block, or vice versa. The class names have to match exactly or the styling silently disappears.
- Adding the snippet twice on the same page. The script targets its selector, so two copies can conflict or double-fire.
- Publishing without testing on a real phone. Most Shopify traffic is mobile, and layout problems almost always surface there first.
Performance notes
What this block costs you in load time, and how to keep that cost at zero.
- The CSS is inline and scoped to this block, so it adds no extra network request. At a few kilobytes it has no measurable effect on your Lighthouse score.
- The JavaScript is vanilla — no jQuery, no external library, no additional request. Keep it after the markup so it never blocks rendering.
- Add
loading="lazy"plus explicit width and height attributes to every image in the snippet. That prevents Cumulative Layout Shift, which is a Core Web Vitals ranking factor. - Run PageSpeed Insights before and after you add the block so you have a concrete number rather than a guess.
SEO & accessibility
How to add this block without damaging your on-page structure or your rich results.
- Nothing in this snippet should replace your page
<h1>. Keep product and page headings intact and use<h2>or<h3>for the block's own heading so the document outline stays clean. - Write a descriptive alt attribute for every image. Empty or generic alt text is one of the most common accessibility and SEO issues on Shopify stores.
- Any link you add here is an internal link. Point it at a real collection or page rather than
#, and use descriptive anchor text instead of “click here”. - If the block shows review or rating content, keep it consistent with the structured data your review app already outputs. Duplicating or contradicting rating markup can cost you the rich result entirely.
- The block does not create a new URL, so there is no canonical or indexing change to make. It improves on-page engagement signals rather than crawlability.
Quality guarantee — questions merchants ask
Will this snippet work with my theme?
It is built with standard Liquid, HTML and CSS, so it works with Dawn and virtually every Online Store 2.0 theme, as well as most vintage themes. The only thing that changes between themes is the file you paste it into — if yours has no sections/main-product.liquid, look for the equivalent template that renders the same area.
Do I need an app to use it?
No. This is theme code you own outright: no monthly fee, no third-party script tag, and no app that can break your storefront the next time it updates.
How long does it take to add “Quality guarantee” to a store?
Most merchants have it live in under fifteen minutes — duplicate the theme, paste the code, adjust the colours and copy, preview on mobile, publish.
The block appears but nothing happens. What is wrong?
That is almost always a script-order problem. Check that the script tag is still at the bottom of the snippet and that the markup was not pasted inside another script or a Liquid comment block. Open your browser console and look for an error naming the snippet's selector.
The styling looks broken after pasting. How do I fix it?
Confirm you copied the whole snippet including the closing style tag, then check whether one of your theme's own CSS rules is overriding it. If a theme rule wins, increase the specificity of the snippet's selector rather than scattering !important through the file.
Will it slow my store down?
Not meaningfully. It is inline markup with scoped CSS and at most a few lines of vanilla JavaScript — no external libraries, no extra HTTP request. Optimising your product images will always have a far bigger impact on load time.
Can I use it on a client store or a commercial project?
Yes. Every snippet in the MCO Hub library is free to copy, modify and ship on any store, including client work. Attribution is appreciated but not required.
Related snippets
Keep exploring
Guides
Shopify Liquid



