Rule ID: ace-struct-frame-unique-title

Check that each iframe and frame element has a unique descriptive title

WCAG 2.0 (A) - WCAG 2.2 (A) 4.1.2: Name, Role, Value Blind Deafblind Mobility User Impact

What This Rule Checks

When navigating through a website using assistive technologies such as screen readers, it’s crucial that each frame or iframe has a unique, descriptive title. This helps users understand the purpose or content of each frame, improving the accessibility of your website.

Who Is Affected

This issue primarily affects: Blind users, who rely entirely on screen readers or braille displays to navigate and interact with content; Deafblind users, who rely on braille displays and cannot access visual or auditory content; Mobility users, who navigate using keyboards, switches, voice control, or other assistive input devices.

Why This Matters

Screen reader users navigate between frames using the title attribute. Duplicate titles make it impossible to distinguish between embedded content areas, forcing users to enter each frame to discover what it contains.

How to Fix

Provide Unique Titles for Each Frame: Ensure that each frame or iframe has a unique and descriptive title attribute. The title should summarize the content or purpose of the frame.

Match Titles with Content: It’s best practice to give the enclosed document inside the frame a corresponding <title> element. Screen readers may use this internal document title to replace the title attribute in the frame, so having them aligned ensures a consistent user experience.

Code Examples

Incorrect Markup Solutions:
Code example
<!-- Multiple frames with identical titles --> <iframe src="ad1.html" title="Content"> </iframe> <iframe src="ad2.html" title="Content"> </iframe> <iframe src="chat.html" title="Content"> </iframe> Copy
Correct Markup Solutions:
Code example
<!-- Each frame has a unique, descriptive title --> <iframe src="ad1.html" title="Special offer banner"> </iframe> <iframe src="ad2.html" title="Partner advertisement"> </iframe> <iframe src="chat.html" title="Customer support chat"> </iframe> Copy

Common Mistakes to Avoid

  • Using generic titles like “Content” or “Frame” for all iframes.
  • Copy-pasting iframe elements without updating the title attribute.
  • Using the same title for both the main content frame and advertising frames.

AI Auto-Fix Available

This rule supports ACE™ AI Auto-Fix. When a violation is detected, ACE can automatically generate a code fix for review. The AI analyzes the specific element in context and proposes a targeted remediation that preserves your existing markup and styling. You can preview, modify, and approve the fix before it is applied.

Tip: Proper document structure enables assistive technologies to present content meaningfully. Headings, lists, and semantic HTML elements create a navigable outline of the page that screen reader users depend on.

Related WCAG Criteria

4.1.2: Name, Role, Value