`, and labels are associated with inputs using the `for` attribute matching the input’s `id`. This semantic foundation typically resolves 60-70% of accessibility issues without adding any ARIA. Next, add ARIA only where semantic HTML is insufficient. For example, a button that shows or hides a menu needs `aria-expanded` and `aria-controls`. A live-updating notification area needs `aria-live=”polite”` and optionally `aria-atomic=”true”`.
A custom select dropdown needs `role=”combobox”`, `aria-haspopup=”listbox”`, and dynamic updates to `aria-expanded`. A field with validation errors needs `aria-invalid=”true”` and `aria-describedby` pointing to the error message. The tradeoff here is between effort and benefit. A native HTML select element requires no ARIA but limits styling options. A custom dropdown styled with CSS and JavaScript provides better visual control but requires more ARIA attributes and JavaScript complexity to remain accessible. Many developers choose to use custom dropdowns, but this decision should be intentional, not accidental.
Common Accessibility Errors and How to Avoid Them
One of the most frequent errors is missing or poorly associated labels on form fields. A screen reader cannot announce what a text input is for if it lacks a `` element with a `for` attribute matching the input’s `id`. Many developers hide labels with CSS and rely on placeholder text, but placeholders disappear when a user starts typing, leaving screen reader users confused. The fix is simple: use proper `` elements, and if your design requires hidden text labels, hide them visually with CSS while keeping them available to assistive technologies using the `sr-only` class (Screen Reader Only). Another common error is using color alone to communicate information, such as a red border for errors or a green checkmark for valid fields. Color-blind users cannot perceive these distinctions. Always pair color with text, icons, or patterns.
For example, a form field with an error should display not only a red border but also an error message tied to the field with `aria-describedby` and `aria-invalid=”true”`. Warning: images without alt text create accessibility barriers and also hurt SEO, since search engines cannot read images. Every informative image needs descriptive alt text; decorative images need `alt=””` to signal they should be skipped. A third error is relying on mouse-only interactions. Every interactive element must be keyboard-accessible. A modal that can only be closed by clicking an X button should also close when a user presses Escape, and focus should be trapped within the modal and returned to the trigger element when closed. Hover-only content, such as tooltips that appear only on mouse-over, excludes keyboard and screen reader users. Always provide keyboard equivalents and ensure focus-based interactions work alongside hover states.
Testing Your Accessible Pages
Testing requires both automated tools and manual verification. Automated tools like Axe, Lighthouse, and WAVE scan pages for common issues like missing alt text, unlabeled buttons, color contrast problems, and incorrect ARIA usage. These tools are valuable for catching obvious errors but cannot catch all accessibility issues. A page might pass automated testing yet still be difficult to navigate with a keyboard or screen reader if the interactive patterns are confusing.
Manual testing with actual assistive technologies is essential. Testing with a screen reader like NVDA (free, Windows) or JAWS (paid, Windows) or VoiceOver (built into Mac and iOS) reveals how your page is experienced by users who cannot see it. Navigation using only the keyboard—tabbing through interactive elements, using arrow keys in menus and lists, using Enter and Space for buttons—identifies keyboard navigation gaps. Testing with real users who have disabilities provides invaluable feedback that no automated tool can match.
The Future of Web Accessibility and Evolving Standards
Web accessibility standards continue to evolve. WCAG 2.2 (released late 2023) introduced new criteria around focus visible, draggable items, and consistent help, while discussions around WCAG 3.0 are underway to simplify and expand accessibility guidance. As web applications become more complex with frameworks like React, Vue, and Svelte, the need for proper ARIA usage becomes more critical—and more complex.
Modern JavaScript frameworks introduce challenges where DOM updates happen dynamically, requiring careful management of ARIA live regions and focus management. The trend toward accessibility-first design means that many teams now incorporate accessibility testing from the start, rather than treating it as a final audit. Progressive enhancement—ensuring pages work without JavaScript and providing semantic HTML as the foundation—gains traction as a best practice. For developers and content creators, staying current with WCAG guidelines and understanding the interplay between semantic HTML and ARIA is increasingly essential to building websites that work for everyone.
Conclusion
Creating truly accessible web pages requires both semantic HTML and ARIA working together. Semantic HTML provides the structural foundation that all users can rely on, while ARIA enhances interactive components and provides additional context that HTML alone cannot express.
The approach is not about choosing between them but using semantic HTML as your starting point and adding ARIA only where necessary to communicate interactive patterns and dynamic content. Moving forward, prioritize semantic HTML in your development workflow, test with both automated tools and real assistive technologies, and treat accessibility as an integral part of design rather than a compliance afterthought. By combining semantic HTML with thoughtful ARIA implementation, you’ll create pages that work better for everyone—including users with disabilities, older browsers, low-bandwidth connections, and search engines.
Frequently Asked Questions
Do I need to use ARIA if I’m using semantic HTML correctly?
Semantic HTML alone handles many accessibility scenarios, but ARIA becomes necessary for complex interactive components like tabs, carousels, and custom dropdowns that semantic HTML cannot fully describe.
Is adding ARIA attributes to divs and spans enough to make a page accessible?
No. ARIA is a communication layer that announces functionality to assistive technologies, but it doesn’t create actual functionality. A `
` without keyboard event listeners, focus management, and proper styling is not truly accessible.
How do I choose between using a native HTML element and a custom element with ARIA?
Native HTML elements are preferred because they include built-in accessibility features (keyboard support, focus management, correct roles) with zero additional effort. Custom elements should only be used when native elements cannot meet your design or functionality requirements.
What’s the most common accessibility mistake developers make?
Relying on color alone to communicate information, missing form labels, and failing to test with actual assistive technologies are among the top mistakes that automated tools cannot always catch.
Should every interactive element have an aria-label?
Only if the element lacks visible text that conveys its purpose. If a button contains the text “Save,” an aria-label is unnecessary. If a button contains only an icon, `aria-label`, `aria-labelledby`, or visible text is required.
Does semantic HTML improve SEO?
Yes. Search engines use semantic HTML to better understand page structure and content hierarchy, which can improve how pages are indexed and ranked for relevant searches.
You Might Also Like