The WordPress 7.1 Field Guide notes that Settings API section titles receive IDs. Plugins that reuse section identifiers across pages, print custom duplicate headings, clone tabs, or target old markup can create invalid IDs, broken anchors, ambiguous accessible relationships, and JavaScript or CSS collisions.
Use this for plugin settings, network admin pages, tabbed options, multisite, white-label dashboards, translated headings, custom do_settings_sections wrappers, and extensions that target section markup.
Quick answer
Inventory every registered settings page and section with page slug, section ID, title callback, rendered heading ID, screen context, tab, locale, network state, and plugin owner. Render each page on WordPress 7.1 as the intended role, collect all id attributes, and report duplicates plus label, aria-labelledby, href fragment, CSS selector, and JavaScript references. Fix the registration identifier or custom wrapper instead of hiding duplicate headings. Repeat for translated locales, multisite network admin, reordered sections, missing titles, and pages that combine sections from several plugins.
Test scenarios to run
Run the same controlled fixture across these branches. Write down the expected result before testing so a surprising response is easy to identify.
| Scenario | Fixture | Expected result |
| Single page | Unique section IDs | One target per heading |
| Two plugins | Both use general | Collision detected |
| Hidden tab | Duplicate DOM remains | Unique IDs still required |
| Locale | Translated title | Stable valid target |
Diagnostic table
Use this table to connect the observed behavior to evidence and a verification step.
| Action | Evidence | Verification |
| Inventory registered section owners | Record WordPress version, plugin versions, page slugs, add_settings_section calls, section IDs, callbacks, custom wrappers, tabs, locales, roles, network context, scripts, styles, and anchor links. | Every tested settings page has unique IDs in each rendered state. |
| Collect rendered IDs and references | Render every settings page and collect heading text, generated ID, all matching nodes, label and ARIA references, URL fragments, query-selected tabs, CSS selectors, and JavaScript lookups. | Labels, ARIA relationships, fragments, CSS, and JavaScript resolve the intended node. |
| Reproduce tab and locale collisions | Test two plugins sharing a generic section ID, repeated callbacks, hidden tabs in the DOM, translated titles, missing titles, reordered sections, network admin, and a page with custom markup. | Roles, locales, tabs, and network admin contexts pass. |
| Fix IDs at registration | Classify duplicate IDs, broken fragment targets, multiple accessible-name targets, selector collisions, focus failures, and code that assumes the pre-7.1 heading structure. | The automated check catches a deliberately introduced duplicate. |
What to check first
- Record WordPress version, plugin versions, page slugs, add_settings_section calls, section IDs, callbacks, custom wrappers, tabs, locales, roles, network context, scripts, styles, and anchor links.
- Render every settings page and collect heading text, generated ID, all matching nodes, label and ARIA references, URL fragments, query-selected tabs, CSS selectors, and JavaScript lookups.
- Test two plugins sharing a generic section ID, repeated callbacks, hidden tabs in the DOM, translated titles, missing titles, reordered sections, network admin, and a page with custom markup.
- Classify duplicate IDs, broken fragment targets, multiple accessible-name targets, selector collisions, focus failures, and code that assumes the pre-7.1 heading structure.
- Change identifiers at their registration owner, update documented links and selectors, retain backward-compatible behavior where required, and add an automated DOM uniqueness assertion.
Field notes
- Write the pass condition before changing anything and keep one repeatable synthetic fixture for the full test window.
- Record exact versions and UTC timestamps because deployments, caches, retries, scheduled actions, and background jobs can change the evidence.
- Test the public path and the stored server-side result, not only an admin preview, isolated command, or API response.
- Repeat verification after the relevant cache, queue, cron, webhook, and observation window has completed.
Useful command or data shape
Adapt paths, IDs, and privacy handling to the site before running commands or storing data on production.
document.querySelectorAll('[id]').forEach((node) => {
const count = document.querySelectorAll('#' + CSS.escape(node.id)).length;
if (node.id && count > 1) console.warn(node.id, count);
});
Why this usually happens
- A generic identifier such as default or general is reused on the same rendered page.
- Tabbed interfaces leave several copied settings sections in the DOM.
- Custom callbacks print an ID that now matches the core-generated heading ID.
- Scripts target an element by ID and silently bind only the first match.
Decision rule
Approve a settings page only when every rendered ID is unique, labels and ARIA references resolve once, fragments focus the intended heading, and scripts or styles do not depend on ambiguous selectors.
Production verification checklist
- Every tested settings page has unique IDs in each rendered state.
- Labels, ARIA relationships, fragments, CSS, and JavaScript resolve the intended node.
- Roles, locales, tabs, and network admin contexts pass.
- The automated check catches a deliberately introduced duplicate.
Safe fix order
Use a sequence that makes each result easy to prove. Stop when new evidence changes the scope or owner of the problem.
- Inventory registered section owners
- Collect rendered IDs and references
- Reproduce tab and locale collisions
- Fix IDs at registration
- Add a DOM uniqueness test
Mistakes to avoid
- Changing production before recording exact versions, UTC timestamps, a stable fixture, the expected result, and a tested rollback point.
- Treating one successful screen as proof while stored records, logs, queues, caches, emails, APIs, and downstream systems remain unchecked.
- Testing only as an administrator instead of using the role, device, locale, cache state, and failure branch that real users reach.
- Leaving temporary exclusions, debug output, helper accounts, broad permissions, or one-off repair code active after verification.
Questions teams ask during testing
Can I run this directly in production?
Begin with read-only evidence and use staging for package, code, database, form, or permission changes. If a production canary is necessary, make it identifiable, reversible, monitored, and unable to expose personal data or charge a customer.
How do I avoid a false positive?
Repeat the same fixture with the same versions, role, URL, locale, cache state, and downstream integrations. Compare browser, stored, and log evidence instead of relying on one screen.
What should the evidence packet contain?
Keep UTC time, exact versions, synthetic record ID, expected result, actual result, relevant log lines, change made, rollback point, owner, and final verification. Redact secrets and personal data.
When is the test complete?
Close the work when the primary path passes, failure branches are understood, stored and downstream records reconcile, temporary changes are removed, and monitoring covers the next update.
What to tell the client or owner
Give the owner a concise packet with the affected workflow, exact versions, UTC test time, fixture ID, expected result, actual result, key logs, change made, rollback point, final result, unresolved risks, owner, and next review date. Remove credentials and personal data before sharing it.
When HandL WP should help
Bring in help when this affects leads, checkout, search visibility, security, paid media reporting, or a client production site. HandL WP can trace the issue through WordPress, hosting, cache, tracking, and Search Console, then verify the workflow after the technical fix.
If this is active on a production site, have HandL WP test a WordPress 7.1 plugin.
Related HandL WP guides
Use these related guides when the same issue touches tracking, security, checkout, or crawler visibility.
Helpful references