Which WCAG criterion this fails
- Does not meet 4.1.1 Parsing (Level A)
- Does not meet 4.1.2 Name, Role, Value (Level A)
How to fix it on Shopify
Everything below is done from Online Store > Themes > Edit code. Take a copy of the theme before editing.
- Ids must be unique across the whole page. Anything rendered inside a loop needs the loop index or the object id appended.
- In Liquid, suffix with {{ section.id }} or {{ product.id }}: id="Quantity-{{ section.id }}".
- Update every reference at the same time — the matching <label for>, aria-controls, aria-labelledby and aria-describedby.
- Quick-view and quick-add modals are the usual source, because they render a second copy of the product form.
- Search the theme for id=" and look for any hardcoded id inside a {% for %} block.
Where this usually lives
snippets/quantity-input.liquid, snippets/card-product.liquid, snippets/quick-add.liquid, sections/main-product.liquid
Paths given for Dawn and its derivatives (Sense, Craft, Refresh, Studio). A heavily customised theme may differ; the CSS selector in your scan report points at the exact element.
Code
<label for="Quantity-{{ section.id }}">Quantity</label>
<input type="number"
id="Quantity-{{ section.id }}"
name="quantity"
form="product-form-{{ section.id }}">How to confirm it is fixed
Re-run the scan. This rule should drop out of the findings entirely. If the instance count falls but does not reach zero, the same defect exists in another template — product cards and quick-view modals are the usual second home for it.
Effort: medium. Rule id: duplicate-id-active (axe-core).