Recommended practice Priority: Moderate
The page has more than one main content area
Two or more parts of the page are marked as the main content. There should be only one. This is a recommended practice that goes beyond the WCAG 2.2 AA level the law relies on.
This text was translated automatically and has not been reviewed by a native speaker yet.
Why it matters to your customers
Screen reader users jump between page areas (header, menu, main content, footer) like chapters. When they jump to "main content", they may land on a banner or a widget instead of the product page or the cart, and have to search again.
Who is affected
- blind people using screen readers
- keyboard users relying on a "skip to content" link
- people with low vision using screen magnifiers with speech
How to fix it
Leave a single <main> element (or role="main") that wraps the real page content. Replace the extra <main> or role="main" in nested templates, sections and embedded widgets with <div> or <section>. Check pop-ups, quick-view windows and mega menus too, since they are often built from a copy of the page template.
On Shopify
Usually the theme's layout/theme.liquid already contains <main>, and a section or app block adds another one. Change the extra <main> in the section file or ask the app developer to remove it.
On Shoptet (CZ)
Usually comes from custom HTML added to a page or from the template. Check your own added code first; if it is in the template, report it to Shoptet or a partner.
On PrestaShop
Usually the theme's layout .tpl and a module template both output <main>. Edit the module template override in the theme so only the layout has <main>.
On WooCommerce
Usually the theme wraps content in <main> and a page builder or a WooCommerce template override adds a second one. Fix it in the child theme's template or switch the builder's container tag to div.
Fix it with AI
Copy this prompt into ChatGPT, Claude or Copilot and add the HTML of the element. Check the answer before you publish it.
You are an experienced web developer and accessibility specialist. Fix this accessibility problem on my website so that it meets WCAG 2.2 level AA. Website: [https://…] ## Problem: The page has more than one main content area Two or more parts of the page are marked as the main content. There should be only one. This is a recommended practice that goes beyond the WCAG 2.2 AA level the law relies on. **How to fix:** Leave a single <main> element (or role="main") that wraps the real page content. Replace the extra <main> or role="main" in nested templates, sections and embedded widgets with <div> or <section>. Check pop-ups, quick-view windows and mega menus too, since they are often built from a copy of the page template. ## Elements found by the automated check [Paste the HTML of the element here, or the selector from the Pandus report] ## Requirements - Change only what is needed; keep the design and how the site works. - Do not add accessibility overlays or widgets; fix the code or the content. - Show the corrected code and say in which template or file it goes. - Explain how to check the fix with the keyboard and a screen reader.
Standards
Not a WCAG success criterion: a recommended practice that makes the site easier to use.
Automated check: axe-core rule landmark-no-duplicate-main.
dequeuniversity.com, github.com, www.w3.org
Read next
Guides and tools
Help articles
-
How to read a report and what to fix first
What each part of the report means and how to turn it into a to-do list for your developer.